summaryrefslogtreecommitdiffstats
path: root/src/sp-item.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/sp-item.cpp')
-rw-r--r--src/sp-item.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/sp-item.cpp b/src/sp-item.cpp
index c0c23ba8b..3069dcf73 100644
--- a/src/sp-item.cpp
+++ b/src/sp-item.cpp
@@ -791,6 +791,16 @@ Geom::OptRect SPItem::desktopVisualBounds() const
{
return visualBounds(i2dt_affine());
}
+
+Geom::OptRect SPItem::desktopPreferredBounds() const
+{
+ if (Inkscape::Preferences::get()->getInt("/tools/bounding_box") == 0) {
+ return desktopBounds(SPItem::VISUAL_BBOX);
+ } else {
+ return desktopBounds(SPItem::GEOMETRIC_BBOX);
+ }
+}
+
Geom::OptRect SPItem::desktopBounds(BBoxType type) const
{
if (type == GEOMETRIC_BBOX) {