小编Dan*_*iel的帖子

AS3 TextField设置文本的上边距,因为一些字符被删除

我想弄清楚为什么有些字母(比如挪威语Å(Å))在顶部"o"的中间切出:

我的代码是这样的:

        var titleFormat:TextFormat = new TextFormat();
        titleFormat.size = textSize;
           // this is embedded font, and exported for action script, declared
        titleFormat.font = myFontBold.fontName;
        titleFormat.bold = true;
        titleFormat.color = parseInt("0x"+fontColor,16);

        var titleText:TextField = new TextField();
        titleText.defaultTextFormat = titleFormat;
        titleText.embedFonts = true;            
        titleText.antiAliasType = AntiAliasType.ADVANCED;
        titleText.text = "Å"+text;
        addChild(titleText);

        titleText.selectable = false;           
        titleText.wordWrap = true;          
        titleText.width = maskImg.width - 80;           
          // this should autosize to fit all text, but it doesn't the top of text
        titleText.autoSize = TextFieldAutoSize.LEFT;
        titleText.x = x; …
Run Code Online (Sandbox Code Playgroud)

flash margin actionscript-3 textfield

5
推荐指数
1
解决办法
2598
查看次数

标签 统计

actionscript-3 ×1

flash ×1

margin ×1

textfield ×1