[luatex] \mathchardef\foo=\mathcode`\x
jfbu
jfbu at free.fr
Fri Dec 18 23:02:29 CET 2015
Le 18 déc. 2015 à 22:57, jfbu <jfbu at free.fr> a écrit :
> Hi David,
>
>>
>> [snip]
>> David
>>
>> For people wanting to use amsmath, a fix would be to change line 741
>> of amsmath,sty so it looks something like
>>
>> \ifx\hyphenationmin\undefined
>> \mathchardef\std at minus\mathcode`\-\relax
>> \mathchardef\std at equal\mathcode`\=\relax
>> \AtBeginDocument{%
>> \mathchardef\std at minus\mathcode`\-\relax
>> \mathchardef\std at equal\mathcode`\=\relax
>> }
>> \else
>> \Umathcharnumdef\std at minus\Umathcodenum`\-\relax
>> \Umathcharnumdef\std at equal\Umathcodenum`\=\relax
>> \AtBeginDocument{%
>> \Umathcharnumdef\std at minus\Umathcodenum`\-\relax
>> \Umathcharnumdef\std at equal\Umathcodenum`\=\relax
>> }
>> \fi
>
> I thought package lualatex-math by Philipp Stephani addressed
> these amsmath problems with \std at minus and \std at equal already ?
>
> as per mathastext.sty package, it already does the right thing
> but in a rather brutal way regarding \@newmcodes macro or amsmath
>
> (it replaces it by \relax :-( )
sorry, please read \newcodes@, used in \DeclareMathOperator and doing
\gdef\newmcodes@{\mathcode`\'39\mathcode`\*42\mathcode`\."613A%
\ifnum\mathcode`\-=45 \else
\mathchardef\std at minus\mathcode`\-\relax
\fi
\mathcode`\-45\mathcode`\/47\mathcode`\:"603A\relax}
which has the \mathcode/\mathchardef issue if one has assigned
an Umathcode to -
best
Jean-François
More information about the luatex
mailing list