LaTeX Pictures

LaTeX Pictures
Version 4.0
September 21, 2026

\int_{-1}^{1} \frac{T_n(x) T_m(x)}{\sqrt{1 - x^2}} \, dx = \begin{cases} 0 & m \neq n \\ \pi/2 & m = n \neq 0 \\ \pi & m = n = 0 \end{cases}

About LaTeX Pictures

The LaTeX Pictures.ipf and LaTeX Palettes.ipf procedure files implement a user interface for creating high-quality typeset mathematical equations using the LaTeX markup language.

Igor 7 or later is required. No installation of any LaTeX-related software is required, but an active and working internet connection is. If your copy of Igor can open this url, your internet connection should be fine:

Print FetchURL("http://www.wavemetrics.net")[0,60]

CodeCogs - An Open Source Scientific Library

The pictures are rendered by the online API for the CodeCogs Equation Editor at:

https://editor.codecogs.com/docs/4-LaTeX_rendering.php

Please comply with their Fair Usage Policy:

https://editor.codecogs.com/support/3-fair_usage.php/

CodeCogs - An Open Source Scientific Library

Picture Formats

The LaTeX markup is rendered into PNG or (on Macintosh)  PDF or (on Windows) PNG format and inserted into Igor annotations or drawn with DrawPICT (Igor's drawing tools). Igor 9 and later can also use PDF on Windows.

Installation

Place everything in your Igor Pro <version> Users folder, inside the "User Procedures" sub folder.

Select "Show Igor Pro User Files" from Igor's Help menu.

Move the following items into the now-visible "User Procedures" folder:
 

  • LaTeX Palettes (folder)
  • LaTeX Palettes.ipf (procedure file)
  • LaTeX Pictures.ipf (procedure file)

LaTeX Syntax

See the "LaTeX Help" button in the panel and search online for "LaTeX math mode syntax" to learn what kinds of
LaTeX commands will work with this implementation.

The LaTeX rendered at https://editor.codecogs.com/docs/4-LaTeX_rendering.php supports base LaTeX math plus amsmath and amssymb, in math mode, with no package loading and no macro definitions.

Core LaTeX math plus the amsmath and amssymb packages are preloaded, so the large majority of standard math notation (fractions, roots, integrals, sums, matrices, aligned environments, arrays, boxed content, the math font families, Greek and its variants, and calculus operators) works normally. 

Using the LaTeX Pictures Panel

To open the LaTeX Pictures panel, enter the following in your Igor experiment's Procedure window:

#include "LaTeX Pictures"

Close the Procedure window (or click Compile).
A new LaTeX menu should appear.
Choose "LaTeX Pictures" from the menu.

Either enter the LaTeX markup text directly into the "Enter LaTeX Expression" area or click the "LaTeX Palettes" popup to first load and then select the LaTeX palette(s) to build up an expression.


Bring the Graph, Layout, or Panel window you want to add the LaTeX picture to to the front, then click either New Annotation (or New DrawPICT).


To add equations to Notebook windows, use the Copy Picture button and then paste into the Notebook.


Choose "_new_" from the LaTeX Pictures popup menu to start editing a new equation.


You can select a previously created equation from the same popup menu.


If you change the LaTeX markup text manually, you'll need to click the Update Picture button, but other settings update immediately if you have LaTeX Auto Update checked in the LaTeX menu. Unlike graphs, layouts or panels, notebook equations do not update when you modify a LaTeX Picture this way.

Using LaTeX Palettes

Clicking in a palette inserts the markup into the expressions area. Some markups incorporate the selected text into the result.

For example:
 

  • Type "a_1b^2" into the "Enter LaTeX Expression" area. This is LaTeX markup for a1b2.
  • Now select what you just typed.
  • Choose the "Accents and Bars" palette, scroll down to the square root of x+y.
  • Click the square root of x+y item.
  • Your selection is transformed into "\sqrt{a_1b^2}", and the resulting picture is shown:

If you look at the bottom of the "Accents and Bars" palette, you'll see that the LaTeX markup for the selected cell is shown as "\sqrt{#x+y#}", which is non-standard LaTeX; the # symbol is used to delimit the part that gets replaced by the selected text.

If there's no selection then the # symbols are removed and the remainder is inserted, which in this example would be "\sqrt{x+y}".

Customizing LaTeX Palettes

You can make your own palettes or amend the palettes provided. The Create LaTeX Palettes menu item displays a panel for loading, building, changing, and saving LaTeX palette waves and files.
 

Click the "About LaTeX Pictures" for details on customizing or creating LaTeX palettes.

Compatibility

PNG is most compatible between Macintosh and Windows.

PDF is supported by Igor 6 or later on Macintosh and on Igor 9 and later on Windows.

Because PNG is only a bitmap format, you might want to render a large bitmap and shrink it down to preserve sharpness when printing at high resolution. That's what the "Shrink DrawPICTs by" setting is for.

Project Details

Current Project Release

LaTeX Pictures 4.0

Release File: LaTeX Pictures 4.0.zip (927.86 KB)
Version: 4.0
Version Date:
Version Major: 4
Version Patch Level: 0
OS Compatibility: WindowsMac-Intel
Release Notes:

Version 4.0 is has many usability improvements and more comprehensive LaTeX palettes.
Igor 9 or 10 recommended, should work back to Igor 7. 

View All Releases
jjweimer

Nicely done. I am finding that the Sans (sic) Serif font choice shows up as serif (see the picture). Also, the header says comic sans was removed but these code lines remain ...

	// Font
	char font[kFontNameBytes]			// "Comic Sans;Computer Modern;Helvetica;San Serif;Verdana;"


	String font=""	// default
	strswitch(ts.font)
		default:
		case "San Serif":
			break
		case "Verdana":
			font= "\\fn_jvn "	// the trailing space is required
			break
		case "Comic Sans":
			font= "\\fn_cs "	// the trailing space is required
			break
		case "Computer Modern":
			font= "\\fn_cm "	// the trailing space is required
			break
		case "Helvetica":
			font= "\\fn_phv "	// the trailing space is required
			break
	endswitch

Based on CodeCogs setFont command, the default font family is Latin Modern, which is serif IIRC. The improvement to the font family selection is as below.

	String font=""	// default
	strswitch(ts.font)
		// serif font families
		case "Latin Modern":    // default
			break
		case "Computer Modern":
			font= "\\fn_cmb "	// the trailing space is required -- NOTE MISSING "b" HERE
			break
		// sans serif font families
		case "Verdana":
			font= "\\fn_jvn "	// the trailing space is required
			break
		case "Helvetica":
			font= "\\fn_phv "	// the trailing space is required
			break
		case "Sans Serif 1":
			font= "\\fn_tx "	// the trailing space is required
			break
		case "Sans Serif 2":
			font= "\\fn_px "	// the trailing space is required
			break
	endswitch

 

example.png (164.55 KB)
JimProuty

I've updated the help file with the revised links.

I have added the fair usage to the procedure windows that implement LaTeX Pictures.

As to the "integrate" suggestion, perhaps you mean integrate true LaTeX into annotations, etc?

Igor 8 does have a subset of LaTex built-in:

DisplayHelpTopic "Igor TeX"

Forum

Support

Gallery

Igor Pro 10

Learn More

Igor XOP Toolkit

Learn More

Igor NIDAQ Tools MX

Learn More