Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

iOS6/iOS 7 UIView transparency

So I have a game application, it has answer screen. Answer screen has 0.9 alpha and answer button has 1.0f. You can see on screenshot.

iOS 6

The same on iOS 7

iOS 7

Button alpha is still 1.0, but it looks transparent. If I do background view alpha 1.0 it works on iOS 7, but I extremely need user to see background under the view.

Please help.

like image 816
Vsevolod Kukhelny Avatar asked Nov 07 '13 15:11

Vsevolod Kukhelny


1 Answers

for the view that is semi-transparent set the alpha this way:

UIView *view.backgroundColor=[[UIColor whiteColor] colorWithAlphaComponent:.6];

not:

UIView *view.backgroundColor=[UIColor whiteColor];    
view.alpha=.6;
like image 119
Nikos M. Avatar answered Oct 04 '22 10:10

Nikos M.