Flex 4中组件背景设置(填充方式)group为例子
2011-03-20 16:09
501 查看
以下以Group为例子讲述如何在Flex 4中填充背景颜色、图片:
1、图片填充方式:
<s:Group x="0" y="0" height="100%" width="100%">
<s:Rect x="0" y="0" height="100%" width="100%">
<s:fill>
<s:BitmapFill source="@Embed('../imges/myBg.jpg')"/>
</s:fill>
</s:Rect>
</s:Group>
2、渐变色填充方式:
<s:Rect alpha="0.5" x="0" y="0" width="100%" height="100%">
<s:fill>
<s:LinearGradient rotation="250">
<s:GradientEntry color="0x222222" ratio="0"/>
<s:GradientEntry color="0xdddddd" ratio="1"/>
</s:LinearGradient>
</s:fill>
</s:Rect>
1、图片填充方式:
<s:Group x="0" y="0" height="100%" width="100%">
<s:Rect x="0" y="0" height="100%" width="100%">
<s:fill>
<s:BitmapFill source="@Embed('../imges/myBg.jpg')"/>
</s:fill>
</s:Rect>
</s:Group>
2、渐变色填充方式:
<s:Rect alpha="0.5" x="0" y="0" width="100%" height="100%">
<s:fill>
<s:LinearGradient rotation="250">
<s:GradientEntry color="0x222222" ratio="0"/>
<s:GradientEntry color="0xdddddd" ratio="1"/>
</s:LinearGradient>
</s:fill>
</s:Rect>
相关文章推荐
- Flex 4中组件背景设置(填充方式)group为例子
- Flex 4中组件背景设置(填充方式)group为例子
- Flex中通过设置fillColors样式改变ComboBox控件的填充背景颜色的例子
- flex中如何设置Alert背景图片的例子
- Flex中如何通过enabled属性在RadioButtonGroup中将所有的RadioButton设置为有效或无效状态的例子
- flex 给group填充背景图片、颜色
- ios-day15-05(Quartz 2D之一张图片以平铺或者填充的方式设置为UIView的背景、以填充的方式为UIView设置条纹背景)
- Flex的NumericStepper控件中如何通过textAlign样式设置文本对齐方式的例子
- Flex 4中如何给Panel设置bitmap填充背景色的例子
- Flex中通过设置opaqueBackground属性给RadioButton控件设置不透明的背景颜色的例子
- Flex中如何通过设置backgroundColor和backgroundAlpha改变DateChooser控件背景颜色的例子
- Flex中通过backgroundColor和backgroundAlpha样式设置NumericStepper控件背景颜色和透明度的例子
- Flex中通过设置borderColor样式和.errorTip CSS分离器改变错误信息提示背景颜色(background color)的例子
- Flex中如何通过设置backgroundAlpha风格来设定VideoDisplay控件的背景透明度(background alpha)的例子
- Flex中通过textAlign样式在一个按钮(Button)控件中设置标签(label)对齐方式的例子
- Flex中如何通过设置GridLines对象的horizontalAlternateFill样式交错显示LineSeries图表背景颜色的例子
- flex4:中DataGroup组件获取数据源(ArrayCollection方式)实例
- Flex中如何通过设置textAlign样式设定DateField中选中日期对齐方式的例子
- Flex中通过设置textAlign和labelStyleName样式设置FormItem容器中标签文本对齐方式的例子
- flex 给group填充背景图片、颜色