I'm trying to add link attributes to the NSMutableString of a NSTextView
.
Since I only want to add the link to the visible text with the text view, I observe the NSScrollView
for scrolling changes with the NSViewBoundsDidChangeNotification
notification of the NSScrollView
's contentView.
When the notification selector is called, I add a link attribute to the string. But unfortunately the notification is called immediately after I've added the link attribute to the string. And this goes on and on forever - since adding the link changes the view's bounds.
Is there anything I miss here? Is this a Lion only issue?