Search code examples
unicodeemacslatexorg-mode

Emacs: automatically replace LaTeX to Unicode symbols


In Emacs I frequently use math symbols when I write my theory summaries of math textbooks. I use org-mode to structure information and I know about at least two methods of entering special symbols:

  1. Using embedded LaTeX: enter its representation in the form \land then press C-c C-x \ (org-toggle-pretty-entities) to view it literally;
  2. Using C-x 8 RET (insert-char).

I want it however to behave the following way: I enter the LaTeX representation, and it is automatically converted into the physical Unicode form (abbrev?). Is there a package for that and if not, what elisp should I write to implement this behavior?


Solution

  • M-x set-input-method RET TeX sounds like what you want.

    View available symbols by executing M-x describe-input-method RET TeX (or its binding C-h I).

    If you'll want to use this often, you can customize the variable default-input-method and set it to TeX. That way, you can activate the input method with C-\ (for toggle-input-method) in any buffer where you need it.