I’m using a UITableView in plain mode because I want to have the sticky section headers. I have a custom background image which is set for the cell’s backgroundView but this image gets stretched the whole width of the UITableView.
How can I prevent it from getting stretched? I’ve tried setting UIViewContentModeCenter to no avail but I don’t really know which view to set it to (the tableview, the cell? the cell’s contentView?)
I actually didn’t try to set
UIViewContentModeCenteron thebackgroundView. So setting that made the image not stretch.