It’s difficult for me to spend much time interacting with a major-mode and not
find something to tweak. Even when that mode is my oldest companion in the world
of Emacs, something will surely pop up. So it’s only fitting that in the final
week of my thesis submission deadline I start tinkering with latex-mode again.
I wrote the following snippet after compiling a recent Emacs snapshot which
defines a myriad of rules for prettify-symbols-mode in tex-mode. Equations
become much easier to read when you replace the verbose math symbols like
\alpha with α, but that only makes all the LaTeX styling commands stand out
even more. Suddenly, all those \left, \right, \! and \;, are sticking
out like that mole on a hag’s nose.
What do we do about that? We hide them away. Not completely, of course. We still
need to see those commands. We just tuck them away a little, where we can see
them without having to see them.
Here’s a sample of what it might look like for you.
Improving LaTeX equations with font-lock
19 Oct 2015, by Artur Malabarba.It’s difficult for me to spend much time interacting with a major-mode and not find something to tweak. Even when that mode is my oldest companion in the world of Emacs, something will surely pop up. So it’s only fitting that in the final week of my thesis submission deadline I start tinkering with
latex-mode
again.I wrote the following snippet after compiling a recent Emacs snapshot which defines a myriad of rules for
prettify-symbols-mode
intex-mode
. Equations become much easier to read when you replace the verbose math symbols like\alpha
withα
, but that only makes all the LaTeX styling commands stand out even more. Suddenly, all those\left
,\right
,\!
and\;
, are sticking out like that mole on a hag’s nose.What do we do about that? We hide them away. Not completely, of course. We still need to see those commands. We just tuck them away a little, where we can see them without having to see them.
Here’s a sample of what it might look like for you.
Tags: font-lock, latex, init.el, emacs,
Beacon — Never lose your cursor again »
« Paradoxical Hydras
Related Posts
Longlines mode in LaTeX in latex
Content © 2019, All rights reserved. Icons under CC3.0.