Change UINavigationBar Height

前端 未结 12 1538
囚心锁ツ
囚心锁ツ 2020-11-28 09:26

Can some one tell me how to change the navigation bar height?

Here is what i have so far:

CGFloat navBarHeight = 10;
self.navigationController.navi         


        
12条回答
  •  心在旅途
    2020-11-28 09:49

    Try this code inside - (void)viewDidLayoutSubviews method,

    CGFloat navBarHeight = 10.0f;    
    CGRect frame = CGRectMake(0.0f, 0.0f, 320.0f, navBarHeight);
    [self.navigationController.navigationBar setFrame:frame];
    

提交回复
热议问题