summaryrefslogtreecommitdiffstats
path: root/src/widgets/ruler.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/widgets/ruler.cpp')
-rw-r--r--src/widgets/ruler.cpp6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/widgets/ruler.cpp b/src/widgets/ruler.cpp
index 274e1df54..e4e72d86e 100644
--- a/src/widgets/ruler.cpp
+++ b/src/widgets/ruler.cpp
@@ -44,6 +44,7 @@
#define DEFAULT_RULER_FONT_SCALE PANGO_SCALE_X_SMALL
#define MINIMUM_INCR 5
+using Inkscape::Util::unit_table;
enum {
PROP_0,
@@ -258,8 +259,6 @@ sp_ruler_init (SPRuler *ruler)
gtk_widget_set_has_window (GTK_WIDGET (ruler), FALSE);
- Inkscape::Util::UnitTable unit_table;
-
priv->orientation = GTK_ORIENTATION_HORIZONTAL;
priv->unit = new Inkscape::Util::Unit(unit_table.getUnit("px"));
priv->lower = 0;
@@ -380,8 +379,6 @@ sp_ruler_set_property (GObject *object,
SPRuler *ruler = SP_RULER (object);
SPRulerPrivate *priv = SP_RULER_GET_PRIVATE (ruler);
- Inkscape::Util::UnitTable unit_table;
-
switch (prop_id)
{
case PROP_ORIENTATION:
@@ -1189,7 +1186,6 @@ sp_ruler_draw_ticks (SPRuler *ruler)
SPRulerMetric ruler_metric = ruler_metric_general; /* The metric to use for this unit system */
PangoLayout *layout;
PangoRectangle logical_rect, ink_rect;
- Inkscape::Util::UnitTable unit_table;
if (! gtk_widget_is_drawable (widget))
return;