在Flex中调整子画布的大小

时间:2012-01-18 20:13:36

标签: flash actionscript-3 flex mxml

我正在试图弄清楚如何调整儿童画布的大小,但我无法弄明白。

我在这样的父画布周围有一堆迷你画布:

<mx:Canvas width="10" height="10" backgroundColor="#040404" top="0" left="0" id="anchorTL" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" right="0" top="0" id="anchorTR" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" horizontalCenter="0" top="0" id="anchorTM" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" verticalCenter="0" left="0" id="anchorML" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" left="0" bottom="0" id="anchorBL" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" horizontalCenter="0" bottom="0" id="anchorBM" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" bottom="0" right="0" id="anchorBR" />
    <mx:Canvas width="10" height="10" backgroundColor="#040404" right="0" verticalCenter="0" id="anchorMR" />

每种类型的调整大小(左上角,右下角等)

如何在点击并按住时调整画布大小?

1 个答案:

答案 0 :(得分:2)

那里已经有一个组件可以为你做这个(我之前尝试过编写这个组件,它并不像表面上那样简单)。

http://www.objecthandles.com/

^如果这对您有用或者您有更具体的需求,请告诉我。