答案 0 :(得分:1)
也许这会有所帮助: -
将单元格颜色设置为
cell.backgroundColor=[UIColor clearColor];
然后: -
UIView *view = [[UIView alloc] initWithFrame:self.tableview.frame];
CAGradientLayer *gradient = [CAGradientLayer layer];
gradient.frame = view.bounds;
gradient.colors = @[(id)[UIColor blackColor].CGColor,(id)[UIColor whiteColor].CGColor];
[view.layer insertSublayer:gradient atIndex:0];
self.tableview.backgroundView=view;