Advertisement
Guest User

Untitled

a guest
Aug 21st, 2019
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.90 KB | None | 0 0
  1. navBar.topItem.title = @"title";
  2.  
  3. self.navigationItem.title = @"the title";
  4.  
  5. CGRect navBarFrame = CGRectMake(0, 0, self.tableView.frame.size.width, 44.0);
  6. UINavigationBar *navBar = [[UINavigationBar alloc] initWithFrame:navBarFrame];
  7.  
  8. UINavigationItem *navItem = [UINavigationItem alloc];
  9. navItem.title = @"Your Title";
  10.  
  11. [navBar pushNavigationItem:navItem animated:false];
  12.  
  13. [self.view addSubView:navBar];
  14.  
  15. self.tableView.tableHeaderView = navBar; etc
  16.  
  17. [self setTitle:@"My Title"];
  18.  
  19. self.navigationItem.title=@"Hello World";
  20.  
  21. navigationBar.topItem.title = @"Title";
  22.  
  23. self.navigationController.navigationBar.topItem.title = @"Title";
  24.  
  25. _title = @"Title";
  26.  
  27. self.title = @"Title";
  28.  
  29. self.navigationItem.title = @"Your title";
  30.  
  31. override func viewDidLoad() {
  32. super.viewDidLoad()
  33. navigationItem.title = "Title"
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement