2

然后视图如下所示: 在此处输入图像描述

而且我向下滚动和向上滚动很多次,都会出现错误。该代码与演示中的示例代码大部分相同。

2015-05-18 10:15:16.907 HiPDA V2[29096:948402] 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:0x7fa810d4ce20 V:    [JSQMessagesLabel:0x7fa810d4ca80(20)]>",
    "<NSLayoutConstraint:0x7fa810d4dc40 V:[JSQMessagesLabel:0x7fa810d4d5f0(20)]>",
    "<NSLayoutConstraint:0x7fa810d54910 V:[JSQMessagesLabel:0x7fa810d54670(0)]>",
    "<NSLayoutConstraint:0x7fa810d55010 V:|-(0)-[JSQMessagesLabel:0x7fa810d4ca80]   (Names: '|':UIView:0x7fa810d4c900 )>",
    "<NSLayoutConstraint:0x7fa810d55100 V:    [JSQMessagesLabel:0x7fa810d4ca80]-(0)-[JSQMessagesLabel:0x7fa810d4d5f0]>",
    "<NSLayoutConstraint:0x7fa810d551a0 V:[JSQMessagesLabel:0x7fa810d4d5f0]-(0)-[UIView:0x7fa810d4e1b0]>",
    "<NSLayoutConstraint:0x7fa810d55330 V:[JSQMessagesLabel:0x7fa810d54670]-(0)-|   (Names: '|':UIView:0x7fa810d4c900 )>",
    "<NSLayoutConstraint:0x7fa810d55380 V:[UIView:0x7fa810d4e1b0]-(0)-[JSQMessagesLabel:0x7fa810d54670]>",
   "<NSAutoresizingMaskLayoutConstraint:0x7fa8131f45d0 h=--& v=--& V:[UIView:0x7fa810d4c900(38)]>"
)

W ill attempt to recover by breaking constraint 
<NSLayoutConstraint:0x7fa810d4dc40 V:  [JSQMessagesLabel:0x7fa810d4d5f0(20)]>

Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
4

0 回答 0