开发者

How to pass an option containing a space to a package in LaTeX/XeLaTeX

开发者 https://www.devze.com 2022-12-27 07:03 出处:网络
When I declare an option containing a space, LaTeX/XeLaTeX eats it. In the main .tex, I have : \\usepackage[test font]{test}

When I declare an option containing a space, LaTeX/XeLaTeX eats it.

In the main .tex, I have :

\usepackage[test font]{test}

In my .sty file I have :

\DeclareOption*{\newfontfamily\testfont[Scale=1]{\CurrentOption}}
\Proce开发者_如何转开发ssOptions

But the Tex engine passes to the package testfont option and not test font.

So the question is how to pass the option containing the space to the package.


Protect it with braces

\usepackage[{test font}]{test}


Try


\catcode`\ =11
\usepackage[test font]{test}
\catcode`\ =10

This is quite likely to fail, but the failure might be progress on what we have so far.

0

精彩评论

暂无评论...
验证码 换一张
取 消