Subject: plain ASCII output (was Re: Jade Backends (from The DSSSList Digest V2 #120)) From: Louis-Dominique Dubeau <ldd@xxxxxxxxxxx> Date: 27 Aug 1998 09:07:51 -0400 |
MARK.WROTH@xxxxxxxxxxx (Wroth, Mark) writes: > BTW, a decent plain ASCII (i.e. emailable in an SMTP message as > formatted but not marked up plain text) would be even more useful. > There are obvious issues with such functionality (what does one do with > non-ASCII characters, for example). My current approach to this one is > to use the RTF backend and then save the resulting file as text, which > sort of works but is less than totally satisfactory. I use a different approach for that. I use the SGML backend and output the contents without any kind of SGML contstructs (except two special tags). The only SGML thing I output is <sp> and <nl> which are replaced by a very simple perl script to spaces and newlines respectively. (I started using <sp> and <nl> at a time when my knowledge of dsssl was very thin... I might be able to do without them now.) I also pipe the thing through the fmt command to do word-wrap. This approach has the following advantages: - The ASCII layout doesn't have to be tied to the RTF layout. For example you might want to wrap emphasized words with "*" (like *this*) in the ASCII output while using bold or italics in the RTF output. - You don't need an RTF-aware wordprocessor to convert to ASCII. (I'm using Linux so that means I don't have to reboot in Windows.) - It can be done in batch mode. It has the disadvantage though that you need to maintain at least 2 dsssl files: one for RTF output and one for ASCII output. I actually maintain 3 files: one common library of definitions and rules, one dsssl file for RTF and one dsssl file for ASCII. I do not consider this to be a permanent solution to ASCII output though. I'd rather have a real ASCII backend. Regards, ldd DSSSList info and archive: http://www.mulberrytech.com/dsssl/dssslist
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: Jade Backends (from The DSSSLis, Wroth, Mark | Thread | Re: Jade Backends (from The DSSSLis, James Tauber |
Re: Jade Backends (from The DSSSLis, David Megginson | Date | Re: PostScript?, Adam P. Harris |
Month |