Re: Disabled, auto-disappearing placeholder in search field like Safari, Console.app
Re: Disabled, auto-disappearing placeholder in search field like Safari, Console.app
- Subject: Re: Disabled, auto-disappearing placeholder in search field like Safari, Console.app
- From: Andrew Farmer <email@hidden>
- Date: Tue, 24 Feb 2009 03:57:39 -0800
On 23 Feb 09, at 20:52, Jerry Krinock wrote:
When I bind to an NSSearchField with option key=value pair
NSNullPlaceholderBindingOption="Search names", indeed "Search names"
is displayed in the search field whenever the bound keyPath is nil.
But it appears as normal black text which the user must overtype.
In contrast, the "Google" search field in Safari has disabled (gray)
text that disappears when the field becomes the key view. The
search field in Console.app has similar behavior.
This is placeholder text. You can set it with the "placeholder" field
on text input fields, or programatically using the
setPlaceholderString on a NSTextFieldCell.
_______________________________________________
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