程序包 net.top_t
类 LaTexConvert
java.lang.Object
net.top_t.LaTexConvert
public class LaTexConvert
extends java.lang.Object
LaTextConvert used to convert LaTex code
-
字段概要
-
构造器概要
构造器 构造器 说明 LaTexConvert() -
方法概要
修饰符和类型 方法 说明 static java.lang.StringlatexToSvgCode(java.lang.String latex, boolean fontAsShapes, boolean bkgTransparent)convert LaTex code to .svg codestatic voidmain(java.lang.String[] args)private static voidsvgTo(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, int type, java.io.File output)convert LaTex code to given file type. support PDF/PS/EPS filestatic voidtoEps(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File epsFile)convert LaTex code to eps filestatic voidtoPdf(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File pdfFile)convert LaTex code to a .pdf filestatic voidtoPngFile(java.lang.String latexString, java.io.File pngFile, boolean isTransparent)convert LaTex code to .png filestatic voidtoPs(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File psFile)convert LaTex code to ps filestatic voidtoSvgFile(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File svgFile)convert LaTex code to .svg file从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
字段详细资料
-
构造器详细资料
-
LaTexConvert
public LaTexConvert()
-
-
方法详细资料
-
latexToSvgCode
public static java.lang.String latexToSvgCode(java.lang.String latex, boolean fontAsShapes, boolean bkgTransparent) throws java.io.IOExceptionconvert LaTex code to .svg code- 参数:
latex- LaTex codefontAsShapes- use shapebkgTransparent- if set background color to be transparent- 返回:
- 抛出:
java.io.IOException
-
toSvgFile
public static void toSvgFile(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File svgFile)convert LaTex code to .svg file- 参数:
latexCode- LaTex formulafontAsShapes- font as shapesbkgTransparent- set background to be transparentsvgFile-
-
toPngFile
public static void toPngFile(java.lang.String latexString, java.io.File pngFile, boolean isTransparent) throws java.io.IOExceptionconvert LaTex code to .png file- 参数:
latexString- LaTex formulapngFile- File object, where the png file will be stored toisTransparent- set the background color to be transparent- 抛出:
java.io.IOException
-
toPdf
public static void toPdf(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File pdfFile) throws org.apache.batik.transcoder.TranscoderException, java.io.IOExceptionconvert LaTex code to a .pdf file- 参数:
latexCode- LaTex codefontAsShapes- it can be set to true/falsebkgTransparent- background color is transparent or notpdfFile- File object of PDF- 抛出:
org.apache.batik.transcoder.TranscoderExceptionjava.io.IOException
-
toPs
public static void toPs(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File psFile) throws java.io.IOException, org.apache.batik.transcoder.TranscoderExceptionconvert LaTex code to ps file- 参数:
latexCode- LaTex codefontAsShapes- it can be set to true/falsebkgTransparent- background color is transparent or notpsFile- File object of ps- 抛出:
java.io.IOExceptionorg.apache.batik.transcoder.TranscoderException
-
toEps
public static void toEps(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, java.io.File epsFile) throws java.io.IOException, org.apache.batik.transcoder.TranscoderExceptionconvert LaTex code to eps file- 参数:
latexCode- LaTex codefontAsShapes- it can be set to true/falsebkgTransparent- background color is transparent or notepsFile- file object of eps- 抛出:
java.io.IOExceptionorg.apache.batik.transcoder.TranscoderException
-
svgTo
private static void svgTo(java.lang.String latexCode, boolean fontAsShapes, boolean bkgTransparent, int type, java.io.File output) throws java.io.IOException, org.apache.batik.transcoder.TranscoderExceptionconvert LaTex code to given file type. support PDF/PS/EPS file- 参数:
latexCode- LaTex codefontAsShapes- it can be set to true/falsebkgTransparent- background color is transparent or nottype- file type of PDF, PS, EPSoutput- file of output- 抛出:
java.io.IOExceptionorg.apache.batik.transcoder.TranscoderException
-
main
public static void main(java.lang.String[] args)
-