iOS 约束冲突
来源:互联网 发布:网络福建师范大学校长 编辑:程序博客网 时间:2024/05/17 23:56
在使用AutoLayout的时候调试台打印出以下信息
Unable to simultaneously satisfy constraints. Probably at least one of the constraints in the following list is one you don't want. Try this: (1) look at each constraint and try to figure out which you don't expect; (2) find the code that added the unwanted constraint or constraints and fix it. (Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints) ( "<NSLayoutConstraint:0x14e6dff0 DrawIconView:0x14d6d9b0.leading == UIView:0x14d6d600.leadingMargin>", "<NSLayoutConstraint:0x14e55270 H:[DrawIconView:0x14d6d9b0(30)]>", "<NSLayoutConstraint:0x14e5c740 UIView:0x14d6d600.trailingMargin == DrawIconView:0x14d6d9b0.trailing>", "<NSLayoutConstraint:0x14e67d50 H:[UIView:0x14d6d600(50)]>")Will attempt to recover by breaking constraint
遇到这个问题不要木,仔细看一下应该是约束有冲突,向控制台里寻找更详细的信息,发现到了#986类似的字眼,错误大概就是出现在这个。
原来设置了WIDTH约束后又定义了CenterX 果断改为LeftMargin与RightMargin 再次运行 问题解决。
0 0
- iOS 约束冲突
- iOS 约束冲突解决方法
- ios 约束冲突NSAutoresizingMaskLayoutConstraint
- iOS开发------手动约束布局出现NSAutoresizingMaskLayoutConstraint冲突(解决)
- iOS--Masonry解决 tableViewCell 重用时约束冲突
- iOS Massonry约束自定义TableViewCell自适应行高的约束冲突的问题
- iOS 约束
- DELETE 语句与 REFERENCE 约束冲突。
- INSERT 语句与 FOREIGN KEY 约束""冲突
- DELETE 语句与 REFERENCE 约束 冲突 解决办法
- INSERT 语句与 FOREIGN KEY 约束冲突
- 使用 UIViewAlertForUnsatisfiableConstraints 捕捉autolayout 约束冲突
- 约束报错、冲突如何定位UI
- Masonry mas_updateConstraints 更新约束冲突解决
- ios自动布局 约束
- IOS 自动约束
- iOS简单约束1
- iOS约束的设置
- [手游新项目历程]第11天-protobuf
- 关于C#对AutoCad2007二次开发插件工作总结
- test标题
- SVN使用教程
- 上传图片并生成缩略图
- iOS 约束冲突
- 利用notepad++运行php
- Sublimewebinspector 断点不能打上的解决方法
- 颜色渲染器Shader对象
- Java四种引用详解
- C++拷贝构造函数
- spring学习笔记(20)数据库事务并发与锁详解
- Linux出现Read-only system的解决方法
- BZOJ 3992 SDOI2015 序列统计