diff --git a/egui/src/widgets/color_picker.rs b/egui/src/widgets/color_picker.rs index 63e24119bb6..474b0505fbd 100644 --- a/egui/src/widgets/color_picker.rs +++ b/egui/src/widgets/color_picker.rs @@ -308,8 +308,10 @@ fn color_picker_hsvag_2d(ui: &mut Ui, hsva: &mut HsvaGamma, alpha: Alpha) { color_slider_2d(ui, v, s, |v, s| HsvaGamma { s, v, ..opaque }.into()); } +//// Shows a color picker where the user can change the given [`Hsva`] color. +/// /// Returns `true` on change. -fn color_picker_hsva_2d(ui: &mut Ui, hsva: &mut Hsva, alpha: Alpha) -> bool { +pub fn color_picker_hsva_2d(ui: &mut Ui, hsva: &mut Hsva, alpha: Alpha) -> bool { let mut hsvag = HsvaGamma::from(*hsva); ui.vertical(|ui| { color_picker_hsvag_2d(ui, &mut hsvag, alpha); @@ -323,7 +325,7 @@ fn color_picker_hsva_2d(ui: &mut Ui, hsva: &mut Hsva, alpha: Alpha) -> bool { } } -/// Shows a color picker where the user can change the given color. +/// Shows a color picker where the user can change the given [`Color32`] color. /// /// Returns `true` on change. pub fn color_picker_color32(ui: &mut Ui, srgba: &mut Color32, alpha: Alpha) -> bool {