Package com.tinyline.tiny2d

Examples of com.tinyline.tiny2d.TinyFont


   public static TinyFont getFont() {
        if (font != null)
            return font;

        /* Create TinyFont object. */
        font = new TinyFont();
        font.horizAdvX = 904;
        font.fontFamily = new TinyString("MyArial".toCharArray());
        font.unitsPerEm = 2048;
        font.ascent = 1854;
        font.descent = -434;
View Full Code Here


        int wH = daWidth(tile) >> 1;
        int hH = daHeight(tile) >> 1;
        int stoneSize = daWidth(tile);
        int fontSize = stoneSize;
        TinyFont font = MyArial.getFont();

        char[] text = label.toCharArray();
        TinyRect cbox;
        // calculate fontSize, so the number fits into stone
        while (true) {
View Full Code Here

        if (commentLines <= 0)
            return;

        Tiny2D t2d = getT2D(tile);
        TinyFont font = MyArial.getFont();
        int commentFontSize = daHeight(tile) / commentLines;
        //int commentFontDescent = commentFontSize * font.descent / font.unitsPerEm;
        int commentFontAscent = commentFontSize * font.ascent / font.unitsPerEm;
        TinyColor fgColor = new TinyColor(commentFgColor);

View Full Code Here

TOP

Related Classes of com.tinyline.tiny2d.TinyFont

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.