Re: NSTextView scrolls to top on Save

2010-12-19 Thread Andy Lee
On Dec 18, 2010, at 10:38 PM, Andy Lee wrote: As a learning experience, I'm trying to make a trivial document-based app: a window with a text view that can edit and save RTF files. What I have now almost works, except that whenever I save changes, the text view scrolls to the top.

Re: NSTextView scrolls to top on Save

2010-12-19 Thread Kyle Sluder
On Sun, Dec 19, 2010 at 1:20 PM, Andy Lee ag...@mac.com wrote: I can understand why Apple wouldn't use a bindings-based solution for this example, since bindings is an advanced topic unto itself, but I think using an NSTextStorage would be appropriate given the context.  Unless someone

Re: NSTextView scrolls to top on Save

2010-12-19 Thread Andy Lee
On Dec 19, 2010, at 8:04 PM, Kyle Sluder wrote: On Sun, Dec 19, 2010 at 1:20 PM, Andy Lee ag...@mac.com wrote: I can understand why Apple wouldn't use a bindings-based solution for this example, since bindings is an advanced topic unto itself, but I think using an NSTextStorage would be

NSTextView scrolls to top on Save

2010-12-18 Thread Andy Lee
As a learning experience, I'm trying to make a trivial document-based app: a window with a text view that can edit and save RTF files. What I have now almost works, except that whenever I save changes, the text view scrolls to the top. Needless to say, this would be very annoying in a real