Sometimes cornerRadius just isn't enough
Two tips for coders new to Flex... if you want to have rounded corners in mx.containers like VBox, HBox, Canvas, etc, set the borderStyle to solid and the borderThickness to 0, and then set your cornerRadius to whatever you want. If the borderStyle is left at none (default), the cornerRadius attribute seems broken and ineffective.
The second tip, if you want rounded corners at the top and bottom of your Panel, there's a property called roundedBottomCorners which defaults to false. When set to true, you will see rounding both top and bottom.
Here's an example http://www.crazedcoders.com/demos/rounded/
I should point out that this has been blogged previously here.
5 comments:
Thankx a lot!!!
That helped me too...
you rock! thanks so much for posting this. i never would have guessed that's how to make rounded corners work with canvas. i struggled with it for an hour before i found your post. big ups.
Really thanks!
Thanks, helped me too
I've run into this numerous times, and I always seem to forget. Thanks for reminding me!
As I remember, the dropShadow property has similar issues.
Post a Comment