ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Aditya Mahajan <adityam@umich.edu>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: [OT] intelligent commas in math (in LaTeX)
Date: Thu, 29 Sep 2011 12:15:15 -0400 (EDT)	[thread overview]
Message-ID: <alpine.LNX.2.02.1109291210330.17969@nqv-gnoyrg> (raw)
In-Reply-To: <CALBOmsYMaxAQ=0pGxoWP+Tm3GjHWe=fYZGLGt2DwCtz+_U42hg@mail.gmail.com>

On Mon, 26 Sep 2011, Mojca Miklavec wrote:

> http://tug.org/pracjourn/2011-1/beccari.html

Short summary: This allows the comma in  $1, 2, 3$ to be have as 
punctuation comma (similar to \setupmathematics[autopunct=no]) and
$1,23$ to behave as decimal comma (similar to 
\setupmatematics[autopunct=yes]). Since it is targeting pdftex and xetex 
engines, it makes , an active char in mathmode and redefines it as a macro 
that uses look ahead to check if the next token is a digit.

In principle a cleaner implementation is possible in luatex (without using 
active characters), but I am not completely sure about this. It will be 
better to handle this as part of \mnum macro.

Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


  reply	other threads:[~2011-09-29 16:15 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-26 20:06 Mojca Miklavec
2011-09-29 16:15 ` Aditya Mahajan [this message]
2011-09-30  7:36   ` luigi scarso
2011-09-30  9:04     ` Philipp A.
2011-10-01  2:12     ` Aditya Mahajan
2011-10-01  6:16       ` luigi scarso

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=alpine.LNX.2.02.1109291210330.17969@nqv-gnoyrg \
    --to=adityam@umich.edu \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).