Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can't use safe areas in Xcode 9 after upgrading minimum deployment target to iOS 9

I have just changed my app from supporting iOS 8 and up to supporting iOS 9 and up. I believe I've done this properly, since when I now build my app, I'm getting warnings for everything in the app which was deprecated in iOS 9.

I am using Xcode 9, GM seed.

The problem is that I cannot enable the "Use Safe Area Layout Guides" toggle in any of my storyboards. When I do, I get a warning "Safe Area Layout Guide before iOS 9.0". Is there some additional setting that I need to update? A clean and build did not fix the problem.

like image 915
Jordan Wood Avatar asked Sep 14 '17 14:09

Jordan Wood


2 Answers

Just deselect "Use Safe Area Layout Guides" option, which should fix this. A screenshot below may point you the right direction. Hope this image can help

alt screenshot

like image 172
zhengwu119 Avatar answered Sep 22 '22 08:09

zhengwu119


When you changed the deployment target, did it automatically change the deployment target in your storyboard? (File inspector when opening the Storyboard)

Storyboard File Inspector

Did you update the deployment target in both the Project and in (all) your target(s)?

Project:

Project

Target:

Target

like image 24
Sti Avatar answered Sep 22 '22 08:09

Sti