NSTextView and setUsesFontPanel:
NSTextView and setUsesFontPanel:
- Subject: NSTextView and setUsesFontPanel:
- From: Duncan Campbell <email@hidden>
- Date: Wed, 30 Nov 2005 11:34:34 +1100
Hi list.
I have a little problem with NSTextView and setUsesFontPanel:
If I enable the font panel, then anywhere in my app that I use an
NSColorPanel (in my case, thru an NSColorwell) the color is also
applied to my textview.
I understand that this is because the textView and the colorwell are
both using the shared NSColorPanel, however I would like to stop this
from happening.
I can see 2 approaches:
1. create another instance of NSColorPanel and assign to my colorwell's.
2. override/intercept the color changing on the NSTextView and decide
at that point whether the color should be changing or not.
My preferred approach is (1) and so far I have created my own
NSColorPanel instance, and assigned to the colorwell using
takeColorFrom: - however this isn't working.
Can anyone offer any help?
(Of course this is also going to be happening for NSFontPanel as well..)
Duncan.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden