Styles, Search & Replace With "Append" ?

General comments and questions. Technical support.
Post Reply
acant05
Posts: 28
Joined: Fri Nov 18, 2005 3:44 pm
Location: Elkins, WV, USA

Styles, Search & Replace With "Append" ?

Post by acant05 »

I am converting batches of rtf documents to text and/or html formats. I need to add a marker (such as "T:" or "H1:") that precedes the Title and Heading styled text so that MobiPocket Creator can import the file and create a TOC. Have tried saving the html from MS Word but it is too "messy." Also, saving to txt doesn't work since identy of heaings is lost. Is this possible with Atlantis?
Couldn't see a way in the help file...

Thanks
Blessings,
Al Cantley
Robert
Posts: 1906
Joined: Fri Aug 15, 2003 8:27 pm

Re: RTF to HTML

Post by Robert »

Greetings

1. As you noticed, saving to text, that is to “pure text”, would get rid of all formatting, including formatting attached to headings.

2. Atlantis has got a command to save documents as Web pages (“File | Save Special > Save As Web Page…”) This will produce clean HTML code.

3. About creating TOCs. It might be a good idea to create the TOCs before saving the RTF files as Web pages. All you need to do is to open the RTF files in Atlantis, then click “Insert | Table Of Contents…”

Hope this helps.
Cheers
Robert
acant05
Posts: 28
Joined: Fri Nov 18, 2005 3:44 pm
Location: Elkins, WV, USA

Post by acant05 »

Robert,

My problem is that the documents I am working with are exported in rtf format from Folio Views and do not use the standard style names, Heading 1, Heading 2, etc; one uses Section , Subsection, and another uses Chapter, Chapter Subtitle. There are hundreds of documents involved. Compounding the problem is MobiPocket's quirkiness.

The bottom line is that I need to be able to search based on styles and append a marker to the applicable style's content.

If Atlantis cannot do this then my best solution may be to use a text editor RE script to transform the raw rtf file.

Thanks again.
Blessings,
Al Cantley
Robert
Posts: 1906
Joined: Fri Aug 15, 2003 8:27 pm

Re: RTF to HTML (2)

Post by Robert »

Hi,
I am not sure, but this might work for you:

1. Open one of these RTF documents in Atlantis.
2. If the document does not include “Heading” styles, use the Control Board (F6) Style panel to create them. Create as many “Heading” styles (1, 2, 3, etc) as are required to have corresponding levels in the TOCs. Give them appropriate characteristics.
3. Use the rightmost toolbar button on the Control Board Style panel to select all paragraphs associated with the document “Section” style.
4. Leave the document selection AS IS, and select the “Heading 1” style in the Control Board Style panel.
5. Press the “Apply style to document selection” button on the Control Board Style panel.
All the paragraphs previously associated with the “Section” style will now be associated with the “Heading 1” style.
6. Repeat steps 3 to 5 with all the Folio Views style names that need to be “converted”.
7. When the document has appropriate “Heading” styles, click “Insert | Table Of Contents…”
8. When the TOC has been created, click “File | Save Special > Save As Web Page…”

Note that you do not need to create “Heading” styles in each new document. When the “Heading” styles have been created in the first document, they can be imported into any other document, using the Style panel “Import styles” toolbar button. This is of course if you want the “Heading” styles to have the same characteristics across all documents.

Hope this helps.
Cheers,
Robert
Post Reply