开发者

how to add childs to canvas in varius orders

I need help to add childs to canvas. I want to add childs 开发者_StackOverflow社区to canvas in top-down direction and left-right direction? I'm using the addChild function but I don't want to calculate the X and the Y for each Item. is there a way to do that?


You can add a mx:HBox or a mx:VBox to your canvas.

These components lay their children out like you require:

<mx:Canvas width="100%" height="100%">
    <mx:VBox id="verticalLayout" width="100%" height="100%" />
</mx:Canvas>

Calling "addChild" on the "verticalLayout" component will add each child under the previous.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜