Package org.scilab.forge.jlatexmath

Examples of org.scilab.forge.jlatexmath.TeXFormula


        xyzSE[0] = se1; xyzSE[1] = se2;  xyzSE[2] = se3;
        xyzSW[0] = sw1; xyzSW[1] = sw2;  xyzSW[2] = sw3;
       
        latexStr = _latexStr;
       
        TeXFormula formula = new TeXFormula(true, latexStr);
        TeXIcon icon = formula.createTeXIcon(TeXConstants.STYLE_DISPLAY, 20);
        icon.setInsets(new Insets(5, 5, 5, 5));

        img = new BufferedImage(icon.getIconWidth(), icon.getIconHeight(), BufferedImage.TYPE_INT_ARGB);
        Graphics2D g2 = img.createGraphics();
        g2.setColor(Color.white);
View Full Code Here


        plotAbsolute = true;
        xcoord = x;
        ycoord = y;
        latexStr = _latexStr;
       
        TeXFormula formula = new TeXFormula(true, latexStr);
        TeXIcon icon = formula.createTeXIcon(TeXConstants.STYLE_DISPLAY, 20);
        icon.setInsets(new Insets(5, 5, 5, 5));

        img = new BufferedImage(icon.getIconWidth(), icon.getIconHeight(), BufferedImage.TYPE_INT_ARGB);
        Graphics2D g2 = img.createGraphics();
        g2.setColor(Color.white);
View Full Code Here

   * see Text for formatted text output
   */
  public void plot(AbstractDrawer  draw) {
                  if (!visible) return;
   
                            TeXFormula formula = new TeXFormula(label);
                           
                            TeXIcon icon = formula.createTeXIcon(TeXConstants.STYLE_DISPLAY, size);
                            icon.setTeXIconColor(plotColor);
                            //icon.setInsets(new Insets(5, 5, 5, 5));

                            Graphics2D g2 = draw.getGraphics();
                            g2.setColor(plotColor);
View Full Code Here

            LatexImage tximg = new scalaSci.math.plot.plotObjects.LatexImage(latex, xcoord, ycoord);
            currentPlot.addPlotable(tximg);
        }
       
        public static void  latexRender(String latex)  {
                      TeXFormula tf = new TeXFormula(latex);
                      TeXIcon icontf = tf.createTeXIcon(TeXConstants.STYLE_DISPLAY, 20);
                      icontf.setInsets(new Insets(5, 5, 5, 5));
 
                      OutputTextPane otp = new OutputTextPane();
                      otp.addIcon(icontf,  0, true);
      JPanel jp = new JPanel();
View Full Code Here

  }

  public void setModel(final LatexExtension latexExtension) {
    model = latexExtension;
    try {
      teXFormula = new TeXFormula("\\begin{array}{l} \\raisebox{0}{ "
          +model.getEquation()
          +" } \\end{array}"
      );
      teXFormula.createTeXIcon(TeXConstants.STYLE_DISPLAY, DEFAULT_FONT_SIZE);
    }
    catch (final Exception e) {
      try {
        teXFormula = new TeXFormula("\\mbox{" + e.getMessage() + "}");
        teXFormula.createTeXIcon(TeXConstants.STYLE_DISPLAY, DEFAULT_FONT_SIZE);
      }
      catch (final Exception e1) {
        teXFormula = new TeXFormula("\\mbox{Can not parse given equation}");
      }
    }
    zoom = 0;
    revalidate();
    repaint();
View Full Code Here

    .append(rawText)
    .append("}");

//        LogUtils.severe(String.format("TeX='%s'", sb.toString()));

    TeXFormula tf = new TeXFormula(sb.toString());

        //tf.createTeXIcon(style, size, TeXConstants.UNIT_PIXEL, maxWidth, align, TeXConstants.UNIT_PIXEL, 40f);
    return tf.new TeXIconBuilder()
      .setStyle(style)
      .setSize(size)
View Full Code Here

TOP

Related Classes of org.scilab.forge.jlatexmath.TeXFormula

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.