您的位置:首页 > 产品设计 > UI/UE

设置UITableView的section之间的距离

2013-07-31 10:50 465 查看
设置UITableView的section之间的距离(本例中设置section之间的距离为20):

- (CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section
{
return 0.0;
}

- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section
{
return 20.0;
}

- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section
{
UIView *view = [[UIView alloc] initWithFrame:CGRectMake(0,0, 320,20)];
view.backgroundColor = [UIColor clearColor];
return [view autorelease];
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: