Re: Centering CheckBox in Table Column
Re: Centering CheckBox in Table Column
- Subject: Re: Centering CheckBox in Table Column
- From: Stephane <email@hidden>
- Date: Tue, 27 Feb 2007 18:33:00 +0100
If your checkbox does not have any title:
tPrototypeCell = [[NSButtonCell alloc] initTextCell: @""];
if (tPrototypeCell!=nil)
{
[tPrototypeCell setEditable: YES];
[tPrototypeCell setButtonType:NSRadioButton];
[tPrototypeCell setImagePosition:NSImageOnly]; // <- This is what
probably interests you the most
[tPrototypeCell setControlSize:NSSmallControlSize];
tColumn=[IBsetsArray_ tableColumnWithIdentifier:@"State"];
[tColumn setDataCell:tPrototypeCell];
[tPrototypeCell release];
}
On Feb 27, 2007, at 6:13 , development3 wrote:
I am hoping that someone can help me.
I have a table, with two columns. The second column has check box.
That all works correctly, The problem is that the Check Box is
drawn the very left in the column. The problem is I would like them
drawn Centered. I have tried setting the Alignment for the data for
the column to centered. But I think that only works for text. This
would not look so bad except the column is like 70 pixels, and I
can not make it smaller because of the Column title. I have
searched the archives but found nothing on this. Is this possible?
If so how? It really looks stupid. It works fine, just looks stupid.
Thanks in advance for any help.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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