For example:
-
I set UIView’s alpha property as
alpha = 0, Does that means itsopaqueproperty be treated asopaque=YES? -
How
opaque,alphaandbackgroundColoraffect the performance? -
Anything else?…
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
backgroundColoris the color that appears in the back of aUIView. By default, it’snil, resulting in a clear background color for theUIView. To assign a background to yourUIView, assign aUIColorlike so:You can also set the
backgroundColorto be an image:alphais the opacity of the view. You can use this attribute to fade aUIViewand make it partially transparent. The value can range from 0 (completely invisible) to 1 (completely opaque).opaqueis a boolean value that indicates whether theUIViewis opaque or not. If you’ve set thealphato anything less than 1, then you should setopaqueto NO:Apple’s documentation explains why and how the
opaqueproperty works: