Re: Making combo box popup wide enough
Re: Making combo box popup wide enough
- Subject: Re: Making combo box popup wide enough
- From: Shaun Wexler <email@hidden>
- Date: Thu, 6 Oct 2005 14:21:35 -0700
On Oct 6, 2005, at 1:25 PM, Glen Simmons wrote:
NSComboBox, Cocoa's red-headed stepchild, doesn't do a very good
job of displaying its list of choices. Unlike NSPopupButton, which
shows the full width of its items, NSComboBox truncates them. How
can I get it to do the right thing and show all of its choices? And
making the control wider is not an option since the choices may
change / be localized.
To pop-up, NSComboBoxCell creates a borderless NSWindow containing a
NSTableView with one NSTableColumn. You can access these private
objects using a category:
@interface NSComboBoxCell (PrivateAccessorHack)
- (NSTableView *)tableView;
@end
@implementation NSComboBoxCell (PrivateAccessorHack)
- (NSTableView *)tableView
{
return _tableView;
}
@end
I assume you can figure it out from there...
--
Shaun Wexler
MacFOH
http://www.macfoh.com
_______________________________________________
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