Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

UITableView Header shows content behind it

I have a UITableView with headings on top of a textured background. I want the header to stick at the top, which they do, but I don't want the cells to show behind it as they go by. Here is an example:

UITableView image

New Content is the header. You can see the rows of data under it as they scroll by. I can't set the background of the header because it has to show the texture from the window behind it. How can I not show the rows underneath the header?

like image 276
CaseyB Avatar asked Nov 04 '22 03:11

CaseyB


1 Answers

Basically, you can't - not without making the headers opaque. The cells are what is behind the headers, so if you make the headers transparent, the cells are what you will see behind them.

like image 106
matt Avatar answered Nov 10 '22 05:11

matt