设置NumericStepper组件圆角半径.

cornerRadius样式学习.
示例:

代码:

<? xml version="1.0" encoding="utf-8" ?>
<!--  http://blog.flexexamples.com/2008/05/13/setting-the-corner-radius-on-a-numericstepper-control-in-flex/  -->
< mx:Application  xmlns:mx ="http://www.adobe.com/2006/mxml"
        layout
="vertical"
        verticalAlign
="middle"
        backgroundColor
="white" >

    
< mx:Script >
        
<![CDATA[
            private function init():void {
                slider.value = numericStepper.getStyle("cornerRadius");
            }
        
]]>
    
</ mx:Script >

    
< mx:ApplicationControlBar  dock ="true" >
        
< mx:Form  styleName ="plain" >
            
< mx:FormItem  label ="cornerRadius:" >
                
< mx:HSlider  id ="slider"
                        minimum
="0"
                        maximum
="10"
                        liveDragging
="true"
                        snapInterval
="1"
                        tickInterval
="1"   />
            
</ mx:FormItem >
        
</ mx:Form >
    
</ mx:ApplicationControlBar >

    
< mx:NumericStepper  id ="numericStepper"
            cornerRadius
=" {slider.value} "
            initialize
="init();"   />

</ mx:Application >

你可能感兴趣的:(组件)