I've got some complex code giving me an error:
! You can't use '\vadjust' in vertical mode.
So I presume I need to switch to the horizontal mode. I've found this question, "What are vertical and horizontal modes?", but nothing explaining how to switch between them.
I've looked at the TeXbook
, but nothing seems to answer this question.
How do switch between the two?
\vadjust
; just say\ifvmode<...>\else\vadjust{<...>}\fi
.\ifvmode
it ends up skipping the code which is supposed to typeset some numbers properly vertically spaced.\vadjust
is for adding vertical material when we're in horizontal mode, so I can't understand why you need to use it in the first place. However, the way to ensure being in horizontal mode (which starts a paragraph, if issued in vertical mode) is\leavevmode
.