Flex2 Fieldset Component
One thing that keeps driving me nuts is the lack of a "FieldSet" component, like the html tag of the same name, in Flex. So I wrote one.
This component is based on the base VBox component so all of the properties and methods of the VBox apply. Here is an example of using the component.
label="This is the fieldset legend"
borderStyle="solid" borderThickness="2" cornerRadius="10">
<mx:Label text="Label"/>
<mx:TextInput/>
</nimer:FieldSet>
Note: I've added this new component to the same .swc file as my DebugPanel component. Considering that the .swc now has more then one component, I've also renamed the .swc too. So, if you are already using the DebugPanel.swc you'll want to remove the link to that .swc file and create a new link to this nimerComponents.swc in your project.

1) Right-Click on your project, go to the properties option
2) Select the "Flex Build Path" property panel
3) Select the "Library Path" tab
4) Click on the "Add SWC" button and browse to the .swc file you want to add.
To use the component, from the swc (after you've added the swc to the project).
1) in the mxml file you want to add it, add another xmlns in the root tag. Right next to the xmlns:mx="" attribute.
2) for the example above you would use (this is the same as an Import)
xmlns:nimer="com.mikenimer.components.*"
3) call the tag, using the namespace prefix you defined in step 2.
<nimer:FieldSet>...</nimer:FieldSet>
does that help?
It looks fine in the compiled swf - just won't show up in design mode.
thanks for that sweet component! There is a little bug in it though, you shouldn't be calculating the leftPadding for your label, it shouldn't be supposed move. Otherwise great job!
I commented out that part in the FieldSet class and it's working fine:
//legend.setStyle("paddingLeft", cr);
thanks again!
A.
override protected function createChildren():void
{
legend = new Label();
legend.text = this.label;
legend.opaqueBackground = this.getStyle("backgroundColor");
this.addChild(legend);
super.createChildren();
}
http://needfornews.com/top_search.php
http://vidslib.com/
http://rssnewsdigest.com/top_search.php
http://stocknewssite.com
http://newssiteworld.com
http://newssiteguide.com
http://newssitedirect.com
http://reportsiteworld.com
http://funingame.busythumbs.com
http://www.phpweblog.net/funingame
http://funingame.blog.bokee.net