Package net.sf.latexdraw.glib.models.interfaces.prop.ITextProp

Examples of net.sf.latexdraw.glib.models.interfaces.prop.ITextProp.TextSize


      shape.setPosition(text.getX(), text.getY());
    }
    else
      throw new IllegalArgumentException();

    TextSize textSize;
    try { textSize = TextSize.getTextSizeFromSize(Double.valueOf(elt.getAttribute(SVGAttributes.SVG_FONT_SIZE)).intValue()); }
    catch(final Exception e) { textSize = null; }

    if(textSize!=null)
      shape.setText("\\" + textSize.getLatexToken() + '{' + shape.getText().replace("&", "\\&") + '}'); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$

    if(SVGAttributes.SVG_FONT_WEIGHT_BOLD.equals(elt.getAttribute(SVGAttributes.SVG_FONT_WEIGHT)))
      shape.setText("\\textbf{" + shape.getText() + '}'); //$NON-NLS-1$

    if(SVGAttributes.SVG_FONT_STYLE_ITALIC.equals(elt.getAttribute(SVGAttributes.SVG_FONT_STYLE)))
View Full Code Here

TOP

Related Classes of net.sf.latexdraw.glib.models.interfaces.prop.ITextProp.TextSize

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.