iOS 10 - View Controller / Navigation Bar Title hidden

Funnybear

I'm currently facing stranges behaviours with iOS 10.

Indeed, everything was working fine, but since I updated to xCode 8 and began testing my App on iOS 10, a lot of stuff went wrong.

For example, all my Navigation Bar's titles are not displayed anymore.

More precisely, when I'm using the menu to navigate threw my app, every time I switch to a different view, there are no title, BUT when I press the back button, I can briefly see it before the transition to the other view.
I don't understand this new behaviour, I didn't change anything in the code, and when I launch the App on iOS 9 or lesser, everything is working properly.

I tried to set the title in the ViewWillAppear / ViewDidLoad, in the prepareForSegue, but nothing is working.

if ([segue.identifier isEqualToString:kMy_Segue]) {
    MyViewController* destinationVC = segue.destinationViewController;
    [destinationVC setTitle:@"MyTitle"];
}

I feel like there are some changes with the pushed Navigation Controller, or the title item is not at the same index than the Navigation Bar itself because when I navigate threw subviews in the menu, the title only appears when I press back.

For example I have a category in my Menu called "World". When I tap it I want the title of the subview to be "World", but nothing is displayed. Then, I have all the continents listed "Africa", "Europe", "Asia" etc... When I tap on Africa, I want the next title to be "Africa" right? And again, nothing is displayed BUT if I press the back button and go back to the list of continents, the title "World" appears.

If anyone has encountered this issue, I would really appreciate some help.

KSR

Follow this:

Solution-1

Goto to the viewController, then click on NavigationItem as shown below:

enter image description here

In the right pane, change "Title" as follows:

enter image description here

Solution-2

Add a UIView to your navigationBar as shown below:

enter image description here

Add an UILabel to your navigationItem as shown below:

enter image description here

Change the frame of the newly added UILabel as follows:

enter image description here

Change text of UILabel to "Sample Title" and change UIView backgroundColor to clearColor.

I have made a sample in Xcode8, please check my GitHub link below:

https://github.com/k-sathireddy/NavigationItemSample

Collected from the Internet

Please contact [email protected] to delete if infringement.

edited at
0

Comments

0 comments
Login to comment

Related

From Dev

iOS Navigation Bar Title View Buttons

From Dev

IOS Custom View or Navigation Bar Controller

From Dev

iOS XCode6 Status Bar Hidden breaks navigation controller

From Dev

iOS 10 Beta makes navigation bar buttons and title disappear on pushViewController

From Dev

Page View Navigation Bar Title

From Dev

Navigation bar Hidden not working IOS

From Dev

Auto Layout with navigation bar and view controller (iOS 7)

From Dev

iOS - pop a view controller by panning on the left edge, navigation bar disappears

From Dev

iOS: Navigation Controller title not centered

From Dev

Add navigation bar on a view controller

From Dev

Add a navigation bar to a view without a navigation controller

From Dev

Navigate from a navigation bar view controller to a tab bar view controller

From Dev

Navigate from a navigation bar view controller to a tab bar view controller

From Dev

Navigation Bar's Title View Overlaps

From Dev

Swift - Title Not Appearing for Navigation View Controller

From Dev

iOS: Scope bar hidden when search bar is displayed in navigation bar

From Dev

Navigation title not showing on view with tab view controller, but "back" navigation works

From Dev

Navigation title not showing on view with tab view controller, but "back" navigation works

From Dev

Interactive view controller transition from view controller with status bar hidden

From Java

iOS change navigation bar title font and color

From Dev

iOS Navigation Bar title truncated on segue

From Dev

swift ios cant change navigation bar title

From Dev

iOS: navigation bar title - two colors

From Dev

iOS - add image and text in title of Navigation bar

From Dev

ios Title and Subtitle in Navigation Bar centered

From Dev

iOS - add image and text in title of Navigation bar

From Dev

iOS Navigation Bar title truncated on segue

From Dev

Add navigation bar to a view controller without a navigation controller

From Dev

Add navigation bar to a view controller without a navigation controller

Related Related

  1. 1

    iOS Navigation Bar Title View Buttons

  2. 2

    IOS Custom View or Navigation Bar Controller

  3. 3

    iOS XCode6 Status Bar Hidden breaks navigation controller

  4. 4

    iOS 10 Beta makes navigation bar buttons and title disappear on pushViewController

  5. 5

    Page View Navigation Bar Title

  6. 6

    Navigation bar Hidden not working IOS

  7. 7

    Auto Layout with navigation bar and view controller (iOS 7)

  8. 8

    iOS - pop a view controller by panning on the left edge, navigation bar disappears

  9. 9

    iOS: Navigation Controller title not centered

  10. 10

    Add navigation bar on a view controller

  11. 11

    Add a navigation bar to a view without a navigation controller

  12. 12

    Navigate from a navigation bar view controller to a tab bar view controller

  13. 13

    Navigate from a navigation bar view controller to a tab bar view controller

  14. 14

    Navigation Bar's Title View Overlaps

  15. 15

    Swift - Title Not Appearing for Navigation View Controller

  16. 16

    iOS: Scope bar hidden when search bar is displayed in navigation bar

  17. 17

    Navigation title not showing on view with tab view controller, but "back" navigation works

  18. 18

    Navigation title not showing on view with tab view controller, but "back" navigation works

  19. 19

    Interactive view controller transition from view controller with status bar hidden

  20. 20

    iOS change navigation bar title font and color

  21. 21

    iOS Navigation Bar title truncated on segue

  22. 22

    swift ios cant change navigation bar title

  23. 23

    iOS: navigation bar title - two colors

  24. 24

    iOS - add image and text in title of Navigation bar

  25. 25

    ios Title and Subtitle in Navigation Bar centered

  26. 26

    iOS - add image and text in title of Navigation bar

  27. 27

    iOS Navigation Bar title truncated on segue

  28. 28

    Add navigation bar to a view controller without a navigation controller

  29. 29

    Add navigation bar to a view controller without a navigation controller

HotTag

Archive