On Sat, May 10, 2008 at 2:19 AM, Graham Cox <[EMAIL PROTECTED]> wrote:
> What this suggests to me is that the text container needs to keep track of
> the previous non-zero remainder rect that it set, and if the proposedRect is
> the same, then it should return it unchanged, resetting the remainderRect.

I'm pretty sure you're interpreting this incorrectly.  Instead, it
sounds like you should, when given a proposed rectangle, move the left
edge of that rectangle to where the text may begin for your shape, and
then split that rectangle where the text may end.  The framework will
then recursively invoke your method on the remainder rectangle until
it equals NSZeroRect.

It's a standard greedy approach that should require no context.

--Kyle Sluder
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to