views:

123

answers:

1

in studying actionscript 3's graphics class, i've come across the undocumented drawRoundRectComplex() method. it's a variant of drawRoundRect() but with 8 parameters, the final four being the diameter of each corner (x, y, width, height, top left, top right, bottom left, bottom right).

//example
var sp:Sprite = new Sprite();
sp.graphics.lineStyle(1, 0x000000);
sp.graphics.drawRoundRectComplex(0, 0, 200, 150, 110, 50, 0, 10);
addChild(sp);

this seems to be a pretty useful method, so i'm just curious if anyone knows of any reasons why adobe chose not to document it?

+1  A: 

I believe it's documented in the mx.utils.GraphicUtils class.

Link.

Rev316
there it is. strange that it doesn't show up in blue in frame or actionscripts for flash cs4. i guess it's under-documented rather than undocumented.
TheDarkInI1978
is mx.utils.GraphicUtils a legacy class? if so would that make drawRoundRectComplex old also? is there something newer?
TheDarkInI1978
Formally I think everything in the mx.* package is Flex, or at least used to be. Offhand I suspect that the undocumented part is that Graphics implements what used to be a flex-only routine?
fenomas