本文介绍了setAutoresizingMask从osx中的代码的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述 在尺寸检查器中有一个名为Atosizing的部分,可以设置控件的左,右,上,下布局,我发现我用 setAutoresizingMask 不知道如何设置它,我的控制布局向右和向上(意味着当用户调整大小窗口我的控制牛排向右和向上)解决方案查看这些 -setAutoresizingMask 参数: 因此,您可以它就像这样: [YourOutlet setAutoresizingMask:NSViewMinXMargin | NSViewMinYMargin]; There is a section in size inspector with name Atosizing that can set left,right,up,down layout of a control,i find that i do that with setAutoresizingMask but don't know how set it that my control layout to right and up (means when user resize window my control steak to right and up) 解决方案 Look at these -setAutoresizingMask parameters:So You can do it like this:[YourOutlet setAutoresizingMask: NSViewMinXMargin | NSViewMinYMargin]; 这篇关于setAutoresizingMask从osx中的代码的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持! 10-11 21:33