Discarding the last TextLine and trying again with a new width
Hi all,
I'm using TextBlock to create a paragraph. This paragraph has regions which do not render any text (so that I could put some images down within the generated text in a way more similiar to CSS float styles. BTW, I'm not trying to achieve an inline image rendering; I know that is possble already with TextBlock).
So, my problem:
If one of these 'block out' regions are close to the boundary of the overall paragraph region, then this is the result:

In the left column, because those words are not broken on natural word breaks, createTextLine results in TextLineCreationResult.EMERGENCY.
That's great--I can detect this situation from the API. However, I can't figure out what to do once I'm aware of it!
What I want to do is this: I want to throw away any EMERGENCY TextLine (I've tried releaseLines), and then 'rewind' one createTextLine attempt so that I can try to generate the next TextLine using the same context as before the EMERGENCY failed attempt.
For clarity, this would mean in the above image, I'd hope to just discard the 'achi', 'year', 'repr', 'won', 'digr', 'prog', 'achi' TextLines on that thin left column... meaning only whitespace would occur in that thin column. On the first line of the right of that skipped block, you'd see 'achievement' on the first broken line, because the 'achi' would be considered during the next createTextLine() attempt.
Regards,
Seth
