I am trying to create a new math alphabet on LuaLaTeX, based on the code of mathspec. I set up a font family with some options via fontspec and declare it as an alphabet. Although it seems to work, LuaLaTex ignores the options.

Specifically, I borrowed the following lines from mathspec:


    \zf@fontspec{Style = Swash}{Arno Pro Italic}

When I use $\mymathcal{N}$, for example, LuaLaTeX prints a standard italic N instead of its swash version. On the other hand, XeLaTeX works fine (after changing the encoding scheme).

Do you know how I could fix this issue?


You have to use Renderer=Basic. There are also far better ways to define the font, with the newer versions of fontspec


\newfontfamily{\mynonswashfont}{Cochineal}[] % just for testing



{\mynonswashfont\itshape ABCDEFHIJKLMNOPQRSTUVWXYZ}



{\mynonswashfont\itshape Q}

{\myswashfont\itshape Q}


enter image description here

You can see that the third line (with \mymathcal) has the same output as the last one.

  • Thank you! It's perfect. Thanks for fixing the question too! – Luca B. May 15 '16 at 14:45

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.