I am trying to replicate a gradient from UINavigationBarto use it as a gradient for custom subclass objects UIButtonin the same view.
However, I can’t understand how colors are produced? That is, you specify only one color to set the background color UINavigationBar- tintColor- but it creates a good gradient, does it seem to have at least 4 colors?
I'm really interested in the "inner" upper and lower colors, though - only inside the 1px border around the bar ... the outer borders of the "border" really look different, though.
EDIT - 1
With further research, it seems that HSB (instead of RBG as a first thought) manipulate values to produce different colors.
There is also a convenience method on UIColorto obtain HSB values that should be useful:
getHue:saturation:brightness:alpha:
Useful links found so far
HSL and HSV Wiki
UIColor class reference
Program color highlight
From the book Basics of Interactive Computer Graphics
EDIT - 2
If you did not know that you can set the gradient for the background on UIButtonprogrammatically, here are some links for how to do this:
FUN WITH UIBUTTONS AND CORE ANIMATION LAYERS
Five tips for creating stylish UIButtons (kudos to @cdo to provide this link)
EDIT - 3
, "" ( ) HSB UINavigationBar "" ( ).
Google , :
https://docs.google.com/spreadsheet/ccc?key=0AnKVtzkNS9scdGVRN01pa1NQcC1hdThNbEVzQU8wRlE&usp=sharing
: 3.5 "iPhone Simulator ( Xcode 4.6) iOS 6.1 HSB PhotoShop.
, , , . , :
/ ( ) RGB HSB " " " " (. ), tintColor UINavigationBar.
( ), " " " " "" ( , ve , "" )?