I've been struggling with this for a few days...so time to ask, if I may. I am trying to emulate Scott Anguish's multiplication table in his book. I cannot get tableview to show columns of constant width.

I have looked at the guides of Apple, tried to understand all the nuances of tableview, scrollview, headers etc, looked at numerous tutorials on NSTableview, (most a little dated), discerned that perhaps I should be looking at NSTableColumn, and thought I had found the answer doing this.

-(void) awakeFromNib
{
        NSLog(@"awakeFromNib: setting \"sizeToFit\"");
        [tv sizeToFit];
        
}

where tv is declared as:  "IBOutlet NSTableView *tv;"

As far as I can tell, the outlet is set correctly, NSLog is called at the appropriate time.

What I get when I use the above code is the first couple of columns varying in size, then the next "n" columns equally space.

If I have missed something in the documentation, I would appreciate a pointer, but somehow, I cannot believe that it is this difficult to do, but perhaps I am doing something that will become a lot easier further into Hillegas tutorial?

Thanks in advance.
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please 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:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to