I'd like to do autolayout based on the parent view, but the top and bottom layout guides are fighting me. Thing is, I'm in an embedded view controller and they aren't relevant:
The layout guides are here:
I thought maybe one of these settings would remove them, but no luck:
How do I get rid of these guides? If that's not possible, any info on why they get created would be really helpful.
Thanks!
I had to deselect and reselect Use Safe Area Layout Guides to remove the Top/Bottom layout guides and still keep safe area layout guides.
Simply uncheck the Content Layout Guides. This option is found under the Size Inspector tab in storyboard. NOTE: This option is found under the Size Inspector tab in storyboard.
You can disable safe area layout guide from storyboard for particular view controller. Select View Controller -> File Inspector (first tab) -> Use safe area layout guides (uncheck the checkbox). You can also change it programmatically in viewDidLoad(). Hope this Helps!
Select your view. Select 'Add New Constraints' option in the InterfaceBuilder. From the dropdown menu of top or bottom constraint, select the 'Top Layout Guide' or 'Bottom Layout Guide'.
Remove the top and bottom layout guides pic
Simply to deselect and reselect Use Safe Area Layout Guides
,
as Apple deprecated Top Layout Guide
@Daniel Storm's answer is more accurate.
@Juan's answer is good , not very ok.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With