Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Set transparency in image IOS

I have a table view, I have addeed image as subview for header, but that image is shown with bagckground white color,how to set transparency for image.

TIA

like image 589
Feroz Avatar asked Aug 06 '12 08:08

Feroz


2 Answers

For this you have to set alpha of your UIImageView

Your_ImageView.alpha = 0.6;

You can also do it in your xib file

like image 186
superGokuN Avatar answered Sep 20 '22 12:09

superGokuN


Assuming the name of your view is myTransparentSubView:

[myTransparentSubView setBackgroundColor:[UIColor clearColor]];

If you are using the Interface Builder then set the background Color property accordingly within IB.

like image 29
Hermann Klecker Avatar answered Sep 20 '22 12:09

Hermann Klecker