How does one change the background colour of the uisearchcontroller? Atm it looks like this
I want it all one colour.
I've attempted sc.view.tintColor = UIColor.rgb(10, green: 150, blue: 255)
and
sc.view.backgroundColor = UIColor.rgb(10, green: 150, blue: 255)
but doesn't remove the grey bit the side
Eh, with some thought I solved it.
sc.searchBar.barTintColor = UIColor.rgb(10, green: 150, blue: 255)
sc.searchBar.searchBarStyle = UISearchBarStyleProminent
sc.searchBar.backgroundImage = [UIImage new]
sc.searchBar.barTintColor = UIColor.rgb(10, green: 150, blue: 255)
set searchBarStyle to Prominent. It working for me
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With