views:

54

answers:

1

I created a custom Navbar for my application using a protocoll:

@implementation UINavigationBar (CustomImage)
- (void)drawRect:(CGRect)rect {
    UIImage *image = [UIImage imageNamed: @"navbar.png"];
    [image drawInRect:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
}
@end

alt text

this works fine. all toolbars in my application look great now. but i also want a way to tint my uibarbuttonitems in my toolbar. i could set the tint color of every button, but this does not work on pre-defined items like the ones in my mailcomposerview and so on.

is there a way to give all my buttons a tint color? just like i've done that with my navigation bar.

+1  A: 

You'll need to set the tintColor for navigationBar property of your navigation controller.

Paul Ardeleanu
for every navigationbar in my application? :O
choise
You only have one for each navigation controller ;)
Paul Ardeleanu
but how to do this for a MFMailComposer f.e.?
choise
You probably mean MFMailComposeViewController. Same way, as MFMailComposeViewController inherits from UINavigationController: myMailComposer.navigationBar.tintColor
Paul Ardeleanu