ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Sietse Brouwer <sbbrouwer@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: \digits get \times instead of \cdot before exponent
Date: Tue, 21 May 2013 21:17:55 +0200	[thread overview]
Message-ID: <CAF=dkzy=9fRdhtBx1nbQAGXoCFbwcx=CA6Jty5HGG0NEM_a6Gw@mail.gmail.com> (raw)
In-Reply-To: <519B869C.2020507@wxs.nl>

Hi Hans,

Christian Prim wrote:
>>>
>>> is it possible to change the behaviour of \digits to have \cdot [...]
>>> instead of \times [...]?

Hans wrote:
> there are several ways we can deal with this: [...]
> or maybe a key/value in setuptimes .. not sure yet

We've already got \setdigitmode, \setdigitorder, and \setdigitspace;
it might make sense to create a \setupdigits to consolidate these
setups into one interface. Something like this:

\setupdigits
   [mode=4,               % -->\setdigitmode{4}
                          % (decimal period, thinspace between groups)
    inputdecimalmark={,}, % -->\setdigitorder{0}
    signspace=yes,        % -->\setdigitsign{1}; '+ 1.4', not '+1.4'
    times=\times,         % or times=\cdot
    ]

Cheers,
Sietse

---------------

P.s: I've been thinking I'd like to write more contexty interface that
doesn't use predefined modes, but lets you setup the decimal mark,
separator mark, the input decimal mark, etc. Something like this:

\setupdigits
   [inputdecimal={.},  % input  3.1415926535
    decimal={,}
    separator=\space,
    groupsize=4,       % output 3,1415 9265 45
    signspace=,]       % +3.14159...

That could even tie into \setuplanguage to allow setting
language-specific defaults. Would anyone be interested in this?
___________________________________________________________________________________
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
___________________________________________________________________________________


  parent reply	other threads:[~2013-05-21 19:17 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-05-20  7:32 Christian Prim
2013-05-21  9:44 ` Romain Diss
2013-05-21 14:37   ` Hans Hagen
2013-05-21 15:15     ` Christian Prim
2013-05-21 15:34       ` Hans Hagen
2013-05-21 15:40         ` Christian Prim
2013-05-21 19:17     ` Sietse Brouwer [this message]
2013-05-21 21:35       ` Romain Diss
2013-05-22  8:29         ` Hans Hagen
2013-05-22 12:31           ` Romain Diss

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='CAF=dkzy=9fRdhtBx1nbQAGXoCFbwcx=CA6Jty5HGG0NEM_a6Gw@mail.gmail.com' \
    --to=sbbrouwer@gmail.com \
    --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).