summaryrefslogtreecommitdiffstats
path: root/src/document.cpp
diff options
context:
space:
mode:
authorMartin Owens <doctormo@gmail.com>2013-07-10 00:46:51 +0000
committerMartin Owens <doctormo@gmail.com>2013-07-10 00:46:51 +0000
commit4d232a223d1dcb7b2381615de1a64b20b2fb6165 (patch)
tree698134d73546364e488f3e6cd42fa22eb924e21e /src/document.cpp
parentFix for Bug #1185132 (colorspace.h not included in the tarball when doing a m... (diff)
downloadinkscape-4d232a223d1dcb7b2381615de1a64b20b2fb6165.tar.gz
inkscape-4d232a223d1dcb7b2381615de1a64b20b2fb6165.zip
Small refactor of align and distribute to reduce complexity.
(bzr r12411)
Diffstat (limited to 'src/document.cpp')
-rw-r--r--src/document.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/document.cpp b/src/document.cpp
index 706710cfc..0e9c43fe4 100644
--- a/src/document.cpp
+++ b/src/document.cpp
@@ -611,6 +611,11 @@ Geom::Point SPDocument::getDimensions() const
return Geom::Point(getWidth(), getHeight());
}
+Geom::OptRect SPDocument::preferredBounds() const
+{
+ return Geom::OptRect( Geom::Point(0, 0), getDimensions() );
+}
+
/**
* Given a Geom::Rect that may, for example, correspond to the bbox of an object,
* this function fits the canvas to that rect by resizing the canvas