[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Readability of troff documents (Was: [Groff] Bug in gxditview)
From: |
Alejandro Lopez-Valencia |
Subject: |
Re: Readability of troff documents (Was: [Groff] Bug in gxditview) |
Date: |
Fri, 23 May 2003 07:32:37 -0500 |
At 12:41 a.m. 23/05/2003, Giorgos Magos wrote:
Is there a way (other than preprocessing through some sed
filter) of inserting these the way they're inserted in
LaTeX?
Besides the sed (or awk) way, there are other alternatives.
1. If you are in control of your editor, you can use a mechanism to map
key-codes to groff char-codes. See for example the attached keymap files
for vim. You need a vim compiled with the +keymap feature. This approach
has its disadvantages, namely, you need that the particular character be
assigned a key-code! (Thusly, you still need to type \[em] or use sed...).
But this cold be worked around using a language map (+langmap feature). I
haven't explored this possibiity though. (B. Moolenaar, vim's BDFL,
considers this a thorough perversion of the original purpose, btw). I am
sure you can do the same with a Mule enabled Emacs (and lots of coding ;-).
2. Use the right language for the job. Python allows you to write special
purpose codecs that don't necessarily have to be actual computer codepages
nor character vector encodings. Soo... You can write the web application
code you give as an example of (very practical and contemporaneous uses of
troff) in some Python web-application framework (there are several each
appealing to different audiences) and use an special purpose codec to
decode your input text into groff source on-the-fly. I haven't tried this
yet, but to my taste this beats hands-down writing sed scripts :-)
groff_keymap.zip
Description: Zip archive
- Re: Readability of troff documents (Was: [Groff] Bug in gxditview), (continued)
[Groff] Re: Readability of troff documents, Werner LEMBERG, 2003/05/23
- Re: [Groff] Re: Readability of troff documents, Andreas Kähäri, 2003/05/23
- RE: [Groff] Re: Readability of troff documents, Ted Harding, 2003/05/23
- Re: [Groff] Re: Readability of troff documents, Giorgos Magos, 2003/05/23
- Re: [Groff] Re: Readability of troff documents, Greg 'groggy' Lehey, 2003/05/24
- Re: [Groff] Re: Readability of troff documents, Werner LEMBERG, 2003/05/25
- Re: [Groff] Re: Readability of troff documents, Ted Harding, 2003/05/25
Re: Readability of troff documents (Was: [Groff] Bug in gxditview),
Alejandro Lopez-Valencia <=
Re: Readability of troff documents (Was: [Groff] Bug in gxditview), Robert D. Goulding, 2003/05/23
Re: Readability of troff documents (Was: [Groff] Bug in gxditview), Jorgen Grahn, 2003/05/23