
Hi....
What is FXG in flex4? can you give me the explanation about it..
Thanks

Ans:
FXG:
FXG is a declarative syntax for defining static graphics. You typically use a graphics tool such as Adobe Illustrator to export an FXG document, and then use the FXG document as an optimized component in your application.
For example:
FXG component:
<?xml version="1.0" encoding="utf-8"?>
<Graphic xmlns="http://ns.adobe.com/fxg/2008" version="2">
<Path data="
M 0 0 L 50 50 L 100 0 L 100 100 L 50 50 L 0 100 L 0 0 Z">
<stroke>
<SolidColorStroke color="#AAAAAA" weight="1"/>
</stroke>
<fill>
<RadialGradient>
<GradientEntry color="#000000" alpha="1.0"/>
<GradientEntry color="#AA0000" alpha="0.5"/>
</RadialGradient>
</fill>
</Path>
<Path data="
M 0 0 L 50 50 L 0 100 L 100 100 L 50 50 L 100 0 L 0 0 Z">
<stroke>
<SolidColorStroke color="#AAAAAA" weight="1"/>
</stroke>
<fill>
<RadialGradient>
<GradientEntry color="#000000" alpha="1.0"/>
<GradientEntry color="#00AA00" alpha="0.5"/>
</RadialGradient>
</fill>
</Path>
</Graphic>
main application:
<?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:mx="library://ns.adobe.com/flex/mx" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:comps="FXG.*"> <mx:Panel title="Path FXG Example" height="179" width="202" layout="horizontal" paddingTop="10" paddingBottom="10" paddingLeft="10" paddingRight="10"> <s:HGroup> <comps:path/> </s:HGroup> </mx:Panel> </s:Application>
If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.
Ask your questions, our development team will try to give answers to your questions.