iOS 11 Beta 1 uses the increased navigation-bar title for almost all system-apps (it started doing this in iOS 10 and the Music app). I am wondering if Apple has a public API fo
The only change done to UINavigationBar
API for iOS 11 is prefersLargeTitles
.
Documentation here: https://developer.apple.com/documentation/uikit/uinavigationbar/
You can do it to your own apps with one small change: check "Prefers Large Titles" for your navigation bar in IB, or if you prefer to do it in code using:
navigationController?.navigationBar.prefersLargeTitles = true
If you need to change the text attributes of the large title you need to use the new largeTitleTextAttributes
property on UINavigationBar
:
UINavigationBar.appearance().largeTitleTextAttributes = [
NSAttributedString.Key.foregroundColor: UIColor.black
]