开发者

NSWindow resize limit

I'm trying to create a resize limit for my NSWindow. I don't want the window to scale smaller than 732x or 496y pixels. What would be the best way to go about doing th开发者_如何学Gois?


In Xcode click the .xib file and then select your window. In the utilities tray click the size inspector and check the box next to Minimum Size Constraints and set the size


In code you would do it like this:

window.contentMinSize = NSMakeSize(320.0, 568.0);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜