IPhone Navigation Bar button, using custom image, done with Interface Builder

interface-builderiphone

iPhone application, which has two buttons -right side- of Navigation Bar title. I want to do this completely using Interface Builder and have had some limited success. The current problem is with buttons using custom image. All built-in images are ok, e.g. Info Light or Add Contact. Custom image just won't get visible.

alt text

Type: custom
Title: (empty)
Image: (empty)
Background: my_image.png

Any ideas what to try? Could it be that my PNG image is somehow wrong? Tried also images, which show ok on Tab bar. Please note that button highligh works ok. Just missing the image… Must be close, right?

alt text

Best Answer

EDIT: I read your question a bit too quickly the first time. I now see you're using a custom view for the UIBarButtonItem. Are you just simulating this through Interface Builder, or have you tried building your project and running it in the Simulator or on your device? I was able to successfully get a custom image in view in a UIBarButtonItem, though I had to build and run my project before I could see it (simulating it through IB wasn't enough).

Related Topic