Re: No NSTextContainer being returned for glyph range
Re: No NSTextContainer being returned for glyph range
- Subject: Re: No NSTextContainer being returned for glyph range
- From: Douglas Davidson <email@hidden>
- Date: Wed, 6 Sep 2006 17:23:13 -0700
On Sep 6, 2006, at 4:49 PM, Mike R. Manzano wrote:
The configuration is one layout manager to many containers, each
with a view.
I do have
layoutManager:didCompleteLayoutForTextContainer:atEnd:
defined to add containers like the TextEdit example.
Because of this I assume layout will finish and end in a state
where there's a container for all glyphs before the NSAssert1 line.
I'm not sure exactly what's happening in your particular case, but in
general when the layout manager fills up the last container it will
assign the nil text container to all subsequent glyphs, then your
layout manager did-complete delegate method will be called, it will
add another container, and at that point layout will be invalidated
for the glyphs beyond the previous last text container. So if you
happen to ask at the wrong time, you may see some glyphs with the nil
text container. To help figure out what's going on, you can break at
that point, see how many text containers you have, and see what the
glyph ranges are for each of them--that should show the layout
manager's state.
Douglas Davidson
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden