Re: Is the behavior of NSTextView's insertNewline documented anywhere?
Re: Is the behavior of NSTextView's insertNewline documented anywhere?
- Subject: Re: Is the behavior of NSTextView's insertNewline documented anywhere?
- From: Peter Seibel <email@hidden>
- Date: Wed, 17 Jan 2007 09:26:34 -0800
On Jan 17, 2007, at 1:17 AM, Martin Wierschin wrote:
It appears that if you type two newlines at the end of a list it
tries to un-nest one list level, stripping the NSTextList from the
paragraph style and deleting back to the beginning of the line. If
anyone can explain that I'd be grateful.
Probably because it thinks the user is trying to terminate the
list. You'll see that MS Word behaves the same way.
Yup. The question is why is it taking it upon itself to delete text
that it didn't insert. I'd get it if the NSTextView took care of
inserting list markers for you but it doesn't. So I wrote the code to
do it and then was surprised to discover that the text view was
deleting them for me. Which is actually almost what I wanted (to
implement the same, auto-end-of-list behavior you described) but is
hard to deal with when there is nothing in any of the docs I've seen
that mentions that it does this. Thus I'm wondering if there are docs
I haven't seen. I've looked at the NSTextView and NSText class docs
and most, if not all, of the text system architecture docs.
-Peter
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden