groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Groff] Smart quotes


From: Peter Schaffter
Subject: [Groff] Smart quotes
Date: Mon, 5 Feb 2001 15:01:06 -0500
User-agent: Mutt/1.2.5i

Has anyone solved the problem of smart quotes in groff?  I'm
writing a macro set, and I'd like to include a smart quotes
option so that "..." gets turned into the appropriate open-
and close-quotes on output, without the user having to enter
``...''

The macro set is designed for fiction writers, who have
frequent need of quotation marks, and for whom, in a text file,
`` and '' are visually disturbing, as are inline escape sequence
and control lines that break up a paragraph.

I'd like to write a macro that gets invoked *inline* with
the " character ( .char " \*[QUOTE_MACRO] ).  QUOTE_MACRO would
evaluate whether " was an open-quote or a close-quote, and
substitute `` or '' accordingly.

Problem is, of course, that groff doesn't like inline macros
that contain anything but escape sequences, which makes
evaluation impossible.

So... how do I do this?

-- 
PTPi
Peter Schaffter
15, chemin Brunette, RR2 CP 406
Ste-Cécile-de-Masham (Québec)
CANADA  J0X 2W0

A confirmed GNU/Linuxer. Sorry, I don't do Windows.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]