TableViewCellWithAutoLayoutiOS8 icon indicating copy to clipboard operation
TableViewCellWithAutoLayoutiOS8 copied to clipboard

Constraints break when setting kLabelVerticalInsets to 16.0f

Open max-pfeiffer opened this issue 9 years ago • 0 comments

When I set the vertical insets to some higher value the contraints of the UITableViewCell break. Not shure what is causing it. It seems to be the size of cells content view. But leveraging that size upwards does't lead to a solution.

2016-04-11 14:52:45.832 TableViewCellWithAutoLayout[451:79339] 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:0x17e97900 V:|-(16)-[UILabel:0x17e96600'Thonburi']   (Names: '|':UITableViewCellContentView:0x17d99fc0 )>",
    "<NSLayoutConstraint:0x17da1a80 V:[UILabel:0x17e96600'Thonburi']-(16)-[UILabel:0x17d9b1c0'Lorem ipsum dolor sit ame...']>",
    "<NSLayoutConstraint:0x17da2bc0 UILabel:0x17d9b1c0'Lorem ipsum dolor sit ame...'.bottom == UITableViewCellContentView:0x17d99fc0.bottom - 16>",
    "<NSLayoutConstraint:0x17e96fa0 'UIView-Encapsulated-Layout-Height' V:[UITableViewCellContentView:0x17d99fc0(44)]>"
)

Will attempt to recover by breaking constraint 
<NSLayoutConstraint:0x17da1a80 V:[UILabel:0x17e96600'Thonburi']-(16)-[UILabel:0x17d9b1c0'Lorem ipsum dolor sit ame...']>

max-pfeiffer avatar Apr 11 '16 14:04 max-pfeiffer