From 11ed8504c3c821297d906acf4a42e83f558c305d Mon Sep 17 00:00:00 2001 From: Patrick Storz Date: Sat, 31 Aug 2019 18:33:26 +0200 Subject: Add appearance="colorbutton" to parameters of type color Renders a simple Gtk::ColorButton with label instead of the full ColorNotebook which is too large for many applications. Should likely be re-implemented bringing up a new Dialog that wraps an Inkscape::UI::Widget::ColorNotebook eventually, instead of relying on the Gtk::ColorButton's picker implementation which is inconsistent to existing pickers. --- src/extension/prefdialog/parameter-int.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/extension/prefdialog/parameter-int.cpp') diff --git a/src/extension/prefdialog/parameter-int.cpp b/src/extension/prefdialog/parameter-int.cpp index 1d768ca00..e18e1bddc 100644 --- a/src/extension/prefdialog/parameter-int.cpp +++ b/src/extension/prefdialog/parameter-int.cpp @@ -152,13 +152,12 @@ ParamInt::get_widget(sigc::signal *changeSignal) scale->set_size_request(400, -1); scale->show(); hbox->pack_start(*scale, true, true); - } - else if (_mode == DEFAULT) { + } else if (_mode == DEFAULT) { Gtk::Label *label = Gtk::manage(new Gtk::Label(_text, Gtk::ALIGN_START)); label->show(); hbox->pack_start(*label, true, true); - auto spin = Gtk::manage(new Inkscape::UI::Widget::SpinButton(fadjust, 1.0, 0)); + auto spin = Gtk::manage(new Inkscape::UI::Widget::SpinButton(fadjust, 1.0, 0)); spin->show(); hbox->pack_start(*spin, false, false); } -- cgit v1.2.3