I add an image to the BackBarButtonItem navigation bar, the image hits the button, but the image does not scale to fill in what would be the problem.
Here is the code I'm using and it displays as follows.
UIImage *backImage = [UIImage imageNamed:@"back.png"]; UIBarButtonItem *newBackButton = [[UIBarButtonItem alloc] initWithImage:backImage style:UIBarButtonItemStylePlain target:self action:@selector(backAction)]; [self.navigationItem setBackBarButtonItem: newBackButton]; [newBackButton release]; [backImage release];

In fact, it should look like below.

Thanks!
source share