Use Constraint-Based Layout for Containers
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute"> <mx:Canvas width="400" height="300"> <mx:Canvas left="20" right="20" top="20" bottom="50" id="innerCanvas"> <mx:Button label="Button Label" left="20" right="20" top="10"/> <mx:TextInput left="30" right="30" bottom="10"/> </mx:Canvas> </mx:Canvas> </mx:Application>