Expand description
Color picker widgets.
EnumsΒ§
- Alpha
- What options to show for alpha
ConstantsΒ§
- N π
- Number of vertices per dimension in the color sliders. We need at least 6 for hues, and more for smooth 2D areas. Should always be a multiple of 6 to hit the peak hues in HSV/HSL (every 60Β°).
FunctionsΒ§
- background_
checkers π - color_
button π - color_
cache_ πget - color_
cache_ πset - color_
edit_ button_ hsva - color_
edit_ button_ rgb - Shows a button with the given color. If the user clicks the button, a full color picker is shown.
- color_
edit_ button_ rgba - Shows a button with the given color. If the user clicks the button, a full color picker is shown.
- color_
edit_ button_ srgb - Shows a button with the given color.
If the user clicks the button, a full color picker is shown.
The given color is in
sRGB
space. - color_
edit_ button_ srgba - Shows a button with the given color. If the user clicks the button, a full color picker is shown.
- color_
picker_ color32 - Shows a color picker where the user can change the given
Color32
color. - color_
picker_ hsva_ 2d - Shows a color picker where the user can change the given
Hsva
color. - color_
picker_ πhsvag_ 2d - color_
slider_ π1d - color_
slider_ π2d - Arguments
- contrast_
color π - input_
type_ πbutton_ ui - is_
additive_ πalpha - We use a negative alpha for additive colors within this file (a bit ironic).
- rgba_
edit_ πui - Shows 4
DragValue
widgets to be used to edit the RGBA f32 values. AlphaβsDragValue
is hidden whenAlpha::Opaque
. - show_
color - Show a color with background checkers to demonstrate transparency (if any).
- show_
color32 π - show_
color_ at - Show a color with background checkers to demonstrate transparency (if any).
- srgba_
edit_ πui - Shows 4
DragValue
widgets to be used to edit the RGBA u8 values. AlphaβsDragValue
is hidden whenAlpha::Opaque
. - use_
color_ πcache