The uiPane component is a basic container that does not implement any automatic layout logic. You must position child objects manually via their x and y properties in the case of generic DisplayObject instances or the move(x,y) method in the case of uiComponent instances1).
You are most likely to use the uiPane component when defining the content for the uiScrollPane container, or if you wish to position and size your UI controls absolutely without the help of layout containers.
NOTE: A uiPane cannot use a skin. If you wish to render a skin as the background, put the uiPane inside a uiFrame container.
import com.ghostwire.ui.containers.uiPane; import com.ghostwire.ui.controls.uiCheckBox; import com.ghostwire.ui.controls.uiPushButton; var agreeBtn:uiCheckBox = new uiCheckBox("I accept the agreement"); agreeBtn.move(10,10); var nextBtn:uiPushButton = new uiPushButton("Next >>"); nextBtn.move(10,30); var agreePane:uiPane = new uiPane(); agreePane.addChild(agreeBtn) agreePane.addChild(nextBtn) // ** add to displaylist ** addChild(agreePane);
For more information on the members of the com.ghostwire.ui.containers.uiPane class, please refer to the API Reference.
x and y properties in the case of uiComponent instances but the use of the move() method is recommended.