Re: Window maxSize different from setMaxSize ???
Re: Window maxSize different from setMaxSize ???
- Subject: Re: Window maxSize different from setMaxSize ???
- From: Bill Cheeseman <email@hidden>
- Date: Thu, 8 Oct 2009 09:09:00 -0400
On Oct 7, 2009, at 5:55 PM, Bill Cheeseman wrote:
Can somebody explain this to me? It's on Snow Leopard 10.6.1:
In my window controller's -windowDidLoad method (or -awakeFromNib):
[[self window] setMaxSize:NSMakeSize(800, 800)];
[[self window] maxSize]; // --> {800, 856}
OK, duh, it's because of the toolbar in this window. So this is a
documentation bug: the NSWindow Class Reference says absolutely
nothing about the toolbar, in the -setMaxSize: and -maxSize
documentation. It should disclose that -maxSize returns a different
value than you set in -setMaxSize: if a toolbar is visible when -
maxSize is called.
--
Bill Cheeseman
email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
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:
This email sent to email@hidden