4

Using an \exe environment in a document with the class ‘standalone’ is problematic for me. Here’s a MWE:

\documentclass[12pt]{standalone}
\usepackage{gb4e}
\begin{document}
\begin{exe}
    \ex German:
    \gll Dies ist    ein            Test. \\
         This be.3SG INDEF.M.SG.NOM test. \\
    \glt “This is a test.”
\end{exe}
\end{document}

What happens is that I always get errors of the following kind:

! LaTeX Error: Something's wrong--perhaps a missing \item.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...                                              

l.8     \ex G
             erman:

Using \documentclass{article}, this code compiles without problems. It seems that standalone has a problem with the way gb4e uses lists to handle the individual rows in interlinear glosses?

The output should be a PDF/PNG file that looks like this:

Correctly formatted interlinear gloss

1

Use either preview or varwidth option.

\documentclass[12pt,varwidth,border=3]{standalone}
\usepackage{gb4e}
\begin{document}
\begin{exe}
    \ex German:
    \gll Dies ist    ein            Test. \\
         This be.3SG INDEF.M.SG.NOM test. \\
    \glt “This is a test.”
\end{exe}
\end{document}

enter image description here

  • Can someone explain why this works? – Azor Ahai Apr 25 '17 at 17:42

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.