Flex 4 Spark 面板有一个丑陋的灰色顶部
我有一个 Flex 4 Spark 面板,我通过 PopUpManager 弹出,但它的顶部有一个我无法摆脱的灰色部分。那是什么以及如何删除它?
更新:下面是一个示例面板。我只需在其上调用 PopUpManager.addPopUp(new TestPanel(), background, true);
即可收到按钮上方的实心灰色条。
<s:Panel xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fx="http://ns.adobe.com/mxml/2009"
dropShadowVisible="false"
backgroundAlpha="0"
controlBarVisible="false"
borderVisible="false">
<s:VGroup>
<s:Button label="A button" width="150" height="55"/>
</s:VGroup>
</s:Panel>
I have a Flex 4 spark Panel I'm popping up through the PopUpManager, but it has a gray portion at the top I can't get rid of. What is that and how can I remove it?
UPDATE: An example Panel is below. I simply call PopUpManager.addPopUp(new TestPanel(), background, true);
on it and receive that solid gray bar above the button.
<s:Panel xmlns:s="library://ns.adobe.com/flex/spark"
xmlns:fx="http://ns.adobe.com/mxml/2009"
dropShadowVisible="false"
backgroundAlpha="0"
controlBarVisible="false"
borderVisible="false">
<s:VGroup>
<s:Button label="A button" width="150" height="55"/>
</s:VGroup>
</s:Panel>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
所以,我就是这样做的。我制作了一个自定义皮肤: HeaderlessPanelSkin.as
然后,在面板中,我只需引用新皮肤:
skinClass="HeaderlessPanelSkin"
这样就可以了:)
So, this is how I did it. I made a custom skin: HeaderlessPanelSkin.as
Then, in the panel, I just reference the new skin:
skinClass="HeaderlessPanelSkin"
That should do it :)
创建新皮肤,并在面板声明中使用它......就像这样
文件->新建MXML Skin,Host Component为面板。
编辑皮肤属性以按照您的喜好进行更改,在本例中为标题上的渐变颜色。
Create new skin, and in the panel declaration use it... like so
File->New MXML Skin, Host Component is panel.
Edit the Skin properties to change it how you like, in this case the gradient colors on the header.
听起来像面板标题栏
创建自定义外观并按照您希望的显示方式设置标题栏的样式。
Sounds like the Panel TitleBar
Create a custom skin and style the title bar how you want it to appear.