禁用X $ C $Ç故事板约束 [英] Disable Constraints in Xcode Storyboard

查看:101
本文介绍了禁用X $ C $Ç故事板约束的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想布置一个非常简单的看法。我已经放在4自定义按钮在视图中像间距的网格。但是,当我运行应用程序,我得到两个不同大小的按钮。我在这里包括故事板和仿真图像。

我很想禁用约束,但是找不到在哪里做吧!我真的不希望他们。这仅仅是一个简单的原型应用程序,并在最后,我甚至不会有这些按钮,我会在code打好所有的东西。

我试过在4个独立的按钮,拖动并试图拖动只是在一个和它复制到我想去的地方。我只是希望他们留在我把他们!任何帮助将是AP preciated。

- 马克


解决方案

您关闭它在文件检查器(第一选项卡上左) - 有一个名为使用自动布局复选框(它在默认情况下选中)

I'm trying to layout a very simple view. I've placed 4 custom buttons in the view in a grid like spacing. But when I run the app I get two of the buttons with different sizes. I've included the storyboard and simulator images here.

I would LOVE to disable constraints but cant find where to do it! I really don't want them. This is just for a simple prototype app and in the end I won't even have these buttons, I'll lay everything out in code.

I've tried dragging in 4 individual buttons AND tried just dragging in one and duplicating it to where I want. I just want them to stay where I put them! Any help would be appreciated.

-Mark

解决方案

You turn it off in the File Inspector (first tab on left) -- there's a checkbox called "Use Autolayout" (it's checked by default).

这篇关于禁用X $ C $Ç故事板约束的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆