RE: What is the preferred way to set NSTextView content from NSAttributedString?
RE: What is the preferred way to set NSTextView content from NSAttributedString?
- Subject: RE: What is the preferred way to set NSTextView content from NSAttributedString?
- From: Jonathan Prescott via Cocoa-dev <email@hidden>
- Date: Sun, 2 Feb 2020 15:19:08 -0500
Did you tell V that it needs to re-load it’s display? There is a method on
NSView (from which NSTextView is derived) called “needsDisplay(sic)” which sets
a flag on the view so that the view will re-draw its content the next display
cycle. So, after you set the content to T2, you need to call
“V.needsDisplay()” so that the next display cycle the view gets refreshed.
Need to check the spelling of the method.
Jonathan
_______________________________________________
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