设置UITableView section间距

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

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

- (UIView *)tableView:(UITableView *)tableView viewForFooterInSection:(NSInteger)section
{
    UIView *view = [[UIView alloc] initWithFrame:CGRectMake(0,0, 320,5)];
    view.backgroundColor = [UIColor clearColor];
    return view;
}

5即为所设置的间距

原文地址:https://www.cnblogs.com/punkrocker/p/4597709.html