diff options
Diffstat (limited to 'src/extension/param/description.cpp')
| -rw-r--r-- | src/extension/param/description.cpp | 39 |
1 files changed, 17 insertions, 22 deletions
diff --git a/src/extension/param/description.cpp b/src/extension/param/description.cpp index 07aaa07cc..7f7d2d976 100644 --- a/src/extension/param/description.cpp +++ b/src/extension/param/description.cpp @@ -26,17 +26,19 @@ namespace Extension { /** \brief Initialize the object, to do that, copy the data. */ -ParamDescription::ParamDescription (const gchar * name, - const gchar * guitext, - const gchar * desc, - const Parameter::_scope_t scope, - bool gui_hidden, - const gchar * gui_tip, - Inkscape::Extension::Extension * ext, - Inkscape::XML::Node * xml, - AppearanceMode mode) : - Parameter(name, guitext, desc, scope, gui_hidden, gui_tip, ext), - _value(NULL), _mode(mode), _indent(0) +ParamDescription::ParamDescription(const gchar * name, + const gchar * guitext, + const gchar * desc, + const Parameter::_scope_t scope, + bool gui_hidden, + const gchar * gui_tip, + int indent, + Inkscape::Extension::Extension * ext, + Inkscape::XML::Node * xml, + AppearanceMode mode) + : Parameter(name, guitext, desc, scope, gui_hidden, gui_tip, indent, ext) + , _value(NULL) + , _mode(mode) { // printf("Building Description\n"); const char * defaultval = NULL; @@ -50,11 +52,6 @@ ParamDescription::ParamDescription (const gchar * name, _context = xml->attribute("msgctxt"); - const char * indent = xml->attribute("indent"); - if (indent != NULL) { - _indent = atoi(indent) * 12; - } - return; } @@ -76,15 +73,13 @@ ParamDescription::get_widget (SPDocument * /*doc*/, Inkscape::XML::Node * /*node } else { newguitext = _(_value); } - + Gtk::Label * label; - int padding = 12 + _indent; if (_mode == HEADER) { label = Gtk::manage(new Gtk::Label(Glib::ustring("<b>") +newguitext + Glib::ustring("</b>"), Gtk::ALIGN_START)); - label->set_margin_top(5); - label->set_margin_bottom(5); + label->set_margin_top(5); + label->set_margin_bottom(5); label->set_use_markup(true); - padding = _indent; } else { label = Gtk::manage(new Gtk::Label(newguitext, Gtk::ALIGN_START)); } @@ -92,7 +87,7 @@ ParamDescription::get_widget (SPDocument * /*doc*/, Inkscape::XML::Node * /*node label->show(); Gtk::HBox * hbox = Gtk::manage(new Gtk::HBox(false, 4)); - hbox->pack_start(*label, true, true, padding); + hbox->pack_start(*label, true, true); hbox->show(); return hbox; |
