Welcome to Telelogic Product Support
  Home Downloads Knowledgebase Case Tracking Licensing Help Telelogic Passport
Telelogic DOORS (steve huntington)
Decrease font size
Increase font size
Topic Title: Find the location of a rich text chunk
Topic Summary:
Created On: 31-Mar-2006 02:35
Status: Post and Reply
Linear : Threading : Single : Branch
Search Topic Search Topic
Topic Tools Topic Tools
Quick Reply Quick Reply
Subscribe to this topic Subscribe to this topic
E-mail this topic to someone. E-mail this topic
Bookmark this topic Bookmark this topic
View similar topics View similar topics
View topic in raw text format. Print this topic.
 31-Mar-2006 02:35
User is offline View Users Profile Print this message


Chris Jones

Posts: 177
Joined: 1-Jul-2005

I'm working on a script that reads in an RTF and needs to decide some things based on the formatting of a string inside the file. It will look for "Introduction" and then see if this is has a certain Paragraph Style.
Since DOORS rich text apparently doesn't know about Styles, I am planning to find a match, then look backward through the raw RTF string for "\s1" (which tells us that the paragraph uses style 1).

I am trying to figure out the best way to do this. I can use a 'for rtp in s' loop and check if rtp.text is the right string, but then I don't know where I'm at inside the string. Is there some way to get the string index of a rich text paragraph? Or should I use regexps on the raw string? (The problem with that is that it will also match other things, like the Title, that say "Introduction.")

Chris
Report this to a Moderator Report this to a Moderator
Statistics
20925 users are registered to the Telelogic DOORS forum.
There are currently 1 users logged in.
The most users ever online was 15 on 15-Jan-2009 at 16:36.
There are currently 0 guests browsing this forum, which makes a total of 1 users using this forum.
You have posted 0 messages to this forum. 0 overall.

FuseTalk Standard Edition v3.2 - © 1999-2009 FuseTalk Inc. All rights reserved.