3 ms·
> Good thing you didn't bother, because it's absolutely not worth it. The biggest thing LuaTeX gives you is variou hooks and access to various data structures
by svat 6y ago
> Good thing you didn't bother, because it's absolutely not worth it.
The biggest thing LuaTeX gives you is variou hooks and access to various data structures used internally by the typesetting engine, so that you can work with them directly instead of having to do everything in a roundabout way through macro expansion. If all you need is text expansion then sure, just use TeX/LaTeX macros. (You mentioned "try to do something with text that embeds LaTeX macros"; I think working at the text level like that is a sign that your problem, or at least your solution, may not be a good fit for what LuaTeX gives.)
Here are a couple of my answers where LuaTeX was valuable; you can find hundreds more (IMO) by others:
- https://tex.stackexchange.com/a/379802 https://tex.stackexchange.com/a/379802 Avoid getting short words at line edges: Note that the macro-level solution runs into issues with \ref etc (just as you said about text that embed LaTeX macros), but the LuaTeX solution works perfectly in all cases
- https://tex.stackexchange.com/a/401315 https://tex.stackexchange.com/a/401315 Letter-spacing
- https://tex.stackexchange.com/a/403353 https://tex.stackexchange.com/a/403353 Typesetting on a poster with some image cut out
- https://tex.stackexchange.com/a/416772 https://tex.stackexchange.com/a/416772 Doing text replacements based on TeX macro state (maybe this could be done without LuaTeX?)
- https://tex.stackexchange.com/a/414013 https://tex.stackexchange.com/a/414013 Inserting random kerning
I do completely agree with your recommendation of generating TeX/LaTeX if possible (and keeping the macros/LaTeX to a minimum).