textlayoutformat的最后一行左对齐

时间:2012-01-03 14:16:13

标签: flash flex flash-builder flex4.5

我为{tlf

设置了textLayoutFormat.textAlign = TextAlign.JUSTIFY;
sample text sample text sample text
sample text sample text sample text
             sample text

但看起来像这样

sample text sample text sample text
sample text sample text sample text
sample                         text

我想为最后一行设置左对齐。

1 个答案:

答案 0 :(得分:1)

使用textAlignLast属性。

示例:

<s:TextArea
    textAlign="justify"
    textAlignLast="right"
    text="sample text sample text sample text
    sample text sample text sample text
    sample text
    "/>

输出:

sample text sample text sample text
sample text sample text sample text
                        sample text

请注意textAlignLast仅适用于对齐文本。