summaryrefslogtreecommitdiffstats
path: root/src/rect-context.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2013-08-09 11:47:56 +0000
committerJaviertxo <jtx@jtx.marker.es>2013-08-09 11:47:56 +0000
commit4e358f420a7a1512c722d9eccd864416bc4c075b (patch)
tree223e826158e09ab2c864abf0214fe1e6a714ab61 /src/rect-context.cpp
parentUpdate to trunk (diff)
parentRemove missing files from POTFILES.in (diff)
downloadinkscape-4e358f420a7a1512c722d9eccd864416bc4c075b.tar.gz
inkscape-4e358f420a7a1512c722d9eccd864416bc4c075b.zip
update to trunk
(bzr r11950.1.127)
Diffstat (limited to 'src/rect-context.cpp')
-rw-r--r--src/rect-context.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/rect-context.cpp b/src/rect-context.cpp
index 06745564f..17675745f 100644
--- a/src/rect-context.cpp
+++ b/src/rect-context.cpp
@@ -35,7 +35,6 @@
#include "message-context.h"
#include "pixmaps/cursor-rect.xpm"
#include "rect-context.h"
-#include "sp-metrics.h"
#include <glibmm/i18n.h>
#include "xml/repr.h"
#include "xml/node-event-vector.h"
@@ -483,8 +482,10 @@ static void sp_rect_drag(SPRectContext &rc, Geom::Point const pt, guint state)
// status text
double rdimx = r.dimensions()[Geom::X];
double rdimy = r.dimensions()[Geom::Y];
- GString *xs = SP_PX_TO_METRIC_STRING(rdimx, desktop->namedview->getDefaultMetric());
- GString *ys = SP_PX_TO_METRIC_STRING(rdimy, desktop->namedview->getDefaultMetric());
+ Inkscape::Util::Quantity rdimx_q = Inkscape::Util::Quantity(rdimx, "px");
+ Inkscape::Util::Quantity rdimy_q = Inkscape::Util::Quantity(rdimy, "px");
+ GString *xs = g_string_new(rdimx_q.string(*desktop->namedview->doc_units).c_str());
+ GString *ys = g_string_new(rdimy_q.string(*desktop->namedview->doc_units).c_str());
if (state & GDK_CONTROL_MASK) {
int ratio_x, ratio_y;
bool is_golden_ratio = false;