Replies: 1 comment
-
Well, since there is no feedback here I think it's going to depend entirely on #7899. If the new color formats are supported, |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
See Enhanced Color Format Support in XAML/Styles based on CSS #7899 for further details.
Color is the core RGB color model color struct used throughout the framework. Recently, HsvColor was added as it's needed in a few places like acrylic, ColorSpectrums and ColorPicker, etc. I wonder if a new
HslColor
should be added as well in a limited capacity for interop with HTML/CSS which uses HSL instead of HSV.This would be a very basic struct with conversion code to/from RGB and HSV. There are no plans to use it except to enable in the future support for "hsl(230, 100%, 40%)" for example in XAML and styles (it would be immediately converted to an RGB Color using conversions within HslColor itself).
Any thoughts or objections about this? There are so many color models we shouldn't attempt to support all especially if they aren't needed in core code. However, since the styling system is heavily based on CSS it seems reasonable in this case to support HSL parsing and conversion to RGB/HSV which is used in code.
Beta Was this translation helpful? Give feedback.
All reactions