Reputation: 3287
I'm building a table view prototype cells defined in InterfaceBuilder, and there appears to be an 8 pixel margin below the content view in all the UITableViewCells being defined.
I'm able to align a view at the absolute bottom of a cell by setting the autolayout bottom parameter to -8, but this seems like kind of a hack and potentially brittle to future iOS updates, and it seems like there should be a way to get rid of the 8 pixel margin in IB or programmatically.
Upvotes: 2
Views: 746
Reputation: 8014
Check that you have not used a constraint which is pinned to the margin rather than the view.
If so, change the constraint to be pinned with no margin.
When you create the constraints for the outermost view there is a check box saying constrain to margin. Deselect that. On existing constraints you can also remove the margin use on the individual constraint menus for the first and second views.
Upvotes: 1