I am trying to change the color of the Settings button to white, but can't get it to change.
I've tried both of these:
navigationItem.leftBarButtonItem?.tintColor = UIColor.whiteColor()
navigationItem.backBarButtonItem?.tintColor = UIColor.whiteColor()
but no change, it still looks like this:
How do I make that button white?
Very easy to set up in the storyboard:
It will be solved with this line in -(void)viewDidLoad:
You can use like this one. Place it inside
AppDelegate.swift
.You should use this:
Swift 3
The most upvoted answer is not correct for Swift 3.
The correct code to change color is:
If you want to change color, change UIColor.white above to the desired color
This snippet does the magic. Instead of the redColor, change it to as your wish.