关于UItableView的表头背景颜色的设置
来源:互联网 发布:淘宝图片保护怎么申请 编辑:程序博客网 时间:2024/05/16 09:28
在UITableView中,其实有很多的属性,运行的好,我们的应用程序会很流畅和美观,今天在网上找资料,和自己动手写了点小东西,关于UITableView表头的背景颜色和字体颜色的设置。
代码如下:
-(UIView *)tableView:(UITableView *)tableView viewForHeaderInSection:(NSInteger)section{ UIView *myView = [[UIView alloc]init]; [myView setBackgroundColor:[UIColor blueColor]]; UILabel *titleLabel = [[UILabel alloc]initWithFrame:CGRectMake(5, 0, 120, 44)]; titleLabel.textColor = [UIColor whiteColor]; titleLabel.backgroundColor = [UIColor clearColor]; titleLabel.text = [dateTitle objectAtIndex:section]; [myView addSubview:titleLabel]; return myView;}
0 0
- 关于UItableView的表头背景颜色的设置
- 关于UITableView设置背景颜色无效的问题
- 设置UITableView Section的背景颜色和字体颜色 ----------自
- 关于UITableView表索引的颜色设置
- UITableView背景颜色设置
- UITableView背景颜色设置
- ios 设置UITableView 选中行cell的背景颜色(自定义选中的背景颜色)
- 关于设置背景颜色影响的范围
- 关于设置对话框的背景颜色,和设置控件的字体颜色或背景颜色
- 关于设置对话框的背景颜色,和设置控件的字体颜色或背景颜色
- 关于设置对话框的背景颜色,和设置控件的字体颜色或背景颜色VC++
- iOS6 UITableView的背景颜色的修改
- iOS6 UITableView的背景颜色的修改
- 设置UITableView Section的背景颜色和字体颜色-自定义Section
- IOS_设置UITableView Section的背景颜色和字体颜色(自定义section布局)
- UITableView分区时的清除背景颜色
- UITableView 背景颜色不能改变的原因
- 改变UITableView的headerView、footerView背景颜色
- mysql 锁表详解
- linux目录结构详细介绍
- 关于Python笔试中提交代码多组测试的输入问题汇总
- WebLogic配置JNDI数据源
- 动静分离 ( 大白话 )
- 关于UItableView的表头背景颜色的设置
- OKhttp的封装工具类(可以直接使用)
- android---获取值AndroidManifest.xml中meta-data的value
- STM32小笔记(一) GPIO口的配置
- 一份React-Native学习指南
- sscanf-的用法
- Android流式标签
- android应用程序第12课:RelativeLayout
- 223. Rectangle Area