Next: , Previous: LaTeX fragments, Up: Embedded LaTeX

11.7.4 Previewing LaTeX fragments

If you have dvipng or imagemagick installed1, LaTeX fragments can be processed to produce preview images of the typeset expressions:

C-c C-x C-l
Produce a preview image of the LaTeX fragment at point and overlay it over the source code. If there is no fragment at point, process all fragments in the current entry (between two headlines). When called with a prefix argument, process the entire subtree. When called with two prefix arguments, or when the cursor is before the first headline, process the entire buffer.
C-c C-c
Remove the overlay preview images.

You can customize the variable org-format-latex-options to influence some aspects of the preview. In particular, the :scale (and for HTML export, :html-scale) property can be used to adjust the size of the preview images.

You can turn on the previewing of all LaTeX fragments in a file with

     #+STARTUP: latexpreview

To disable it, simply use

     #+STARTUP: nolatexpreview


[1] Choose the converter by setting the variable org-latex-create-formula-image-program accordingly.