更改分组表边界半径

时间:2012-01-27 01:24:24

标签: iphone ios uitableview core-graphics

是否可以更改分组UITableView的半径?圆角是我设计的重点。

3 个答案:

答案 0 :(得分:0)

不,不是。您可以使用标准的tableview和一些自定义背景图像复制它。

答案 1 :(得分:0)

我认为唯一的方法是为您的表格单元格提供自己的背景图像。您可以提供3张图像,以便像Apple一样对UITableView感觉圆润。

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath 根据单元格索引将单元格的backgroundView设置为UIView所需的图像。这将允许您设置顶部,中部和底部。

这是一篇非常好的文章

http://cocoawithlove.com/2009/04/easy-custom-uitableview-drawing.html

确保dequeueReusableCellWithIdentifier:

答案 2 :(得分:0)

您必须根据自己的选择更改cell.backgroundViewcell.selectedBackgroundView

相关问题