diff --git a/src/splivarot.cpp b/src/splivarot.cpp
index e5154c130b3bd504988d7a12de0f054ace327639..ecafd2f04e9eeee17d22d58608f8943bf2d77e9d 100644 (file)
--- a/src/splivarot.cpp
+++ b/src/splivarot.cpp
@@ -474,7 +474,11 @@ sp_selected_path_boolop(bool_op bop, const unsigned int verb, const Glib::ustrin
// premultiply by the inverse of parent's repr
SPItem *parent_item = SP_ITEM(sp_desktop_document(desktop)->getObjectByRepr(parent));
NR::Matrix local = sp_item_i2doc_affine(parent_item);
- gchar *transform = sp_svg_transform_write(local);
+ gchar affinestr[80];
+ gchar *transform = NULL;
+ if (!local.test_identity() && sp_svg_transform_write(affinestr, 79, local.inverse())) {
+ transform = affinestr;
+ }
// now that we have the result, add it on the canvas
if ( bop == bool_op_cut || bop == bool_op_slice ) {
@@ -571,8 +575,6 @@ sp_selected_path_boolop(bool_op bop, const unsigned int verb, const Glib::ustrin
Inkscape::GC::release(repr);
}
- g_free(transform);
-
sp_document_done(sp_desktop_document(desktop), verb, description);
delete res;
continue;
if (simplifyIndividualPaths) {
- NR::Rect itemBbox = item->invokeBbox(sp_item_i2d_affine(item));
+ NR::Rect itemBbox = item->getBounds(sp_item_i2d_affine(item));
simplifySize = L2(itemBbox.dimensions());
}
bpath=SP_CURVE_BPATH(curve);
}
- Path *dest = bpath_to_Path(bpath);
-
- if ( doTransformation ) {
- if ( bpath ) g_free(bpath);
- } else {
- sp_curve_unref(curve);
- }
- return dest;
-}
-
-Path *bpath_to_Path(NArtBpath const *bpath) {
Path *dest = new Path;
dest->SetBackData(false);
{
if (closed)
dest->Close();
}
+
+ if ( doTransformation ) {
+ if ( bpath ) g_free(bpath);
+ } else {
+ sp_curve_unref(curve);
+ }
return dest;
}