Some IDL Tricks

Other FONT stuff:

If you have annotations in which you use a carriage return, you may
feel that the lines are too close to one another (this becomes
pronounced when you have subscripts or superscripts!)  You can fix the
line spacing (and font size) with the SET_CHARACTER_SIZE to
DEVICE. Here is what IDL has to say about it:

     Set this keyword equal to a two-element vector to specify the
     font size and line spacing (leading) of vector and TrueType fonts, 
     and the line spacing of device fonts. The way that the value of this
     vector determines character size is not completely intuitive.

If you're interested in the weirdness, read about it in the Online
Help under SET_CHARACTER_SIZE. The character size will often change if
you change fonts. To find current character size, check the system
variables !D.X_CH_SIZE & !D.Y_CH_SIZE.

Suppose you're using TrueType or PostScript fonts for your axes, but
you want to include a different font, like the symbol font? It's easy
if you're using vector fonts... there are embedded formatting commands
like !7 in vector fonts that tell IDL to switch to another font.  Here
are the current embedded formatting commands:

 Command  Vector Font	          TrueType Font	        PostScript Font	
 !3	  Simplex Roman (default) Helvetica	        Helvetica	
 !4       Simplex Greek	          Helvetica Bold        Helvetica Bold	
 !5       Duplex Roman	          Helvetica Italic      Helvetica Narrow
 !6	  Complex Roman	          Helvetica Bold Italic	Helvetica Narrow 
                                                        Bold Oblique	
 !7	  Complex Greek	          Times	                Times Roman	
 !8	  Complex Italic	  Times Italic	        Times Bold Italic
 !9	  Math/special characters Symbol	        Symbol	
 !M	  Math/special characters Symbol	        Symbol
          (change effective for 
	   one character only)	
 !10	  Special characters	  Symbol *	        Zapf Dingbats	
 !11(!G)  Gothic English	  Courier          	Courier	
 !12(!W)  Simplex Script	  Courier Italic  	Courier Oblique	
 !13	  Complex Script 	  Courier Bold	        Palatino	
 !14	  Gothic Italian	  Courier Bold Italic	Palatino Italic	
 !15	  Gothic German	          Times Bold	        Palatino Bold	
 !16	  Cyrillic	          Times Bold Italic	Palatino Bold Italic
 !17	  Triplex Roman           Helvetica *	        Avant Garde Book
 !18	  Triplex Italic	  Helvetica *	        New Century Schoolbook
 !19		                  Helvetica *	        New Century Schoolbook
 !20	  Miscellaneous	          Helvetica *	        Undefined User Font
 !X	  Revert to the entry 	  Revert to the entry 	Revert to the entry
          font                    font                  font
* The font assigned to this index may be replaced in a future release of IDL.

You may be using PostScript fonts and want to use the Bookman Demi
Italic with ISOLatin1 font encoding for one of your math
symbols... this is not one of the current embedded formatting options.
Therefore, IDL lets you replace one of the font indices with this
font.  Here's how you do this: Let's replace the "Zapf Dingbats" PS
font in the !10 font index.

   IDL> plot, findgen(3), FONT=0, $
   IDL>   xtit='Galactic Radius !10'+string(174B)+'!X [kpc]', $
   IDL>   ytit='Density !10'+string(181B)+'!X [cm!E-3!N]'
   IDL> psclose

You CANNOT change font indices like this for TrueType or vector
fonts!  Only PostScript fonts!