On Oct 9, 2014, at 11:19 AM, Charles Jenkins <cejw...@gmail.com> wrote:

> Well, I was imprecise. I didn’t literally mean the text view would directly 
> change the table view. Right now the text container and text view adjust 
> automatically to fit the text, but my code isn’t told about any changes, so I 
> have no opportunity to do anything to change the table view.  
> 
> But once again I think you might have said the magic word, and this time it 
> is “notification.” Tonight I’ll do research on notifications. I see NSView 
> offers NSBoundsDidChangeNotification and NSFrameDidChangeNotification. If, as 
> I assume, NSTextView is a subclass of NSView, maybe I can make my Subdocument 
> register to receive such notifications from their text views, which would 
> give me the final piece of the puzzle.

Yes, it should work to observe the NSViewFrameDidChangeNotification from the 
text view.  I believe this is how NSClipView knows when the text view that's 
inside of a scroll view has changed its size, so the scroll view knows how much 
it can scroll.

Regards,
Ken


_______________________________________________

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:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to