Use Canvas to hold controls : Canvas « Components « Flex






Use Canvas to hold controls

Use Canvas to hold controls
          

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="vertical">
  <mx:Style>
  @namespace mx "http://www.adobe.com/2006/mxml";
    mx|TextInput { font-size:24 }
  </mx:Style>
  <mx:Canvas borderStyle="solid" borderColor="#000000" width="400" height="313">
    <mx:TextInput text="TextInput 1"/>
    <mx:TextInput text="TextInput 2" x="71" y="47"/>
    <mx:TextInput text="TextInput 3" x="141" y="97"/>
    
    <mx:VBox width="100" backgroundAlpha=".5" x="224" y="144"/>
    <mx:VBox width="100" height="100" backgroundAlpha=".5" x="249" y="169"/>
    <mx:VBox width="100" height="100" backgroundColor="#000000" backgroundAlpha=".5" x="274" y="194"/>
    
  </mx:Canvas>
  
</mx:Application>

   
    
    
    
    
    
    
    
    
    
  








Related examples in the same category

1.Scroll ticker symbols across the screen and lets users adjust the speed with an HSlider controlScroll ticker symbols across the screen and lets users adjust the speed with an HSlider control
2.Put Button into a CanvasPut Button into a Canvas
3.Use Canvas to wrap ButtonsUse Canvas to wrap Buttons
4.Set vertical center and horizontal center for Button inside a CanvasSet vertical center and horizontal center for Button inside a Canvas
5.uses constraint rows and constraint columns to position three Button controls in a Canvas container:uses constraint rows and constraint columns to position three Button controls in a Canvas container:
6.A Canvas container with two vertical regions and two horizontal regions
7.A single constraint column that occupies 20% of the Canvas area
8.Canvas background color whiteCanvas background color white
9.Creating a Canvas container by using constraint-based layoutCreating a Canvas container by using constraint-based layout
10.Use a semitransparent Canvas container to highlight the data pointUse a semitransparent Canvas container to highlight the data point
11.Canvas containerCanvas container
12.Canvas RepositionCanvas Reposition
13.Change Canvas cornerRadius and borderStyleChange Canvas cornerRadius and borderStyle
14.Canvas border style solidCanvas border style solid
15.Add style name to CanvasAdd style name to Canvas