diff options
| author | Alvin Penner <penner@vaxxine.com> | 2012-02-04 21:32:10 +0000 |
|---|---|---|
| committer | apenner <penner@vaxxine.com> | 2012-02-04 21:32:10 +0000 |
| commit | e7281159491626d03d4a9d95b853ea90567e274a (patch) | |
| tree | caab0f4900c913715291afdece2151082ac1e7f4 /src/seltrans.cpp | |
| parent | cppcheck tells us: scanf without field width limits can crash with huge input... (diff) | |
| download | inkscape-e7281159491626d03d4a9d95b853ea90567e274a.tar.gz inkscape-e7281159491626d03d4a9d95b853ea90567e274a.zip | |
implement some switches between visual bbox and geometric bbox, depending on prefs (Bug 906952)
Fixed bugs:
- https://launchpad.net/bugs/906952
(bzr r10935)
Diffstat (limited to 'src/seltrans.cpp')
| -rw-r--r-- | src/seltrans.cpp | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/seltrans.cpp b/src/seltrans.cpp index 922d13a72..e5a61abd0 100644 --- a/src/seltrans.cpp +++ b/src/seltrans.cpp @@ -281,8 +281,12 @@ void Inkscape::SelTrans::grab(Geom::Point const &p, gdouble x, gdouble y, bool s // First, determine the bounding box _bbox = selection->bounds(_snap_bbox_type); - _visual_bbox = selection->visualBounds(); // Used for correctly scaling the strokewidth _geometric_bbox = selection->geometricBounds(); + if (prefs->getInt("/tools/bounding_box") == 0) { + _visual_bbox = selection->visualBounds(); // Used for correctly scaling the strokewidth + } else { + _visual_bbox = _geometric_bbox; + } _point = p; if (_geometric_bbox) { @@ -653,7 +657,11 @@ void Inkscape::SelTrans::_updateVolatileState() //Update the bboxes _bbox = selection->bounds(_snap_bbox_type); - _visual_bbox = selection->visualBounds(); + if (Inkscape::Preferences::get()->getInt("/tools/bounding_box") == 0) { + _visual_bbox = selection->visualBounds(); + } else { + _visual_bbox = selection->geometricBounds(); + } if (!_bbox) { _empty = true; |
