|
Stud.IP
2.2 Revision 48548
|

Public Member Functions | |
| LatexRender ($picture_path, $picture_path_httpd, $format="math") | |
| getErrorString () | |
| setFormat ($format, $template) | |
| setPicturePath ($name) | |
| getPicturePath () | |
| setPicturePathHTTPD ($name) | |
| getPicturePathHTTPD () | |
| getFormulaURL ($latex_formula) | |
| wrap_latex ($latex_text) | |
| getDimensions ($filename) | |
| renderLatex ($latex_text) | |
| cleanTemporaryDirectory () | |
Data Fields | |
| $_picture_path = "" | |
| $_picture_path_httpd = "" | |
| $_tmp_dir = "/tmp" | |
| $_latex_path = "/usr/bin/latex" | |
| $_dvips_path = "/usr/bin/dvips" | |
| $_convert_path = "/usr/bin/convert" | |
| $_identify_path = "/usr/bin/identify" | |
| $_formula_density = 120 | |
| $_xsize_limit = 1024 | |
| $_ysize_limit = 700 | |
| $_tmp_filename | |
| $_format = '' | |
| $_template = '' | |
| $_latex_tags_blacklist | |
| $_err_string = '' | |
| cleanTemporaryDirectory | ( | ) |
Cleans the temporary directory
| getDimensions | ( | $filename | ) |
/** returns the dimensions of a picture file using 'identify' of the imagemagick tools. The resulting array can be adressed with either $dim[0] / $dim[1] or $dim["x"] / $dim["y"]
| string | path to a picture |
| getErrorString | ( | ) |
| getFormulaURL | ( | $latex_formula | ) |
Tries to match the LaTeX Formula given as argument against the formula cache. If the picture has not been rendered before, it'll try to render the formula and drop it in the picture cache directory.
| string | formula in LaTeX format |

| getPicturePath | ( | ) |
Picture path Mutator function

| getPicturePathHTTPD | ( | ) |
Picture path HTTPD Mutator function

| LatexRender | ( | $picture_path, | |
| $picture_path_httpd, | |||
$format = "math" |
|||
| ) |
Initializes the class
| string | path where the rendered pictures should be stored |
| string | same path, but from the httpd chroot |
| renderLatex | ( | $latex_text | ) |
Renders a LaTeX formula by the using the following method:
| string | LaTeX formula |

| setFormat | ( | $format, | |
| $template | |||
| ) |
Format mutator function
| string | sets the current format |
| setPicturePath | ( | $name | ) |
Picture path Mutator function
| string | sets the current picture path to a new location |
| setPicturePathHTTPD | ( | $name | ) |
Picture path HTTPD Mutator function
| string | sets the current httpd picture path to a new location |
| wrap_latex | ( | $latex_text | ) |
wraps a minimalistic LaTeX document around the formula and returns a string containing the whole document as string. Customize if you want other fonts for example.
| string | formula in LaTeX format |
| $_convert_path = "/usr/bin/convert" |
| $_dvips_path = "/usr/bin/dvips" |
| $_err_string = '' |
| $_format = '' |
| $_formula_density = 120 |
| $_identify_path = "/usr/bin/identify" |
| $_latex_path = "/usr/bin/latex" |
| $_latex_tags_blacklist |
| $_picture_path = "" |
| $_picture_path_httpd = "" |
| $_template = '' |
| $_tmp_dir = "/tmp" |
| $_tmp_filename |
| $_xsize_limit = 1024 |
| $_ysize_limit = 700 |