Unexpected behavior of `additionalSafeAreaInsets` when using `prefersLargeTitles` and embedding `UITableViewController`
Originator: | federicotrimboli | ||
Number: | rdar://32683602 | Date Originated: | June 9 2017, 6:53 PM |
Status: | Open | Resolved: | |
Product: | iOS + SDK | Product Version: | iOS 11 beta 1 |
Classification: | UIKit | Reproducible: | Yes |
Summary: I need to attach a label to the bottom of the navigation bar when using `prefersLargeTitles`, and making the content of the table start right after my label. Steps to Reproduce: I need to attach a label to the bottom of the navigation bar when using `prefersLargeTitles` and also embed a `UITableViewController` with its content starting right after my label. Using `additionalSafeAreaInsets` I can add the height of my label to the safe area, in order to make the contents of the table view appear right after my label. This is the view controller hierarchy: - UIViewController * view * topLabel - UITableViewController * tableView Expected Results: Label should always be attached to the navigation bar, even when scrolling and making the bar bigger or smaller. Observed Results: When scrolling up, the label follows the new height and position of the navigation bar. But, when scrolling down, the label is fixed in its original position. Version: iOS 11 beta 1 Notes: ALSO, when using `navigationController?.navigationBar.isTranslucent = false`, the `additionalSafeAreaInsets` are ignored completely.
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!
Main bug still happening on Xcode 9.1 beta 2.
My last comment that says "ALSO, when using
navigationController?.navigationBar.isTranslucent = false
, theadditionalSafeAreaInsets
are ignored completely." was fixed on Xcode 9.0.1 / iOS 11.0.1.Main bug still happening on Xcode 9.0.1 / iOS 11.0.1.