Tagged Questions
10
votes
1answer
166 views
querying whether a font feature has been activated via a fontspec command
A LaTeX package I'm currently writing makes use of -- and definitely requires -- some of the power of LuaLaTeX. I would like to make my package's user interface -- in particular, the options that need ...
8
votes
2answers
158 views
\ifpdf returns true when using LuaLaTeX
The ifpdf package is supposed to detect if pdfTeX is running:
This package looks for pdfTeX in pdf mode and implements and sets the switch \ifpdf.
(from the ifpdf documentation)
However, when I ...
13
votes
4answers
423 views
Combining \ifxetex and \ifluatex with the logical OR operation
I want to write in the preamble of a LaTeX document code that should be take into account by different compilers when the document is typeset. There are fragments that should be used:
only by ...
0
votes
2answers
142 views
Conditional \endinput
I want to prevent processing rest part of a package in case if it is loaded not from lualatex. For some reason I cannot load ifluatex package, so I borrowed definition of \ifluatex from that package ...
7
votes
1answer
185 views
Testing for TeX boolean in Lua code
How can I test for a TeX boolean in Lua?
This kind of code doesn't work:
\newif\if@mypkg@someif
\begin{luacode}
-- some lua code
\if@mypkg@someif
-- some more lua code
\else
...
14
votes
3answers
424 views
Check if LuaTeX is running
I want to check if my tex document is compiled with LuaTeX (or any other Lua TeX compiler).
The simple approach from the TeXbook is to check the \directlua macro against \@empty, like
...