0

I want to have a navigation bar like this:

enter image description here

I tried using this image: enter image description here

And using this code:

homeVC.navigationBar.backIndicatorImage = [UIImage imageNamed:@"bb"];
homeVC.navigationBar.backIndicatorTransitionMaskImage = [UIImage imageNamed:@"bb"];

And the result is...not so good:

enter image description here

What am I doing wrong and how can I achieve an effect similar to the above?

Thanks

0xSina
  • 20,973
  • 34
  • 136
  • 253
  • 1. Nav bar's height seems off. It's 92px at the moment. 2. Your back indicator image lacks the gray overlay around itself to set it's boundaries and darken the below color. – Desdenova Feb 21 '14 at 14:10
  • @Desdenova that what I am confused about. What should be the size of the back indicator image? and does it include the dark color below? Or is that some other method that accepts a 'backbground image' ? – 0xSina Feb 21 '14 at 14:12
  • @Desdenova ignore the height of nav bar. I just screen shotted them so it might be a little inaccruate. – 0xSina Feb 21 '14 at 14:13
  • I'm not sure if there is a limit to it. Based on your screenshot with slight inaccuracy, a 100x88 px image should do. – Desdenova Feb 21 '14 at 14:15
  • @Desdenova the problem is that the back text (in this case 'TODY;S 15) over lap. It comes on top of the back image. That's what leads me to think there's a particular size that I need to use. Looking at the documentation, there's no mention of this though. – 0xSina Feb 21 '14 at 14:20
  • possible duplicate of [Custom image for UINavigation Back Button in iOS 7](http://stackoverflow.com/questions/18912638/custom-image-for-uinavigation-back-button-in-ios-7) – memmons Feb 21 '14 at 14:38
  • So much for the transparent area around the image theory. Seems like that's been changed as well. There is a inset going on around the button, that's ruining the desired affect. Had to use a solid color 88x88 image to see that. – Desdenova Feb 21 '14 at 14:55
  • So what's the right size? I tried 88x88 and that doesn't work. – netwire May 01 '15 at 21:39

0 Answers0