UITableViewStyle.grouped 时, 头部默认高度

UITableViewStyle.grouped 时, 头部默认高度

注意代码顺序

self.backgroundColor = backgroundColorGray
self.separatorColor = self.backgroundColor
self.dataSource = self
self.delegate = self
self.tableFooterView = UIView()
func tableView(_ tableView: UITableView, heightForHeaderInSection section: Int) -> CGFloat {
        return 270
}
func tableView(_ tableView: UITableView, heightForFooterInSection section: Int) -> CGFloat {
        return 0.001
}

你可能感兴趣的:(UITableViewStyle.grouped 时, 头部默认高度)