Re: NSTableView with popupbuttons
Re: NSTableView with popupbuttons
- Subject: Re: NSTableView with popupbuttons
- From: Daniel Morrow <email@hidden>
- Date: Thu, 28 Oct 2004 11:21:52 -0400
In Interface Builder, go to the panel that has the different kinds of
table views. This panel also has a number of different kinds of cells,
NSTextFieldCell, NSButtonCell, and the one you want, NSPopupButtonCell.
Drag it to the column header of your table in IB, now this column is
going to expect NSPopupButtonCells in it.
Now, you'll see that the column header has a little triangle on the
right side of the column. If you click on the triangle, you'll see that
you can change the attributes of the popup button. You can say if it's
a drop-down or regular popup button. And I think you can control-click
from that triangle to a menu you previously created, which would give
this cell a default popup menu, so whenever a new cell gets created, it
should just copy everything over.
I just tried this myself with a quick test, and it mostly works. Each
row has the same menu in it, but when I click on a menu item, it
doesn't change. There's probably something that I need to add in my
table delegate.
Anyway, hope this helps,
-Dan.
On Oct 28, 2004, at 10:21 AM, Peter Karlsson wrote:
Dear list!
I have searched the net for a while now and I can't find a example how
to
build a tableview with popupbuttons in IB. I have found examples where
this
is done programatically but I want to do most of the work in IB. Does
anyone knows of a example somewhere?
Best regards Peter
_______________________________________________
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