【问题标题】:flex 4 textinput skin background colorflex 4 textinput 皮肤背景颜色
【发布时间】:2011-07-25 14:10:11
【问题描述】:

我正在尝试更改 flex 4 中 textinput 组件的背景颜色。我已经能够通过弄乱 Flash 生成器为 sparkskin 生成的固定代码来更改某些外观,但由于某种原因,背景确实如此什么都没有。

我只是想让背景变黑。我更改了背景颜色,但它不起作用:

<!-- fill -->
<!--- Defines the appearance of the TextInput component's background. -->
<s:Rect id="background" left="1" right="1" top="1" bottom="1">
    <s:fill>
        <!--- @private Defines the background fill color. -->
        <s:SolidColor id="bgFill" color="0x000000" />
    </s:fill>
</s:Rect>

【问题讨论】:

    标签: apache-flex flex4 skinning


    【解决方案1】:

    看看行:

        /* Define the content fill items that should be colored by the "contentBackgroundColor" style. */
        static private const contentFill:Array = ["bgFill"];
    

    所以在你的情况下删除不需要的 id:

    <s:Rect id="background" left="1" right="1" top="1" bottom="1">
        <s:fill>
            <!--- @private Defines the background fill color. -->
            <s:SolidColor color="0x000000" />
        </s:fill>
    </s:Rect>
    

    并删除上面列出的行。

    【讨论】:

    • 感谢您的快速响应。我还必须注释掉另一行,但删除 id 有效。谢谢!
    猜你喜欢
    • 2011-06-05
    • 2012-11-05
    • 1970-01-01
    • 2011-03-24
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-08-09
    相关资源
    最近更新 更多