From c718bce60d952066fc27c5b130579e22240efbfc Mon Sep 17 00:00:00 2001 From: Joonas Javanainen Date: Sat, 4 Nov 2017 12:18:09 +0200 Subject: [PATCH] Add set_color_edit_options --- src/lib.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/lib.rs b/src/lib.rs index daf0a3e..5285082 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -670,6 +670,14 @@ impl<'ui> Ui<'ui> { ) -> ColorButton<'ui, 'p> { ColorButton::new(self, desc_id, color.into()) } + /// Initialize current options (generally on application startup) if you want to select a + /// default format, picker type, etc. Users will be able to change many settings, unless you + /// use .options(false) in your widget builders. + pub fn set_color_edit_options(&self, flags: ImGuiColorEditFlags) { + unsafe { + sys::igSetColorEditOptions(flags); + } + } } // Widgets: Trees