swift中UIProgressView的使用
来源:互联网 发布:java 根据模板生成pdf 编辑:程序博客网 时间:2024/05/04 22:23
默认高度是2.0。自定义高度无效,可通过transform属性设置高度
// 实例化(默认高度是2.0。自定义高度无效,可通过transform属性设置高度)let progressview = UIProgressView(frame: CGRectMake(10.0, 10.0, (CGRectGetWidth(self.view.bounds) - 10.0 * 2), 10.0))self.view.addSubview(progressview) progressview.backgroundColor = UIColor.greenColor() // 样式progressview.progressViewStyle = UIProgressViewStyle.Bar // 初始化进度(默认是0.0,且值范围为0.0~1.0)progressview.setProgress(0.3, animated: true) // 进度条颜色progressview.progressTintColor = UIColor.redColor()progressview.trackTintColor = UIColor.brownColor()progressview.tintColor = UIColor.greenColor() // 更改进度条高度progressview.transform = CGAffineTransformMakeScale(1.0, 3.0);
// 默认高度2.0let progressview00 = UIProgressView(frame: CGRectMake(10.0, 60.0, (CGRectGetWidth(self.view.bounds) - 10.0 * 2), 10.0))self.view.addSubview(progressview00)progressview00.setProgress(0.6, animated: true)
源码:https://github.com/potato512/SYSwiftLearning
0 0
- swift中UIProgressView的使用
- swift中UIProgressView的使用
- swift UIProgressView UISilder UISwitch使用
- swift UIProgressView UISilder UISwitch使用
- mono touch中UIProgressView的使用
- swift UIProgressView
- swift UIProgressView
- UIProgressView的详细使用
- UIProgressView的详细使用
- iOS --------UIProgressView的使用
- UIProgressView的使用
- UIProgressView的详细使用
- UIProgressView的使用
- UIProgressView的使用
- Swift - 进度条(UIProgressView)的用法
- Swift UISwitch/UIProgressView/UISlider
- Swift 进度条 UIProgressView
- Swift 之 UIProgressView
- 图像处理库的比较:OpenCV,FreeImage,CImg,CxImage
- cookie和session的区别
- 第七周项目4--队列数组
- 欢迎使用CSDN-markdown编辑器
- PHP时间格式大全
- swift中UIProgressView的使用
- 百度地图JavaScript开源库
- 蓝牙核心技术了解
- android bluetooth——蓝牙的开启、搜索、配对与连接
- osg、osgearth支持中文
- C++程序中的内存布局
- iPhone开源电子书开发
- Android反射机制实现与原理
- 正则表达式网址摘录