无法满足约束

时间:2018-02-15 20:11:12

标签: ios autolayout

我被这个约束问题困扰了。我已经多次尝试重新设计约束但我似乎无法解决问题

2018-02-15 15:01:59.707545-0500 [LayoutConstraints] 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. 
(
"<NSLayoutConstraint:0x61000008bf90 UIButton:0x7fdabc459660.width == 28>",
"<NSLayoutConstraint:0x610000081270 UIImageView:0x7fdabc459d00.width == 22>",
"<NSLayoutConstraint:0x610000083570 UIImageView:0x7fdabc459d00.leading == UITableViewCellContentView:0x7fdabc410000.leading + 16>",
"<NSLayoutConstraint:0x610000082ee0 UILabel:0x7fdabc4593d0.leading == UIImageView:0x7fdabc459d00.trailing + 16>",
"<NSLayoutConstraint:0x610000080b90 UIButton:0x7fdabc459660.leading == UILabel:0x7fdabc4593d0.trailing + 8>",
"<NSLayoutConstraint:0x6100000868b0 UITableViewCellContentView:0x7fdabc410000.trailingMargin == UIButton:0x7fdabc459660.trailing + 8>",
"<NSLayoutConstraint:0x6180000953b0 UITableViewCellContentView:0x7fdabc410000.width == 0>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x61000008bf90 UIButton:0x7fdabc459660.width == 28>

NSLayoutConstraint:0x6180000953b0 UITableViewCellContentView:0x7fdabc410000.width == 0让我怀疑,但我不确定该约束来自哪里

编辑:

以下是突出显示约束的单元格图片。所有约束都在故事板中创建

enter image description here enter image description here

1 个答案:

答案 0 :(得分:0)

我猜,plz改变内容压缩阻力优先级&#34;地址和名称标签&#34;到740并检查。 enter image description here