更改分组表的边框半径 [英] Changing grouped tables border radius

查看:60
本文介绍了更改分组表的边框半径的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否可以更改分组的UITableView的半径?圆角对于我的设计而言是非常大的方法。

Is it possible to change how radius of the grouped UITableView? The rounded corners are way to drastic for my design.

推荐答案

我相信,唯一的方法就是为表格单元格提供自己的背景图像。您可以提供3张图像,以使 UITableView 像苹果一样。

I believe that the only way to do this is to provide your own background images for your table cells. You can provide 3 images to have a rounded feel to the UITableView like Apple Does.


-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
将单元格的backgroundView设置为 UIView ,并根据单元格索引添加所需的图像。

in - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath set the cell's backgroundView to a UIView with the image you want based on the cell index. This will allow you to set the Top, Middle and Bottom.

这是一篇不错的文章

< a href = http://cocoawithlove.com/2009/04/easy-custom-uitableview-drawing.html rel = nofollow> http://cocoawithlove.com/2009/04/easy-custom-uitableview- drawing.html

只需确保 dequeueReusableCellWithIdentifier:

这篇关于更改分组表的边框半径的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆