diff options
| author | Alex Valavanis <valavanisalex@gmail.com> | 2017-02-26 17:31:58 +0000 |
|---|---|---|
| committer | Alex Valavanis <valavanisalex@gmail.com> | 2017-02-26 17:31:58 +0000 |
| commit | 80cdddd1120a4922257039847978f50d660f31f2 (patch) | |
| tree | 51650dd96ccfe3c5d55c6cbe31e56bdd1181f658 /src | |
| parent | Don't block data entry into the text-tool font-size entry widget after an emp... (diff) | |
| download | inkscape-80cdddd1120a4922257039847978f50d660f31f2.tar.gz inkscape-80cdddd1120a4922257039847978f50d660f31f2.zip | |
Gtk+ 3 deprecation fixes
(bzr r15547)
Diffstat (limited to 'src')
| -rw-r--r-- | src/extension/extension.cpp | 4 | ||||
| -rw-r--r-- | src/extension/param/description.cpp | 2 | ||||
| -rw-r--r-- | src/extension/param/notebook.cpp | 4 |
3 files changed, 9 insertions, 1 deletions
diff --git a/src/extension/extension.cpp b/src/extension/extension.cpp index 8b5a687ef..6c6e2d71e 100644 --- a/src/extension/extension.cpp +++ b/src/extension/extension.cpp @@ -694,7 +694,11 @@ public: */ void addWidget(Gtk::Widget *widg, gchar const *tooltip, int indent) { if (widg) { +#if GTK_CHECK_VERSION(3,12,0) + widg->set_margin_start(indent * Parameter::GUI_INDENTATION); +#else widg->set_margin_left(indent * Parameter::GUI_INDENTATION); +#endif this->pack_start(*widg, false, false, 0); if (tooltip) { widg->set_tooltip_text(_(tooltip)); diff --git a/src/extension/param/description.cpp b/src/extension/param/description.cpp index 7cf818280..d0698a00e 100644 --- a/src/extension/param/description.cpp +++ b/src/extension/param/description.cpp @@ -88,7 +88,7 @@ ParamDescription::get_widget (SPDocument * /*doc*/, Inkscape::XML::Node * /*node } label->set_line_wrap(); //label->set_xalign(0); // requires gtkmm 3.16 - label->set_alignment(Gtk::ALIGN_START); + label->set_halign(Gtk::ALIGN_START); // TODO: Ugly "fix" for gtk3 width/height calculation of labels. // - If not applying any limits long labels will make the window grow horizontally until it uses up diff --git a/src/extension/param/notebook.cpp b/src/extension/param/notebook.cpp index 8ef48926e..de86d1005 100644 --- a/src/extension/param/notebook.cpp +++ b/src/extension/param/notebook.cpp @@ -223,7 +223,11 @@ Gtk::Widget * ParamNotebookPage::get_widget(SPDocument * doc, Inkscape::XML::Nod Gtk::Widget * widg = param->get_widget(doc, node, changeSignal); if (widg) { int indent = param->get_indent(); +#if GTK_CHECK_VERSION(3,12,0) + widg->set_margin_start(indent * Parameter::GUI_INDENTATION); +#else widg->set_margin_left(indent * Parameter::GUI_INDENTATION); +#endif vbox->pack_start(*widg, false, false, 0); gchar const * tip = param->get_tooltip(); |
