Struct imgui::ColorPicker
[−]
[src]
#[must_use]pub struct ColorPicker<'ui, 'p> { /* fields omitted */ }
Builder for a color picker widget.
Methods
impl<'ui, 'p> ColorPicker<'ui, 'p>
[src]
fn new(_: &Ui<'ui>, label: &'p ImStr, value: EditableColor<'p>) -> Self
[src]
Constructs a new color picker builder.
fn flags(self, flags: ImGuiColorEditFlags) -> Self
[src]
Replaces all current settings with the given flags.
fn alpha(self, value: bool) -> Self
[src]
Enables/disables the use of the alpha component.
fn small_preview(self, value: bool) -> Self
[src]
Enables/disables the colored square preview next to the inputs.
fn inputs(self, value: bool) -> Self
[src]
Enables/disables the input sliders/text widgets.
fn tooltip(self, value: bool) -> Self
[src]
Enables/disables the tooltip that appears when hovering the preview.
fn label(self, value: bool) -> Self
[src]
Enables/disables display of the inline text label (the label is in any case forwarded to the tooltip and picker).
fn side_preview(self, value: bool) -> Self
[src]
Enables/disables the bigger color preview on the right side of the picker.
fn alpha_bar(self, value: bool) -> Self
[src]
Enables/disables the vertical alpha bar/gradient in the color picker.
fn preview(self, preview: ColorPreview) -> Self
[src]
Sets the preview style.
fn rgb(self, value: bool) -> Self
[src]
Enables/disables the RGB inputs.
fn hsv(self, value: bool) -> Self
[src]
Enables/disables the HSV inputs.
fn hex(self, value: bool) -> Self
[src]
Enables/disables the HEX input.
fn mode(self, mode: ColorPickerMode) -> Self
[src]
Sets the hue/saturation/value editor mode.
fn format(self, format: ColorFormat) -> Self
[src]
Sets the formatting style of color components.
fn reference_color(self, ref_color: &'p [f32; 4]) -> Self
[src]
Sets the shown reference color.
fn build(self) -> bool
[src]
Builds the color picker.