API documentation for visualization library

Michael Galloy

single page | use frames     summary     class     fields     routine details     file attributes

text/

vis_tex2idl.pro

includes main-level program

Converts simple TeX notation to IDL format codes used in graphics output. Only handles subscripts, superscripts, and sequences listed below.

Other file information

Todo:

should be able to handle fractions too, use 190 (276 octal) to draw fraction bars, and !A/!B to go above/below the bar; decide whether to use \frac{1}{2}

Routines

result = vis_subsuper(token, level=long)

Translate TeX superscript (^) or subscript (_) to proper IDL format codes.

result = vis_matchdelim(input)

Returns the position in the input string of the closing curly brace that matches the first open curly brace, -1L if not found.

result = vis_strcnt(input, substr)

Count number of occurrences of a substring in a string.

result = vis_nexttoken(str, tokens [, position=long])

Find the next token in a given string.

result = vis_token(str, token)

Find a substring in an input string, return the portion of the input string before the substring, and modify the input string to contain only the portion of the string after the token.

result = vis_convert_subsuper(input [, level=long])

Convert TeX superscripts and subscripts in a given string to IDL format codes.

result = vis_convert_fraction(input [, /postscript])

Convert TeX fractions in a given string to IDL format codes.

result = vis_textable( [/postscript])

Returns table containing allowable TeX sequences and their translation to IDL.

result = vis_tex2idl(input [, font=long])

Convert a TeX string to a string with embedded IDL format codes.

Routine details

top vis_subsuper

result = vis_subsuper(token, level=long)

Translate TeX superscript (^) or subscript (_) to proper IDL format codes.

Return value

string

Parameters

token in required type=string

either ^ or _, others will return an empty string

Keywords

level in required type=long

set to subscript/superscript level to get appropriate format code

top vis_matchdelim

result = vis_matchdelim(input)

Returns the position in the input string of the closing curly brace that matches the first open curly brace, -1L if not found.

Return value

long

Parameters

input in required type=string

input string to search

top vis_strcnt

result = vis_strcnt(input, substr)

Count number of occurrences of a substring in a string.

Parameters

input in required type=string

string to search

substr in required type=string

substring to search for

top vis_nexttoken

result = vis_nexttoken(str, tokens [, position=long])

Find the next token in a given string.

Return value

string

Parameters

str in required type=string

string to search

tokens in required type=string

tokens

Keywords

position out optional type=long

position in str of next token

top vis_token

result = vis_token(str, token)

Find a substring in an input string, return the portion of the input string before the substring, and modify the input string to contain only the portion of the string after the token.

Return value

string

Parameters

str in out required type=string

input string; the output value of this string is the remaining portion of the string after the token

token in required type=string

substring to find in the input string

top vis_convert_subsuper

result = vis_convert_subsuper(input [, level=long])

Convert TeX superscripts and subscripts in a given string to IDL format codes.

Return value

string

Parameters

input in required type=string

input string to process

Keywords

level in optional type=long

set to subscript/superscipt level to indicate which format code is used to format it (and hence !E and !I are used instead of !U and !D)

top vis_convert_fraction

result = vis_convert_fraction(input [, /postscript])

Convert TeX fractions in a given string to IDL format codes.

Return value

string

Parameters

input in required type=string

input string to process

Keywords

postscript in optional type=boolean

set to use postscript fonts

top vis_textable

result = vis_textable( [/postscript])

Returns table containing allowable TeX sequences and their translation to IDL.

Return value

strarr(2, n)

Keywords

postscript in optional type=boolean

set to use postscript fonts

top vis_tex2idl

result = vis_tex2idl(input [, font=long])

Convert a TeX string to a string with embedded IDL format codes.

Return value

string or strarr

Parameters

input in required type=string/strarr

input TeX string or strarr

Keywords

font in optional type=long

set to -1 to translate for vector fonts, 0 for hardware fonts

File attributes

Modification date: Mon Nov 29 18:32:37 2010
Lines: 607
Docformat: rst rst