1 | Copyright (C) 1996 The Regents of the University of California, All |
---|
2 | Rights Reserved. Written by Matthew W. Craig. |
---|
3 | |
---|
4 | |
---|
5 | PURPOSE: |
---|
6 | The purpose of the TeXtoIDL routines is to make it simple to use Greek |
---|
7 | letters, subscripts and superscripts in making labels for plots in |
---|
8 | IDL. This is accomplished by allowing the user to use TeX control |
---|
9 | sequences for Greek letters and special symbols and for |
---|
10 | sub/superscripts. The TeX control sequences are simple and easy to |
---|
11 | remember, especially if you already use TeX for writing papers (for |
---|
12 | those unfamiliar with TeX, an explanation of that notation is below). |
---|
13 | The translation is done for either vector or PostScript fonts. |
---|
14 | |
---|
15 | BUGS: |
---|
16 | Please report any bugs you find or suggestions for improvement to: |
---|
17 | mcraig@mnstate.edu |
---|
18 | |
---|
19 | FILES: |
---|
20 | For a list of the files in this distribution see the file FILES. |
---|
21 | For a list of one line descriptions of the routines in this |
---|
22 | distribution, see the file DESCRIPTIONS. |
---|
23 | |
---|
24 | INSTALLATION: |
---|
25 | Put these routines somewhere in you IDL path. |
---|
26 | |
---|
27 | USE: |
---|
28 | Once installed, type (in IDL): |
---|
29 | IDL> print,TeXtoIDL(/HELP) |
---|
30 | for brief instructions. The command SHOWTeX will display the |
---|
31 | available TeX sequences on the current graphics device. In addition, |
---|
32 | subscripts and superscripts in the usual TeX notation are available. |
---|
33 | For more details on what TeX notation is, see the section |
---|
34 | INTRO TO TeX, below. |
---|
35 | |
---|
36 | EXAMPLE: |
---|
37 | If you type. . . |
---|
38 | IDL> str = TeXtoIDL("\rho^2 + 2\Gamma_{ij}") |
---|
39 | IDL> help, str |
---|
40 | STR STRING = '!7q!X!U2!N + 2!7C!X!Dij!N' |
---|
41 | IDL> xyouts,.5,.5,str,CHARSIZE=2.,/NORM |
---|
42 | |
---|
43 | then on the screen you will see the Greek letter rho with a 2 in the |
---|
44 | exponent, and then a + and then a 2 and then the uppercase Greek |
---|
45 | letter gamma, with an "ij" in the subscript. |
---|
46 | |
---|
47 | VERSION: |
---|
48 | You are using version $Name: Rel_2_1_2 $ of TeXtoIDL. |
---|
49 | |
---|
50 | REVISION HISTORY: |
---|
51 | See the file VERSIONS. |
---|
52 | |
---|
53 | LEGALITIES: |
---|
54 | For copyright and redistribution restrictions, see the file |
---|
55 | COPYRIGHT. |
---|
56 | |
---|
57 | This software is provided on an "as is" basis, and has absolutely |
---|
58 | NO warranty. For more details, see the file DISCLAIMER. |
---|
59 | |
---|
60 | INTRO TO TeX: |
---|
61 | TeX is a typesetting language which makes including equations in |
---|
62 | manuscripts very easy. In particular, it has an easy to remember |
---|
63 | syntax for including Greek letters, special symbols, and subscripts |
---|
64 | and superscripts. These routines emulate the behavior of TeX, |
---|
65 | allowing its syntax to be used in making IDL plot labels and the |
---|
66 | like. |
---|
67 | |
---|
68 | The TeX syntax for Greek letters is simple. If you want, for |
---|
69 | example, the Greek letter "rho", just type "\rho" and you will get it. |
---|
70 | The IDL string for "rho" is "!7q!X" (for vector fonts) or "!Mr!X" (for |
---|
71 | PostScript fonts). In any event, the IDL strings are not easy to |
---|
72 | remember, and depend on the font type. If you type SHOWTEX at the IDL |
---|
73 | command line, a table will be made on the current graphics device |
---|
74 | showing which Greek letters and special symbols are available, and |
---|
75 | what they look like on your graphics device. |
---|
76 | |
---|
77 | The syntax for sub/superscripts is also simple. An example will make |
---|
78 | it clear. If I write "N_{sub}", I will get an "N" with the subscript |
---|
79 | "sub". The underscore begins the subscript, and everything enclosed |
---|
80 | in the braces is in the subscript. Superscripts are similar; |
---|
81 | "N^{sup}" is an "N" with a superscript "sup". Since it is frequent to |
---|
82 | have one character sub- or superscripts, braces are not needed for a |
---|
83 | one character script. So "N^2" makes an "N" with a "2" in the |
---|
84 | exponent. You can combine sub and superscripts, for example |
---|
85 | "N^2_{sub}", and you can even put subscripts on the things in your |
---|
86 | superscripts, e.g. "N^{N_j}", though this probably won't look very |
---|
87 | good. |
---|