[NTG-context] Character alignment in math mode

Hans Hagen pragma at wxs.nl
Wed Jun 25 09:50:49 CEST 2014

On 6/25/2014 12:29 AM, Wolfgang Schuster wrote:
> Am 24.06.2014 um 21:46 schrieb Maggyero <maggyero at gmail.com>:
>>> why  use math here?
>> It was to avoid oldstyle figures that I use by default. But finally it's better to use oldstyle figures even in tables.
> You can enable lining (and tabular) figures in the table when you don’t want oldstyle figures.
>> Another question about fonts. Is there a way to define a conditional mathcommand based on the current alternative style? For instance, in the following example I would like to keep the bold effect but with adaptation to the local alternative style (in text mode, when the local alternative style is \tf I would like the mathcommand to be \bf, when it is \it I would like \bi, when it is \bf I would like \bf and when it is \bi I would like still \bi):
> You can access the current font alternative with the \fontalternative command (below is a old example I wrote a few months ago).
> \def\Test
>    {\processaction
>       [\fontalternative]
> 	 [     tf=>Upright,
>             it=>Italic,
>             sl=>Slanted,
>             bf=>Bold,
>             bi=>Bolditalic,
>             bs=>Boldslanted,
>        unknown=>Unknown fontalternative]}
> \starttext
> “\Test” {\it “\Test”} {\bs “\Test”} {\sc “\Test”}
> \stoptext


a bit different output

                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl

More information about the ntg-context mailing list