setBackButtonBackgroundImage without title IOS5
Posted
by
user1736571
on Stack Overflow
See other posts from Stack Overflow
or by user1736571
Published on 2012-10-11T01:12:19Z
Indexed on
2012/10/27
23:01 UTC
Read the original article
Hit count: 223
I'm trying to get a back button without a title but I can't make it work. I am really new in objective-c...
UIImage *backButtonImage = [[UIImage imageNamed:@"back.png"] resizableImageWithCapInsets:UIEdgeInsetsMake(0, 0, 30, 50)];
[[UIBarButtonItem appearance] setBackButtonBackgroundImage:backButtonImage
forState:UIControlStateNormal
barMetrics:UIBarMetricsDefault];
With that code I have my back button but also the title of the previous page.
I found some working examples using the class UIViewController but in my case the code is in the appDelegate.m file.
Any idea how I can make it work ?
© Stack Overflow or respective owner