summaryrefslogtreecommitdiffstats
path: root/src/sp-rect.cpp
diff options
context:
space:
mode:
authorKrzysztof Kosi??ski <tweenk.pl@gmail.com>2011-08-27 14:58:22 +0000
committerKrzysztof Kosinski <tweenk.pl@gmail.com>2011-08-27 14:58:22 +0000
commit24526cceccb4ed103a6324756476c64efb3fb5dd (patch)
tree24abb1d2b1bdb6156a83f2d393cbdc4747fda4ac /src/sp-rect.cpp
parentRemove NRRect from paint servers and temporary calculations (diff)
downloadinkscape-24526cceccb4ed103a6324756476c64efb3fb5dd.tar.gz
inkscape-24526cceccb4ed103a6324756476c64efb3fb5dd.zip
Remove all NRRect use.
(bzr r10582.1.5)
Diffstat (limited to 'src/sp-rect.cpp')
-rw-r--r--src/sp-rect.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sp-rect.cpp b/src/sp-rect.cpp
index 729e2a34c..22a403345 100644
--- a/src/sp-rect.cpp
+++ b/src/sp-rect.cpp
@@ -173,8 +173,8 @@ sp_rect_update(SPObject *object, SPCtx *ctx, guint flags)
SPRect *rect = (SPRect *) object;
SPStyle *style = object->style;
SPItemCtx const *ictx = (SPItemCtx const *) ctx;
- double const w = (ictx->vp.x1 - ictx->vp.x0);
- double const h = (ictx->vp.y1 - ictx->vp.y0);
+ double const w = ictx->viewport.width();
+ double const h = ictx->viewport.height();
double const em = style->font_size.computed;
double const ex = 0.5 * em; // fixme: get x height from pango or libnrtype.
rect->x.update(em, ex, w);