From: cilix42 Date: Thu, 31 Jul 2008 15:48:39 +0000 (+0000) Subject: Remove UI stuff from internal text parameter X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=ea5122612095accfe797b5317e98fa1f47540c8d;p=inkscape.git Remove UI stuff from internal text parameter --- diff --git a/src/live_effects/lpe-ruler.cpp b/src/live_effects/lpe-ruler.cpp index 8b457da58..f60c7b9fa 100644 --- a/src/live_effects/lpe-ruler.cpp +++ b/src/live_effects/lpe-ruler.cpp @@ -27,7 +27,7 @@ LPERuler::LPERuler(LivePathEffectObject *lpeobject) : mark_distance(_("Mark distance"), _("Distance between ruler marks"), "mark_distance", &wr, this, 20), mark_length(_("Mark length"), _("Length of ruler marks"), "mark_length", &wr, this, 10), scale(_("Scale factor"), _("Scale factor for ruler distance (only affects on-canvas display of ruler length)"), "scale", &wr, this, 1.0), - info_text(_("Info text"), _("Parameter for text creation"), "info_text", &wr, this, ""), + info_text(this), unit(_("Unit"), _("Unit"), "unit", &wr, this) { registerParameter(dynamic_cast(&mark_distance)); diff --git a/src/live_effects/parameter/text.h b/src/live_effects/parameter/text.h index fafe9fe32..be42cffbc 100644 --- a/src/live_effects/parameter/text.h +++ b/src/live_effects/parameter/text.h @@ -60,19 +60,15 @@ private: }; /* - * This parameter does not display a widget in the LPE dialog; LPEs can use it to display text that - * should not be settable by the user + * This parameter does not display a widget in the LPE dialog; LPEs can use it to display on-canvas + * text that should not be settable by the user. Note that since no widget is provided, the + * parameter must be initialized differently than usual (only with a pointer to the parent effect; + * no label, no tooltip, etc.). */ class TextParamInternal : public TextParam { public: - TextParamInternal(const Glib::ustring& label, - const Glib::ustring& tip, - const Glib::ustring& key, - Inkscape::UI::Widget::Registry* wr, - Effect* effect, - const Glib::ustring default_value = "") : - TextParam(label, tip, key, wr, effect, default_value) {} - //virtual ~TextParamInternal() {} + TextParamInternal(Effect* effect) : + TextParam("", "", "", NULL, effect) {} virtual Gtk::Widget * param_newWidget(Gtk::Tooltips * tooltips) { return NULL; } };