NSTextView : Scroll top when bound-to string changes
NSTextView : Scroll top when bound-to string changes
- Subject: NSTextView : Scroll top when bound-to string changes
- From: Jerry Krinock <email@hidden>
- Date: Fri, 20 Jan 2012 05:33:36 -0800
I've bound the 'Attributed String' of an NSTextView. This view a detail view; its text changes whenever the user changes the selection in an associated table. Upon changing, the text scrolls to the bottom. I want it to stay at the top.
I understand that I can scroll back to the top by sending -scrollPoint:, -scrollRectToVisible:, or -scrollRangeToVisible:, but where would I do this? Invoking -performSelector:withObject:afterDelay: at then end of the getter would probably work, but it seems like such a simple programming requirement should not require such a kludge. Bindings are supposed to make my life easier!
Is there some kind of 'don't scroll' or 'stay scrolled to top' attribute I'm missing?
Thanks,
Jerry Krinock
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden