In the Gumbo SDK I was using I was able to load an Illustrator FXG file into the displayList, dive inside and see all the components - groups, paths, radialGradients etc. With the FlashBuilder 4 I have just downloaded, I can still load the FXG and view, but the inside seems to consist of MovieClip and Shape objects without any of the e.g. Path winding="nonZero" data="M4.35889 data that I am used to seeing. This is what I am doing:
import comp.Flower3; // import Flower.fxg from comp folder
displayGroup = new Group();
var source2:Flower3 = new comp.Flower3();
// Flower appears in VBox as it did with earlier Gumbo sdk
getFxgData(displayGroup.getChildAt(0) as DisplayObjectContainer); // call function to inspect fxg elements
private function getFxgData(container:DisplayObjectContainer):void
var counter:uint = 1;
for (var i:uint=0; i < container.numChildren; i++) // look at all fxg elements to find group tags
child = container.getChildAt(i);
if (child is Group) // child is Group so process
In FlashBuilder 4 the child is Group never fires because there are no longer any Groups found within the fxg ..... cannot find any docs on what changed ... any help much appreciated, TIA
The Flex 4 SDK now compiles .fxg files directly to SWF graphics primitive tags.
If you need an ActionScript representation of the graphics at runtime, you need to migrate the .fxg to .mxml files. There are a few option in the beta to achieve this - send me an email offline firstname.lastname@example.org and I should be able to help you.