Set the Style Properties for Text Ranges : TextRange « Components « Flex

Home
Flex
1.Chart
2.Components
3.Container
4.Data Model
5.Development
6.Effects
7.Event
8.Graphics
9.Grid
10.Style
Flex » Components » TextRangeScreenshots 
Set the Style Properties for Text Ranges
Set the Style Properties for Text Ranges
             
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
    <mx:VBox >
        <mx:Script>
            
                import mx.controls.textClasses.TextRange;
    
                private function alterTextSnapshot():void
                {
                    var textRange:TextRange = new TextRange(area, true, area.selectionBeginIndex, area.selectionEndIndex);
                    textRange.color = 0xff0000;
                    textRange.letterSpacing = 3;
                }
    
          
        </mx:Script>
        <mx:TextArea change="alterTextSnapshot()" id="area" text="this is a test" width="200" height="50"/>
    </mx:VBox>
</mx:Application>

   
    
    
    
    
    
    
    
    
    
    
    
    
  
Related examples in the same category
1.Set html text to TextRangeSet html text to TextRange
2.Set color for TextRangeSet color for TextRange
3.Set font size for TextRangeSet font size for TextRange
4.Set font style for TextRangeSet font style for TextRange
5.Set font weight for TextRangeSet font weight for TextRange
6.Set selection range for TextRangeSet selection range for TextRange
7.TextRange Selected TextTextRange Selected Text
w_ww.ja__va__2__s__._com_ | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.