Skip to main content
Participant
October 24, 2009
Question

Export TextFlow and after import TextFlow inlineGraphics not visible

  • October 24, 2009
  • 1 reply
  • 774 views

I load  a previous export TextFlow as follow :

var xmlOut:XML = TextConverter.export(evt.textFlow,TextConverter.TEXT_LAYOUT_FORMAT,ConversionType.XML_TYPE) as XML

But in my xmlOut my inlineGraphicElement as source="[object Bitmap]"  it's not a uri.

When i load this Texflow my pitures not visibles (not loading in bacground).

Help me please, I'm not understand.

This topic has been closed for replies.

1 reply

Adobe Employee
October 26, 2009

I would suggest that you attach some identifying information to the InlineGraphicElement as a user style, and use that information when you reload the xml to hook up the DisplayObjects to the InlineGraphicElements.

So you would use the setStyle function on the InlineGraphicElement to add you identifying information, for instance setStyle("graphicID", "511"). This is just a way to tag the InlineGraphicElement so you can hook it up to the image later. When you export the TextFlow, you should see the "graphicID" as an attribute on the image. Then when you import the TextFlow, loop through all the InlineGraphicElements in it and set their graphic properties appropriately.

Hope this helps,

- robin

Participating Frequently
October 26, 2009

An alternative to the last step in Robin's solution (loop through all the InlineGraphicElements in it and set their graphic properties appropriately) is to use IConfiguration.inlineGraphicResolver. This callback will be invoked by TLF before the inline graphic is composed. You can return the desired source for the inline graphic from the callback.

Abhishek

Adobe Systems Inc.