The documentation says the clearColor's grayscale and alpha = 0. What does that actually mean? Is it just a color to match whatever the background is?
clearColor is exactly what it says, its clear, so whatever the color is of the view behind the clearColor view, will show through. Think of it as being like clear glass, it is see through e.g. has an alpha value of 0 (zero).
So, say your window background is Red and the background of the view you place on on top of it is clearColor then you will see Red...
Not sure if you wanted the individual definitions. Yes, the [UIColor clearColor]
is transparent. However specific to "The documentation says the clearColor's grayscale and alpha = 0. What does that actually mean?"
a) A grayscale of 0 is equal to the color black.
b) alpha is equal to opacity where 1 is solid and 0 is transparent.
Therefore the documentation is saying that clearColor
is the color black with a completely transparent opacity. (which makes what color it is immaterial)
Basically whatever color/image is behind it will shine through with 100% clarity.
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