\type gives different results in footnotes
Dear list, I have the following sample: \starttext \type{{\em\de Textsatzsystem}} \footnote{\type{{\em\de Textsatzsystem}}.} \stoptext Only in the footnote \em has an extra unrequired space. I don’t have no idea about how TeX works here. As I wrote in a previous message, this is far beyond my understanding. Is there no way to have the same results in footnote? Many thanks for your help, Pablo -- http://www.ousia.tk
On 5/26/2014 9:28 PM, Pablo Rodriguez wrote:
Dear list,
I have the following sample:
\starttext \type{{\em\de Textsatzsystem}} \footnote{\type{{\em\de Textsatzsystem}}.} \stoptext
Only in the footnote \em has an extra unrequired space.
I don’t have no idea about how TeX works here. As I wrote in a previous message, this is far beyond my understanding.
It has to do with catcodes and tex adding a space after a stringified \cs so passing as argument is fragile. There is already some magic in place for \foo{bar} cases so I've added a (less tested) aggressive option 'absolute'. \definetype[TeXcodeA][option=TEX] \definetype[TeXcodeB][option=TEX,compact=all] \definetype[TeXcodeC][option=TEX,compact=absolute] \def\argA#1{\TeXcodeA{{#1}}} \def\argB#1{\TeXcodeB{{#1}}} \def\argC#1{\TeXcodeC{{#1}}} \starttext \startlines \argA {\em\de Textsatzsystem} \argB {\em\de Textsatzsystem} \argC {\em\de Textsatzsystem} \TeXcodeA{{\em\de Textsatzsystem}} \TeXcodeB{{\em\de Textsatzsystem}} \TeXcodeC{{\em\de Textsatzsystem}} \blank \argA {\em \de Textsatzsystem} \argB {\em \de Textsatzsystem} \argC {\em \de Textsatzsystem} \TeXcodeA{{\em \de Textsatzsystem}} \TeXcodeB{{\em \de Textsatzsystem}} \TeXcodeC{{\em \de Textsatzsystem}} \stoplines \stoptext In uploaded beta.
Is there no way to have the same results in footnote?
Many thanks for your help,
Pablo
-- ----------------------------------------------------------------- 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 -----------------------------------------------------------------
On 05/26/2014 10:12 PM, Hans Hagen wrote:
On 5/26/2014 9:28 PM, Pablo Rodriguez wrote:
[...] \starttext \type{{\em\de Textsatzsystem}} \footnote{\type{{\em\de Textsatzsystem}}.} \stoptext
Only in the footnote \em has an extra unrequired space.
I don’t have no idea about how TeX works here. As I wrote in a previous message, this is far beyond my understanding.
It has to do with catcodes and tex adding a space after a stringified \cs so passing as argument is fragile. There is already some magic in place for \foo{bar} cases so I've added a (less tested) aggressive option 'absolute'. [...] In uploaded beta.
Many thanks for your fast fix, Hans. Pablo -- http://www.ousia.tk
participants (2)
-
Hans Hagen
-
Pablo Rodriguez