I have a standard, grouped UITableView that I am trying to add a custom background to (instead of the boring gray stripes). Ultimately, my designer would like the table view to “slide over” or “float over” the background. I have gotten as far as setting the background of the table view to “clear” with the hopes of showing a static image underneath.
How can I modify my current classes and view controllers to achieve this?
You need to do one of two things.
1) Add an image view under the table view. You can do this like this:
The caveat here is that sometimes you’d rather not manipulate the view stack in code.
2) You can draw the background yourself in a UITableView subclass. If you do this, make sure you’re setting the tableview’s bg color to clear first. Here’s my class:
and:
Hope this helps!