What is RGB and alpha value for clear color? i want to do it programmatic, don't need [UIColor clearColor]...??
These colors can be useful for charts and graphics with overlapping elements. The rgb() command is the key: you define a new color using numerical values (0–255) for red, green and blue. In addition, you set an alpha value (also 0–255), which sets the transparency (0 being fully transparent and 255 being “solid”).
In your Colors Pane, select the RGB Slider view. Then use the Color Picker (magnifying glass) to select the color to analyze. RGB values will appear next to the sliders.
In RGB, a color is defined as a mixture of pure red, green, and blue lights of various strengths. Each of the red, green and blue light levels is encoded as a number in the range 0.. 255, with 0 meaning zero light and 255 meaning maximum light.
You can actually apply a hex code color that is transparent. The hex code for transparent white (not that the color matters when it is fully transparent) is two zeros followed by white's hex code of FFFFFF or 00FFFFFF.
According to the Documentation:
"Returns a color object whose grayscale and alpha values are both 0.0."
To represent clear color in rgb format one may use
'rgba(0,0,0,0)'
It just includes the alpha value.
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