开发者

Grouped table view -- section spacing

开发者 https://www.devze.com 2023-01-25 19:59 出处:网络
In a grouped table view can I control the spacing between 开发者_如何学Pythontwo sections?Agree with \'viking\'.. If you are still having troubles, I have noticed that if you create the table through

In a grouped table view can I control the spacing between 开发者_如何学Pythontwo sections?


Agree with 'viking'.. If you are still having troubles, I have noticed that if you create the table through IB it automatically creates a table header/footer section. If you go into the measurments(in IB) and decrease/increase the height of each section you will see the spacing between grouped sections change.


tableView:heightForHeaderInSection: and tableView:heightForFooterInSection:

together these control the space in between sections of a grouped UITableView. You cannot return 0, it will use the default value if you do, so use a small float (0.01) to reduce the space to almost nothing.


implement tableView:viewForHeaderInSection: or tableView:heightForHeaderInSection:

0

精彩评论

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