summaryrefslogtreecommitdiffstats
path: root/src/extension/param/bool.cpp
diff options
context:
space:
mode:
authorMarc Jeanmougin <marc@jeanmougin.fr>2018-01-01 20:26:22 +0000
committerMarc Jeanmougin <marc@jeanmougin.fr>2018-01-01 20:26:22 +0000
commitc8ffe48b5f713bc9fecbb0e83bda2adffa1c5b0b (patch)
tree2ed6e55f942c728377dadbd3f0c4038a777dbb79 /src/extension/param/bool.cpp
parentFix minor typos (diff)
parentUse Gtk::CheckButton label instead of a separate Gtk::Label (diff)
downloadinkscape-c8ffe48b5f713bc9fecbb0e83bda2adffa1c5b0b.tar.gz
inkscape-c8ffe48b5f713bc9fecbb0e83bda2adffa1c5b0b.zip
Merge branch 'checkboxlabel' of gitlab.com:darktrojan/inkscape
Diffstat (limited to 'src/extension/param/bool.cpp')
-rw-r--r--src/extension/param/bool.cpp10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/extension/param/bool.cpp b/src/extension/param/bool.cpp
index 2c7e32480..80bc89138 100644
--- a/src/extension/param/bool.cpp
+++ b/src/extension/param/bool.cpp
@@ -83,8 +83,8 @@ public:
*
* @param param Which parameter to adjust on changing the check button
*/
- ParamBoolCheckButton (ParamBool * param, SPDocument * doc, Inkscape::XML::Node * node, sigc::signal<void> * changeSignal) :
- Gtk::CheckButton(), _pref(param), _doc(doc), _node(node), _changeSignal(changeSignal) {
+ ParamBoolCheckButton (ParamBool * param, gchar * label, SPDocument * doc, Inkscape::XML::Node * node, sigc::signal<void> * changeSignal) :
+ Gtk::CheckButton(label), _pref(param), _doc(doc), _node(node), _changeSignal(changeSignal) {
this->set_active(_pref->get(NULL, NULL) /**\todo fix */);
this->signal_toggled().connect(sigc::mem_fun(this, &ParamBoolCheckButton::on_toggle));
return;
@@ -133,11 +133,7 @@ Gtk::Widget *ParamBool::get_widget(SPDocument * doc, Inkscape::XML::Node * node,
auto hbox = Gtk::manage(new Gtk::Box(Gtk::ORIENTATION_HORIZONTAL, Parameter::GUI_PARAM_WIDGETS_SPACING));
hbox->set_homogeneous(false);
- Gtk::Label * label = Gtk::manage(new Gtk::Label(_text, Gtk::ALIGN_START));
- label->show();
- hbox->pack_end(*label, true, true);
-
- ParamBoolCheckButton * checkbox = Gtk::manage(new ParamBoolCheckButton(this, doc, node, changeSignal));
+ ParamBoolCheckButton * checkbox = Gtk::manage(new ParamBoolCheckButton(this, _text, doc, node, changeSignal));
checkbox->show();
hbox->pack_start(*checkbox, false, false);