3 Replies
      Latest reply on Sep 12, 2019 1:31 AM by weak
      TTAppDev Level 1 Level 1 (0 points)

        We are currently having an issue with navigation bar sizing when using modal presentation in iOS 13.

         

        In most cases this works fine as can be seen in this screenshot:

        However, in a few screens we get this weird effect, with the navigation bar having a lower height and a weird "see-through" gap between it and the view. As seen in this screenshot:

        Both of the view controllers have the same values set for their properties, are modally presented and have the same constrains on their subviews (0 spacing from the superview/margins/top layout guide).

        This issue doesn't happen in iOS 12, even when built with the iOS 13 SDK. Is this a known issue in iOS 13 (beta 8), or is there something we should adjust in the code/storyboard?

        • Re: iOS 13 and NavigationBar size
          Claude31 Level 8 Level 8 (6,515 points)

          When we lookk at the screenshot of the problem, it appears the navbar is dimensioned for the view that is stacked behind (smaller width and a few pixels above).

           

          In the first (correct) screenshot, we see the view behind has a title. Not in the other.

           

          How different are the views behind ?

           

          In fact, I would guess this may come from the way IOS 13 handles UIModalPresentationAutomatic:

          "Defaults to UIModalPresentationAutomatic on iOS starting in iOS 13.0, and UIModalPresentationFullScreen on previous versions"

           

          Try changing the presentation to UIModalPresentationFullScreen and see what happens.

           

          Read this for details:

          h ttps://medium.com/@hacknicity/view-controller-presentation-changes-in-ios-13-ac8c901ebc4e