Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations wOOdy-Soft on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to import RTF/Doc to Quark with different styles? 1

Status
Not open for further replies.

aposp

Technical User
May 12, 2003
1
RU
Dear professionals, I need your advise:
if smbd knows the way to retain formatting and styles after importing rtf/doc to Quark. More over, the text fragment marked with bold (or italic and so on) should have not Normal style in Quark (after importing) but some other style: for ex. Normal_Bold. Is it possible?

If smbd knows some utilities or programes that can transform html tags to XPressTags?

Thank you,
Anna
 
If the Include Style Sheets box is checked, the styles import.

As for html to xtags, it should not be too difficult to write a simple filter, depending on how sophisticated you need it to be. There is a program called R2netcmd that converts RTF to html. The config for R2net can be set so almost all of the header tags, etc., are stripped out of the html, leaving you with a file that basically contains markup. You could then translate the bolds, itals, etc., with a search and replace script.

Here's how mine works: People put RTF file in an IN directory. A TCL/TK script runs as a cron job every few minutes and when it finds a file in IN, it converts it to HTML and does some elementary substitutions for special characters, bolds, itals, etc. It could do fonts and stuff, but I don't care about that. It then moves the RTF file to an OUT directory and puts the html version in a mysql database.

I have another script that does a similar thing with files created by the Xywrite word processor, but it converts the bolds, etc., to XTAGS.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top