【问题标题】:Actionscript3, Adobe Air for mobile: Alternative for bordercontainer?Actionscript 3,移动版 Adob​​e Air:边界容器的替代方案?
【发布时间】:2011-09-20 09:18:55
【问题描述】:

我正在使用 adobe air 创建一个移动应用程序。我想动态添加一个可以包含一些元素并具有边框和背景颜色的容器或组。由于这些是动态添加的,因此我使用 Actionscript 3。边框容器​​可以正常工作,但是根据:http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/spark/components/BorderContainer.html 此组件不适用于移动设备。

所以我的问题是:什么轻量级组件可以包含其他元素,并且具有可设置的背景颜色和边框?

【问题讨论】:

    标签: actionscript-3 mobile air


    【解决方案1】:

    尝试简单地使用 Group spark 组件。您将添加一个填充背景和实线的 Rect:

    <s:Group>
      <s:Rect>
         <s:stroke>
            <s:SolidColorStroke />
         </s:stroke>
         <s:fill>
            <s:SolidColor />
         </s:fill>
      </s:Rect>
    </s:Group>
    

    要获得额外的性能增强,您可能需要查看 FXG 预编译。关于here的一些文章。

    【讨论】:

      猜你喜欢
      • 2011-03-05
      • 2011-01-15
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2011-04-04
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多