summaryrefslogtreecommitdiffstats
path: root/src/live_effects/parameter
diff options
context:
space:
mode:
authorMaximilian Albert <maximilian.albert@gmail.com>2008-07-30 10:56:44 +0000
committercilix42 <cilix42@users.sourceforge.net>2008-07-30 10:56:44 +0000
commit71917528fa6897d596be4260fbb85a9a2ef9fe07 (patch)
tree3a2b9aa85879defd51966e846984a1dddc14feeb /src/live_effects/parameter
parentMake text widget for TextParams work and re-enable it (diff)
downloadinkscape-71917528fa6897d596be4260fbb85a9a2ef9fe07.tar.gz
inkscape-71917528fa6897d596be4260fbb85a9a2ef9fe07.zip
New 'internal' TextParam which doesn't display a widget (useful if the text should not be settable by the user); lpe-ruler uses it now
(bzr r6470)
Diffstat (limited to 'src/live_effects/parameter')
-rw-r--r--src/live_effects/parameter/text.cpp4
-rw-r--r--src/live_effects/parameter/text.h30
2 files changed, 29 insertions, 5 deletions
diff --git a/src/live_effects/parameter/text.cpp b/src/live_effects/parameter/text.cpp
index bf11192dd..f55dca4d8 100644
--- a/src/live_effects/parameter/text.cpp
+++ b/src/live_effects/parameter/text.cpp
@@ -36,10 +36,6 @@ TextParam::TextParam( const Glib::ustring& label, const Glib::ustring& tip,
sp_canvastext_set_coords (canvas_text, 0, 0);
}
-TextParam::~TextParam()
-{
-}
-
void
TextParam::param_set_default()
{
diff --git a/src/live_effects/parameter/text.h b/src/live_effects/parameter/text.h
index ee47f028f..c3eddd9fa 100644
--- a/src/live_effects/parameter/text.h
+++ b/src/live_effects/parameter/text.h
@@ -31,7 +31,7 @@ public:
Inkscape::UI::Widget::Registry* wr,
Effect* effect,
const Glib::ustring default_value = "");
- virtual ~TextParam();
+ virtual ~TextParam() {}
virtual Gtk::Widget * param_newWidget(Gtk::Tooltips * tooltips);
@@ -57,9 +57,37 @@ private:
SPCanvasText *canvas_text;
};
+/*
+ * 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
+ */
+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() {}
+
+ virtual Gtk::Widget * param_newWidget(Gtk::Tooltips * tooltips) { return NULL; }
+};
} //namespace LivePathEffect
} //namespace Inkscape
#endif
+
+/*
+ Local Variables:
+ mode:c++
+ c-file-style:"stroustrup"
+ c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
+ indent-tabs-mode:nil
+ fill-column:99
+ End:
+*/
+// vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4 :