Java Android 颜色选择器

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/2442407/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-13 07:42:31  来源:igfitidea点击:

Android Color Picker

javaandroidcolors

提问by Kleptine

Does anyone know of a quick color picker widget that I could grab to use in my application?

有谁知道我可以在我的应用程序中使用的快速颜色选择器小部件?

I've seen one in a few different applications that have a wheel with colors, and that you tap in the center to select, but I'm not sure where to find it.

我在几个不同的应用程序中看到过一个带有颜色的轮子,您可以点击中心进行选择,但我不确定在哪里可以找到它。

Any color picker would be fine though.

不过,任何颜色选择器都可以。

回答by yanchenko

A rather advanced one from OI Flashlight is here.

来自 OI Flashlight 的一款相当先进的产品在这里

回答by DavidG

This one from Yuku ( http://code.google.com/p/android-color-picker/) is really kewl. It's open source under Apache license, and is much nicer than the Android sample one. It's also a library project, so it's really simple to integrate. I've just added it last week to DigiClock widget, and so far my users are impressed!

这个来自 Yuku ( http://code.google.com/p/android-color-picker/) 真的是 kewl。它是 Apache 许可下的开源软件,比 Android 示例要好得多。它也是一个库项目,因此集成起来非常简单。我上周刚刚将它添加到 DigiClock 小部件,到目前为止我的用户印象深刻!

回答by Macarse

You can use CommonsWare's cwac-colormixer.

您可以使用 CommonsWare 的cwac-colormixer

It's an android library now! :)

它现在是一个 android 库!:)

回答by Attenzione

Created ColorPickerPreference to use in preferences. Used above submitted color-picker-view can find it here: https://github.com/attenzione/android-ColorPickerPreference

创建 ColorPickerPreference 以在首选项中使用。使用上面提交的 color-picker-view 可以在这里找到它:https: //github.com/attenzione/android-ColorPickerPreference

Also will share similar ColorPickerPreference with Rotary Picker (used it before)

还将与 Rotary Picker 共享类似的 ColorPickerPreference(以前使用过)