summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: f51ffb9)
raw | patch | inline | side by side (parent: f51ffb9)
author | buliabyak <buliabyak@users.sourceforge.net> | |
Thu, 26 Jan 2006 05:26:46 +0000 (05:26 +0000) | ||
committer | buliabyak <buliabyak@users.sourceforge.net> | |
Thu, 26 Jan 2006 05:26:46 +0000 (05:26 +0000) |
src/seltrans.cpp | patch | blob | history |
diff --git a/src/seltrans.cpp b/src/seltrans.cpp
index f83c646b7bc6da5dd61614079524175cd06e62d8..1a8c69827426836d4eb0d2ed04a5c02e23ed5a80 100644 (file)
--- a/src/seltrans.cpp
+++ b/src/seltrans.cpp
@@ -1144,11 +1144,12 @@ void Inkscape::SelTrans::stretch(SPSelTransHandle const &handle, NR::Point &pt,
s[!dim] = fabs(s[dim]);
}
- NR::Rect new_bbox = _box * (NR::translate(-scale_origin) * NR::Matrix(s) * NR::translate(scale_origin));
+ NR::Point new_bbox_min = _box.min() * (NR::translate(-scale_origin) * NR::Matrix(s) * NR::translate(scale_origin));
+ NR::Point new_bbox_max = _box.max() * (NR::translate(-scale_origin) * NR::Matrix(s) * NR::translate(scale_origin));
int transform_stroke = prefs_get_int_attribute ("options.transform", "stroke", 1);
NR::Matrix scaler = get_scale_transform_with_stroke (_box, _strokewidth, transform_stroke,
- new_bbox.min()[NR::X], new_bbox.min()[NR::Y], new_bbox.max()[NR::X], new_bbox.max()[NR::Y]);
+ new_bbox_min[NR::X], new_bbox_min[NR::Y], new_bbox_max[NR::X], new_bbox_max[NR::Y]);
transform(scaler, NR::Point(0, 0)); // we have already accounted for origin, so pass 0,0
}
if (fabs(s[i]) < 1e-9)
s[i] = 1e-9;
}
- NR::Rect new_bbox = _box * (NR::translate(-_origin) * NR::Matrix(s) * NR::translate(_origin));
+ NR::Point new_bbox_min = _box.min() * (NR::translate(-_origin) * NR::Matrix(s) * NR::translate(_origin));
+ NR::Point new_bbox_max = _box.max() * (NR::translate(-_origin) * NR::Matrix(s) * NR::translate(_origin));
int transform_stroke = prefs_get_int_attribute ("options.transform", "stroke", 1);
NR::Matrix scaler = get_scale_transform_with_stroke (_box, _strokewidth, transform_stroke,
- new_bbox.min()[NR::X], new_bbox.min()[NR::Y], new_bbox.max()[NR::X], new_bbox.max()[NR::Y]);
+ new_bbox_min[NR::X], new_bbox_min[NR::Y], new_bbox_max[NR::X], new_bbox_max[NR::Y]);
transform(scaler, NR::Point(0, 0)); // we have already accounted for origin, so pass 0,0
}