Re: How to disable/gray an NSTextfield (used as static text)
Re: How to disable/gray an NSTextfield (used as static text)
- Subject: Re: How to disable/gray an NSTextfield (used as static text)
- From: Daniel Todd Currie <email@hidden>
- Date: Sat, 23 Oct 2004 11:27:27 +0900
If you really wanted to, I suppose you could subclass NSTextField and
make it so that text labels gray when they receive the -setEnabled:
message... Otherwise, this is just as good a way as any other:
[myTextLabel setTextColor:[NSColor disabledControlTextColor]];
-- DTC
On 2004 Oct 23, at 09:34, Sean McBride wrote:
Hi,
I am using an NSTextField as a text label (ie not editable nor
selectable). I'd like to 'disable' this textfield so that it appears
gray instead of black.
Obviously, setEnabled:NO does not work. :( I thought to maybe change
the
text colour to disabledControlTextColor, but maybe there is a better
solition?
I checked the archives, and this has been asked before, but not
answered. :)
(Basically, I'm trying to achieve exactly what can be seen in System
Preferences > Energy Saver > Schedule, notice how the word 'at' is
grayed
if the 'start up the computer' checkbox is off.)
Thanks!
--
Erroneous google translation: "She does not love pig-turkey, the toys
which make noise and especially the sound of the harmonica..."
_______________________________________________
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
_______________________________________________
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