Heh, whoops. Maybe I should read the documentation better. The warning is already there, I just missed it:

"NSTextStorage also defines a set of methods ... useful for getting and setting scriptable properties of NSTextStorage objects... In particular, using thecharacters, words or paragraphs methods or their corresponding setter methods is an inefficient way to manipulate the text storage, since these methods create and return many objects."

-Steven

On Jun 4, 2008, at 4:04 PM, Douglas Davidson wrote:

Anything in NSTextStorageScripting.h (like -paragraphs) is really intended for scripting only; stay away from it for other purposes. You should file a bug against the documentation to include a warning to that effect. If you want to go through text by paragraphs, you should use [[textStorage string] paragraphRangeForRange:] or related methods.

Douglas Davidson


_______________________________________________

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