aspose.tex.plugins
The Aspose.TeX.Plugins is a root namespace for all classes of Aspose.TeX.Plugins classes.
Classes
Class | Description |
---|---|
FigureRendererPlugin | The Figure Renderer plugin class. The example shows how to render a LaTeX fragment in PNG. python<br/>from aspose.pydrawing import Color
<br/>from aspose.tex.plugins import FigureRendererPlugin, PngFigureRendererPluginOptions, StreamDataSource, StringDataSource
<br/>
<br/># Create the Figure Renderer.
<br/>renderer = FigureRendererPlugin()
<br/>options = PngFigureRendererPluginOptions()
<br/>options.background_color = Color.yellow
<br/>options.resolution = 150
<br/>options.margin = 10.0
<br/>options.preamble = "LaTeX preamble"
<br/>
<br/># Create the PngFigureRendererPluginOptions instance and set up options.
<br/>options = options
<br/># Add an input LaTeX fragment.
<br/>options.add_input_data_source(StringDataSource("LaTeX fragment"))
<br/># Create a stream to write the image to.
<br/>with open("output path", "wb") as stream:
<br/> # Add an output stream.
<br/> options.add_output_data_target(StreamDataSource(stream))
<br/> # Run the process.
<br/> result = renderer.process(options)
<br/><br/> |
FigureRendererPluginOptions | The options for the FigureRendererPlugin . |
FigureRendererPluginResult | The Figure Renderer plugin’s common result. |
IDataSource | The general data source interface. |
IOperationResult | The general operation result interface. |
IPlugin | The general plugin interface. |
IPluginOptions | The general plugin options interface. |
MathRendererPlugin | MathRenderer plugin class. The example shows how to render a LaTeX formula in PNG. python<br/>from aspose.pydrawing import Color
<br/>from aspose.tex.plugins import MathRendererPlugin, PngMathRendererPluginOptions, StreamDataSource, StringDataSource
<br/>
<br/># Create MathRenderer.
<br/>renderer = MathRendererPlugin()
<br/>options = PngMathRendererPluginOptions()
<br/>options.background_color = Color.yellow
<br/>options.text_color = Color.blue
<br/>options.resolution = 150
<br/>options.margin = 10.0
<br/>options.preamble = "LaTeX preamble"
<br/>
<br/># Create the PngMathRendererPluginOptions instance and set up options.
<br/>options = options
<br/># Add a source formula.
<br/>options.add_input_data_source(StringDataSource("LaTeX formula"))
<br/># Create a stream to write the image to.
<br/>with open("output path", "wb") as stream:
<br/> # Add an output stream.
<br/> options.add_output_data_target(StreamDataSource(stream))
<br/> # Run the process.
<br/> result = renderer.process(options)
<br/><br/> |
MathRendererPluginOptions | The options for the MathRendererPlugin . |
MathRendererPluginResult | The Math Renderer plugin’s common result. |
PngFigureRendererPluginOptions | The Figure Renderer plugin’s options to render a LaTeX figure in PNG. |
PngMathRendererPluginOptions | The Math Renderer plugin’s options to render a math formula in PNG. |
ResultContainer | The plugin execution result container. |
StreamDataSource | The stream data source for plugin’s load and save operations. |
StringDataSource | The string data source for plugin’s load operations. |
SvgFigureRendererPluginOptions | The Figure Renderer plugin’s options to render a LaTeX figure in SVG. |
SvgMathRendererPluginOptions | The Math Renderer plugin’s options to render a math formula in SVG. |
Enumerations
Enumeration | Description |
---|---|
DataType | Enumerates available data types for plugins I/O. |