Skip to main content
Participating Frequently
August 31, 2009
Question

Avoid Freezing

  • August 31, 2009
  • 2 replies
  • 816 views

Hi.

When loading a long text using TextFilter.importToFlow, it freezes. (even with TextFlow.addChild(BIG_ELEMENT))

Could anyone tell me how to avoid it or if it is possible or not?

Thanks.

Yoshiki

This topic has been closed for replies.

2 replies

Participating Frequently
September 6, 2009

I figured out one cause of freezing.

In BaseTextLayoutImporter.as:431,
//var whiteArray:Array = txt.match(/^[\s]+$/);
strip = txt.search(/^[\u0009\u000a\u000d\u0020]+$/) != -1;

My code seems like working, but could anyone confirm this?

Also, in 409, if "for each" is replaced with "setInterval" or something, then it might be better for freezing, I think. I will try when I have time...

Thanks.

Yoshiki Okawa

Adobe Employee
September 1, 2009

How much markup are you importing?

You may need to divide your markup into smaller units - like chapters.  Check out the pagination example here:

http://blogs.adobe.com/tlf/2008/12/

Thanks,

Richard