uliska / lilyglyphs

Make LilyPond's notational elements available in Lua- and XeLaTeX
30 stars 13 forks source link

Undefined control sequence error #91

Closed Josef-Friedrich closed 5 years ago

Josef-Friedrich commented 7 years ago

On the latest TeXlive 2016

%!TEX program = lualatex
\documentclass{article}
\usepackage{lilyglyphs}
\begin{document}
\wholeNote
\end{document}

I got this error:

(/usr/local/texlive/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg))
! Undefined control sequence.
<argument> {\fontspec 
           [Scale=\lilyEffectiveScale ]{emmentaler-\lilyOpticalSuffix .otf}\lil
l.6 \end
      {document}
? 
[1{/usr/local/texlive/texmf-var/fonts/map/pdftex/updmap/pdftex.map}]
(./test.aux))

I used lualatex to compile the test file. By the way thank you for this great package.

uliska commented 7 years ago

Thanks for the report.

The problem is that fontspec isn't loaded in your file. Obviously this should be in the package itself, and I didn't notice that because any of my document classes or fundamental sytle sheets do include it anyway.

So while I can't say how long it will take for this change to get into TeXLive you can simply insert

\usepackage{fontspec}

somewhere in the preamble. This may be before or after the lilyglyphs include, but I suggest to place it immediately before.

Josef-Friedrich commented 7 years ago

Thank you very much!