十六进制到UIColorfromRGB [英] HEX to UIColorfromRGB

查看:61
本文介绍了十六进制到UIColorfromRGB的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在教程此处

这非常简单明了,只需两个步骤.但是,在最后一步,我在UITextField中将十六进制代码作为hexText.text,但是如何将其放入UIColorFromRGB中?

It's fairly straight forward and simple, only 2 steps. But on the last step, I have the HEX code in a UITextField as hexText.text, but how do i put that into UIColorFromRGB?

推荐答案

here is a solution that avoids the macro stuff. You can add it to a category to UIColor and use it more nicely.

这篇关于十六进制到UIColorfromRGB的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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