Re: TableView formatting and "small" NSButton questions
Re: TableView formatting and "small" NSButton questions
- Subject: Re: TableView formatting and "small" NSButton questions
- From: "Alastair J.Houghton" <email@hidden>
- Date: Sat, 1 Nov 2003 21:30:52 +0000
On Saturday, November 1, 2003, at 08:10 pm, Michael Becker wrote:
Hello!
I have two questions:
In Interface Builder, when you insert a Push Button into your window,
you can make it "small". This reduces the height of both the button
and the text in it. However, I cannot find a proper way to do this in
my code.
You want
[[myButton cell] setControlSize:NSSmallControlSize];
Secondly, I need a somewhat complicated tableview-format. The
tableview should display a thumbnail of a picture in one column and in
the next column there should be information about the picture and two
buttons ("edit", "delete"). Is there a way to put all of that in one
column or do I need to use on column per item?
You can put whatever you like in a column... you just need to make an
NSCell subclass that does whatever is appropriate. Then you just do
-setDataCell: on each NSTableColumn you want to contain your custom
cell. Given that you have complete control over your NSCell
implementation, you can pretty much do whatever you please as regards
rendering controls (so, yes, you could use an NSMatrix if you wanted).
Kind regards,
Alastair.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.