Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > NSTextField: Background Color Behavior

NSTextField: Background Color Behavior
Thread Tools
jessejlt
Mac Enthusiast
Join Date: Feb 2003
Location: Portland, Oregon
Status: Offline
Reply With Quote
Apr 23, 2004, 11:38 PM
 
I would like to draw the background color of my NSTextField as rounded instead of squared, like the new NSSearchFields are. Is this possible in an NSTextField? If not, how can I get his behavior?
jesse ;-)
     
Rickster
Mac Elite
Join Date: Feb 2001
Location: Vancouver, WA
Status: Offline
Reply With Quote
Apr 24, 2004, 02:21 AM
 
Check the "Rounded" box in the inspector in IB, or setBezelStyle:NSRoundedBezel (IIRC, check NSTextFieldCell.h to verify) at runtime.

Better yet, don't. Apple's HI recommendation as of Panther is that the generic rounded text field style is deprecated -- rounded text fields should always be search fields (preferably live-search-as-you-type), and NSSearchField provides that. (However, if you need to implement a custom search field control because you're deploying on 10.2, using the rounded text field is a good place to start.)
Rick Roe
icons.cx | weblog
     
   
 
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Top
Privacy Policy
All times are GMT -4. The time now is 12:26 PM.
All contents of these forums © 1995-2017 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.8 © 2000-2017, Jelsoft Enterprises Ltd.,