ios基本控件之UIPageControl
2016-01-18 13:31
387 查看
[pageControl setNumberOfPages:kImageCount];
5. 添加分页控件的监听事件(监听值改变事件)
[pageControl addTarget:self action:@selector(pageChanged:) forControlEvents:UIControlEventValueChanged];
效果:
UIPageControl
1. numberOfPages // 设置有多少页 默认为0
// 2) 设置页数[pageControl setNumberOfPages:kImageCount];
2. currentPage // 设置当前页
[pageControl setCurrentPage:0];3. pageIndicatorTintColor // 设置页码指示器颜色
[pageControl setPageIndicatorTintColor:[UIColor blackColor]];
4. currentPageIndicatorTintColor // 设置当前页码指示器颜色
[pageControl setCurrentPageIndicatorTintColor:[UIColor redColor]];5. 添加分页控件的监听事件(监听值改变事件)
[pageControl addTarget:self action:@selector(pageChanged:) forControlEvents:UIControlEventValueChanged];
效果:
相关文章推荐
- ios基本控件之UILabel
- ios基本控件之UIImageView
- QUiLoader 动态加载.ui文件
- ios基本控件之UIImagePickerController
- ios基本控件之UIDatePicker
- ios基本控件之UIControl
- ios基本控件之UIButton
- ios基本控件之UIAlertView
- ios基本控件之UIActivityIndicatorView
- amazon oa2 - insert a value into a cycled linked list
- iOS9之后支付宝的回调以及iOS8之后提示框UIAlertController
- UILabel设置富文本格式显示
- 在线安装maven插件问题:Cannot complete the install because one or more required items could not be found.
- 素材收集整理
- UICollectionView瀑布流的实现,带例子
- The server quit without updating PID file (mysql.pid)一次意外mysql停止运行备忘录
- UILabel 简单的富文本
- 如何通过代理之道UItableView上cell上面的button点击的是哪一行的
- java_easyui体系之DataGrid(4)[转]
- iOS 隐藏单个页面的UITabBar