Re: Increasing a cell's height!!! HELP!
Re: Increasing a cell's height!!! HELP!
- Subject: Re: Increasing a cell's height!!! HELP!
- From: "Jean-Olivier Lanctôt-D." <email@hidden>
- Date: Sat, 21 Dec 2002 00:51:09 -0500
Hello,
I kind of got it to work.. but with a very cheap way.. very cheap.
- (void)browser:(NSBrowser *)sender willDisplayCell:(id)cell
atRow:(int)row column:(int)column {
if(column==2){
NSCell *infoCell = [[NSCell alloc] init];
[cell setLeaf:YES];
[cell setSelectable:NO];
[cell setEnabled:NO];
[cell setTitle:@""];
[infoCell setWraps:YES];
[infoCell setSelectable:YES];
[infoCell setAlignment:NSJustifiedTextAlignment];
[infoCell setType:NSTextCellType];
[infoCell setScrollable:YES];
[infoCell setStringValue:@"Hello Testing.Hello Testing.\nHello
Testing.\nHello Testing.\nHello Testing.\nHello Testing.\nHello
Testing.\nHello Testing.\nHello Testing.\nHello Testing.\nHello
Testing.\nHello Testing.\nHello Testing.\nHello Testing.\nHello
Testing.\nHello Testing.\nHello Testing.\nHello Testing.\nHello
Testing.\nHello Testing.\nHello Testing.\nHello Testing.\nHello
Testing.\n"];
[infoCell drawWithFrame:[themeBrowser frameOfColumn:2]
inView:themeBrowser]; // Yep :)
[infoCell release];
}else{
[cell setTitle:@"Hello."];
}
}
The main problem is that it does not wrap, even with setWraps:YES...
The ideal way of doing it would be to draw a NSTextView in the column..
I've tried to draw one in the [themeBrowser frameOfColumn:2]
inView:themeBrowser]; Rect... but it does not work... Help me please :)
-- Jean-Olivier
_______________________________________________
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.