ios - navigation bar too big after adding custom background image -


i'm trying customise navigation bars throughout app. navigation controller has been created in ib. used following code add custom image bar. image 320 x 44 points. code in appdelegate in applicationdidfinishlaunchingwithoptions:

uiimage *navbackgroundimage = [uiimage imagenamed:@"nav image.png"];     [[uinavigationbar appearance] setbackgroundimage:navbackgroundimage forbarmetrics:uibarmetricsdefault]; 

the problem on simulator, bar covers half screen! , covers load of content. ive tried messing around image dimensions in photoshop , helps, must easier way messing around , rebuilding trial , error?!!

are there convenience methods set size of nav bar?

any appreciated!!

quick solution :

goto nib file , select uinavigationcontroler -> size inspector -> turnoff autoresizing.

enter image description here

hope .

all best !!!


Comments

Popular posts from this blog

Change php variable from jquery value using ajax (same page) -

Pull out data related to my apps from Android Play Store and iOS App Store -

How can I fetch data from a web server in an android application? -