Re: [NTG-context] "Semi-verbatim" - preserve whitespace - don't escape character
Wolfgang Schuster wrote:
\startlines verbatin text \stoplines
Thanks! That's almost perfect. I've noticed that space is still inserted after punctuation characters such as '.', ':' and '!'. Is it possible to disable this as well? I've read a little about category codes but I'm not entirely sure if that's what I should be using (perhaps ConTeXt provides a higher level macro for it?). __ dc
On Sat, 8 Dec 2007 09:28:02 -0500 dexterclarke@Safe-mail.net wrote:
Wolfgang Schuster wrote:
\startlines verbatin text \stoplines
Thanks! That's almost perfect.
I've noticed that space is still inserted after punctuation characters such as '.', ':' and '!'. Is it possible to disable this as well? I've read a little about category codes but I'm not entirely sure if that's what I should be using (perhaps ConTeXt provides a higher level macro for it?).
This is possible and I give you a very simple and dirty version below but can you explain why do you want this, I thought you want verbatim output and spaces after punctuation marks are part of verbatim code. \starttext \startlines \catcode`!=13 \catcode`:=13 \catcode`.=13 \def.{\char`.\ignorespaces} \def:{\char`:\ignorespaces} \def!{\char`!\ignorespaces} text text, text. text: text! text text text text, text! text. text: text text text text, text: text! text. text text text text, text. text: text! text text \stoplines \stoptext Wolfgang
participants (2)
-
dexterclarkeï¼ Safe-mail.net
-
Wolfgang Schuster