【问题标题】:Flex mx:Canvas label is seen nullFlex mx:Canvas 标签显示为空
【发布时间】:2017-11-08 19:45:20
【问题描述】:

问题是当标签不适合手风琴的大小时,标签的结尾会被视为“你好,我的名字 inull”而不是“你好,我的名字是 Can”。由于其他组件尺寸,我无法扩大手风琴的尺寸。 它可以看作是“你好,我的名字是..”,但是我冷没有找到解决方案。 我尝试了 truncateToFit="true" 标签,但我认为这里没有使用它。 这是弹性代码;

   <mx:Accordion x="0" y="2" width="200" height="100%" id="accSettings" styleName="accordionStyle">
            <mx:Canvas id="emptyCanvas" visible="false" includeInLayout="false">
            </mx:Canvas>
        </mx:Accordion>
        <mx:VBox visible="false" width="100%">
 <mx:Canvas id="screenToVMTab" label="Hello, my name is Can!" width="100%" height="100%">
                <mx:VBox width="100%" height="100%" verticalGap="0" id="vbScreenToVMTab" >
                </mx:VBox>
            </mx:Canvas>
    </mx:VBox>

另外,尝试删除高度和宽度标签,未修复。 谢谢!

【问题讨论】:

  • 我看到 VBox 的可见属性是假的。所以你不会看到 Canvas screenToVMTab。可以加个问题截图吗?

标签: flash canvas apache-flex adobe accordion


【解决方案1】:

试试这个:

<mx:Accordion left="2" top="2" width="130" bottom="2" id="accSettings" styleName="accordionStyle">
    <mx:Canvas id="emptyCanvas" label="Empty Canvas" visible="true" includeInLayout="true" width="100%" height="100%">
        <mx:Label text="Inside Empty Canvas." />
    </mx:Canvas>
    <mx:Canvas id="screenToVMTab" label="Hello, my name is Can!" width="100%" height="100%">
        <mx:VBox width="100%" height="100%" verticalGap="0" id="vbScreenToVMTab" >
            <mx:Label text="Inside VBox. Label 1"/>
            <mx:Label text="Inside VBox. Label 2"/>
        </mx:VBox>
    </mx:Canvas>
</mx:Accordion>

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2017-02-23
    • 2021-03-06
    • 1970-01-01
    • 1970-01-01
    • 2012-02-19
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多