In Cocoa, specifically the iPhone SDK, the opaque
property is described as:
If opaque, the drawing operation assumes that the view fills its bounds and can draw more efficiently. The results are unpredictable if opaque and the view doesn’t fill its bounds. Set this property to NO if the view is fully or partially transparent.
In my experience, if you have a view (label, table cell, etc.) with backgroundColor
set to [UIColor clearColor]
, you do not need to set opaque
to NO
for it to appear properly (with a clear background).
Intuitively, doing this would require also setting opaque to NO, but I've never run into problems.
Can you mix opaque=YES and clearColor, or am I living on borrowed time? It doesn't seem to be specifically documented anywhere.