Unescaped $ and & in texts
Can't we add a new mode to ConTeXt to use $ and & in text without escaping them with a backslash, & is not needed to write tables and for inline math \formula could be used. In text only documents I want also the % as normal character where I don't need comments. What do you think, with \nonknuthmode we have already a command to write '_' in text mode. \appendtoks \catcode`\$=12 \catcode`\&=12 \catcode`\%=12 \to \everystarttext \starttext Procter & Gamble’s stock climbed to $2, a 10% gain. \stoptext Wolfgang
On Wed, 17 Dec 2008, Wolfgang Schuster wrote:
Can't we add a new mode to ConTeXt to use $ and & in text without escaping them with a backslash, & is not needed to write tables and for inline math \formula could be used.
Also add # to the list. Basically, we can just define a catcode regime where only \ { and } are special. Inside math mode (activated by \formula, \math, \mathematics, or \startformula) we can switch to a catcode regime where _ and ^ are also set to appropriate catcodes. I would go as far as to say that we should make this default, but I don't think everyone will like that. So, for me a \justwritenaturally macro will do :) Aditya
Am 17.12.2008 um 21:46 schrieb Aditya Mahajan:
On Wed, 17 Dec 2008, Wolfgang Schuster wrote:
Can't we add a new mode to ConTeXt to use $ and & in text without escaping them with a backslash, & is not needed to write tables and for inline math \formula could be used.
Also add # to the list. Basically, we can just define a catcode regime where only \ { and } are special. Inside math mode (activated by \formula, \math, \mathematics, or \startformula) we can switch to a catcode regime where _ and ^ are also set to appropriate catcodes. I would go as far as to say that we should make this default, but I don't think everyone will like that. So, for me a \justwritenaturally macro will do :)
I wasn't sure if I should add # to the list bit it makes sense. \nonknuthmode takes care to tread _ and ^ as subscript and superscript in math mode and as normal chars in text mode. Wolfgang
Aditya Mahajan wrote:
On Wed, 17 Dec 2008, Wolfgang Schuster wrote:
Can't we add a new mode to ConTeXt to use $ and & in text without escaping them with a backslash, & is not needed to write tables and for inline math \formula could be used.
Also add # to the list. Basically, we can just define a catcode regime where only \ { and } are special. Inside math mode (activated by \formula, \math, \mathematics, or \startformula) we can switch to a catcode regime where _ and ^ are also set to appropriate catcodes. I
there is already \nonknuthmode )
would go as far as to say that we should make this default, but I don't think everyone will like that. So, for me a \justwritenaturally macro will do :)
we can discuss this some time next year or so; it is slightly more complex than changing a few catcoded because we need to make sure that modules etc are loaded under a different catcode regime then Hans  Hans Hagen  PRAGMA ADE Ridderstraat 27  8061 GH Hasselt  The Netherlands tel: 038 477 53 69  fax: 038 477 53 74  www.pragmaade.com  www.pragmapod.nl 
participants (3)

Aditya Mahajan

Hans Hagen

Wolfgang Schuster