3 ms·
Pretty neat! As a suggestion, I would replace also the delimiters "()\{\}[]" with the corresponding left/right versions [1] so LaTeX adjusts automatically the s
by gjulianm 12y ago
Pretty neat! As a suggestion, I would replace also the delimiters "()\{\}[]" with the corresponding left/right versions [1] so LaTeX adjusts automatically the size in the output and I don't have to deal with less readable code missing \left or \right errors.
As another tip to make LaTeX typesetting easier, I'd recommend using a custom keyboard distribution to input symbols easily, (e.g., alt + d for δ instead of \delta). In TeX.sx Jon Wickerson published [2] a layout for the british keyboard and the corresponding package to make LaTeX understand the unicode symbols. If you happen to have a spanish keyboard, I made an adaptation of that code [3].
And another thing: if you plan on using pretex a lot, it may be useful to parse the file on save (maybe before compilation). inotify-tools [4] or watchdog (OS X) [5] can help you, it's easy to create a script that will execute pretex whenever your LaTeX file changes.
Great work!
1: http://tex.stackexchange.com/questions/77589/what-do-the-pieces-of-latex-left-and-right-respectively-mean http://tex.stackexchange.com/questions/77589/what-do-the-pie...
2: http://tex.stackexchange.com/questions/110042/entering-unicode-math-symbols-into-latex-direct-from-keyboard-on-a-mac#110043 http://tex.stackexchange.com/questions/110042/entering-unico...
3: https://github.com/gjulianm/MathUnicode https://github.com/gjulianm/MathUnicode
4: https://github.com/rvoicilas/inotify-tools/wiki https://github.com/rvoicilas/inotify-tools/wiki
5: https://github.com/gorakhargosh/watchdog https://github.com/gorakhargosh/watchdog
- s9w 12y agoleft/right: I've thought a lot about this, and I'm still divided. The left/right system in Tex is not the greatest itself and sometimes produces unwanted output. I was thinking of using another "flag" before math envs to force this. Still not sure what's the right thing to do.
- gjulianm 12y agoEnvironment flags would be good. Another suggestion: per-file flags? if "% pretex delimiters" is present in the file, change delimiters; else, leave them alone.
- s9w 12y agoHmm yes configuration options need to expand beyond command line arguments. I'm still debating the best way. A separate json or cfg file would probably be too annoying? Latex comments would be a neat way, I like that