2

I have stumbled across a weird problem when implementing a view container which is connected with child view controllers.

The hierarchy is the following: I have a UISplitViewController and in the MasterViewController I added a view container which is connected to a UIViewController which is embedded in a UINavigationController.

Storybaord

The outcome is the following:

The ChildViewController leaves a white space at the top which seems to be exactly as high as the status bar. How can I avoid that the status bar frame is shown in the child view controller?

I tried to set wantsFullScreenLayout for the ChildViewController and for its UINavigationController but it doesn't change anything.

I also tried to set the y offsets of the views to -20.0 points but that ends up in another problem.

Only when I set status bar hidden for the application it is not shown for the ChildViewController but that in turn also hides the status bar at the top of the UISplitViewController.

Would be glad for some hints.

outcome

4

1 回答 1

0

基本上看起来顶部间隙状态栏。目前的状态栏是“浅色”的,这就是为什么它没有显示在白色背景之上的原因。尝试将视图控制器的背景颜色更改为黑色或使用外观回调之一将状态栏更改为较深的颜色。

于 2013-11-12T23:38:54.653 回答