summaryrefslogtreecommitdiffstats
path: root/src/desktop.cpp
diff options
context:
space:
mode:
authorMatthew Petroff <matthew@mpetroff.net>2013-09-20 17:09:19 +0000
committerMatthew Petroff <matthew@mpetroff.net>2013-09-20 17:09:19 +0000
commitcf74f053a081f6f4b460da9cd72afaab23d54d13 (patch)
tree427aa22ba3dcad9b55edb90522b5ab0208074e06 /src/desktop.cpp
parentUsing inkscape compact settings to save the icons.svg file (diff)
parentMerge from trunk. (diff)
downloadinkscape-cf74f053a081f6f4b460da9cd72afaab23d54d13.tar.gz
inkscape-cf74f053a081f6f4b460da9cd72afaab23d54d13.zip
Merge Google Summer of Code unit improvement.
(bzr r12554)
Diffstat (limited to 'src/desktop.cpp')
-rw-r--r--src/desktop.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/desktop.cpp b/src/desktop.cpp
index 69d83d8da..d19a99da6 100644
--- a/src/desktop.cpp
+++ b/src/desktop.cpp
@@ -242,7 +242,7 @@ SPDesktop::init (SPNamedView *nv, SPCanvas *aCanvas, Inkscape::UI::View::EditWid
// display rect and zoom are now handled in sp_desktop_widget_realize()
Geom::Rect const d(Geom::Point(0.0, 0.0),
- Geom::Point(document->getWidth(), document->getHeight()));
+ Geom::Point(document->getWidth().value("px"), document->getHeight().value("px")));
SP_CTRLRECT(page)->setRectangle(d);
SP_CTRLRECT(page_border)->setRectangle(d);
@@ -259,7 +259,7 @@ SPDesktop::init (SPNamedView *nv, SPCanvas *aCanvas, Inkscape::UI::View::EditWid
/* Connect event for page resize */
- _doc2dt[5] = document->getHeight();
+ _doc2dt[5] = document->getHeight().value("px");
sp_canvas_item_affine_absolute (SP_CANVAS_ITEM (drawing), _doc2dt);
_modified_connection = namedview->connectModified(sigc::bind<2>(sigc::ptr_fun(&_namedview_modified), this));
@@ -1108,7 +1108,7 @@ void
SPDesktop::zoom_page()
{
Geom::Rect d(Geom::Point(0, 0),
- Geom::Point(doc()->getWidth(), doc()->getHeight()));
+ Geom::Point(doc()->getWidth().value("px"), doc()->getHeight().value("px")));
if (d.minExtent() < 1.0) {
return;
@@ -1125,12 +1125,12 @@ SPDesktop::zoom_page_width()
{
Geom::Rect const a = get_display_area();
- if (doc()->getWidth() < 1.0) {
+ if (doc()->getWidth().value("px") < 1.0) {
return;
}
Geom::Rect d(Geom::Point(0, a.midpoint()[Geom::Y]),
- Geom::Point(doc()->getWidth(), a.midpoint()[Geom::Y]));
+ Geom::Point(doc()->getWidth().value("px"), a.midpoint()[Geom::Y]));
set_display_area(d, 10);
}