是否可以在UIProgressView中添加多种颜色? [英] Is it possible to add multiple colors in a UIProgressView?

查看:406
本文介绍了是否可以在UIProgressView中添加多种颜色?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

基本上,我想创建一个自定义进度视图,它将根据进度值具有不同的颜色。
它应该如下所示:

Basically, I want to create a custom progressview that will have different colors depending on the progress value. It should look like the following:

[-----红色----] [ - 黄色 - ] [ - 绿色 - ]

[-----Red----][--Yellow--][-Green-]

推荐答案

或者你可以看一下这个库 https://github.com/YannickL/YLProgressBar

Or you can look at this library https://github.com/YannickL/YLProgressBar

这篇关于是否可以在UIProgressView中添加多种颜色?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆