Chromium Code Reviews| Index: ui/gfx/color_utils.h |
| diff --git a/ui/gfx/color_utils.h b/ui/gfx/color_utils.h |
| index f6ba46aa85f7f36b29e4bfc4dc51b0707eaf9897..b574288a547f27c64563cf6bca1dea01db9cd98b 100644 |
| --- a/ui/gfx/color_utils.h |
| +++ b/ui/gfx/color_utils.h |
| @@ -5,6 +5,8 @@ |
| #ifndef UI_GFX_COLOR_UTILS_H_ |
| #define UI_GFX_COLOR_UTILS_H_ |
| +#include <string> |
| + |
| #include "third_party/skia/include/core/SkColor.h" |
| #include "ui/gfx/gfx_export.h" |
| @@ -138,6 +140,12 @@ GFX_EXPORT bool IsInvertedColorScheme(); |
| // surface. |
| GFX_EXPORT SkColor DeriveDefaultIconColor(SkColor text_color); |
| +// Creates an rgba string for an SkColor. For example: 'rgba(255,0,255,0.5)'. |
| +GFX_EXPORT std::string SkColorToRGBAString(SkColor color); |
|
Dan Beam
2017/03/03 20:09:43
nit: SkColorToRgbaString()
RGBA -> Rgba
gonzalon
2017/03/03 20:20:04
Done.
|
| + |
| +// Creates an rgb string for an SkColor. For example: '255,0,255'. |
| +GFX_EXPORT std::string SkColorToRGBString(SkColor color); |
|
Dan Beam
2017/03/03 20:09:43
ToRgb
gonzalon
2017/03/03 20:20:05
Done.
|
| + |
| } // namespace color_utils |
| #endif // UI_GFX_COLOR_UTILS_H_ |