开发者

Sections in UITableView with UITableViewStyleGrouped "taking" background with them on scroll

I have this code to set the background image of the UITableViewController:

self.tableView.backgroundColor = [UIColor colorWith开发者_Go百科PatternImage:[UIImage imageNamed:@"bg5.jpg"]];

Thats in viewDidLoad.

On scrolling the table the part of that background image around each section goes with it, annoyingly. If I add a title and header to these sections then the background goes with that too. :/

Any ideas what is causing this?

EDIT it doesn't seem to be taking the background with it to be honest, its as if each section has its own version of the background - which is even more annoying, because even when stationary the background looks out of place.

Thanks

Tom


self.navigationController.view.backgroundColor = [UIColor colorWithPatternImage:[UIImage imageNamed:@"Background.png"]];
self.tableView.backgroundColor = [UIColor clearColor]; 

does it. :)


if you are using a UITableViewCell. In Interface Builder try to set all of the outlets background to clear color. but I mean every thing. if you have labels, backgroundImages, even the view everything goes with clear color.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜