diff options
Diffstat (limited to 'src/sp-clippath.cpp')
| -rw-r--r-- | src/sp-clippath.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/sp-clippath.cpp b/src/sp-clippath.cpp index 33feea8ce..35e073879 100644 --- a/src/sp-clippath.cpp +++ b/src/sp-clippath.cpp @@ -371,7 +371,7 @@ sp_clippath_view_list_remove(SPClipPathView *list, SPClipPathView *view) // Create a mask element (using passed elements), add it to <defs> const gchar * -sp_clippath_create (GSList *reprs, SPDocument *document) +sp_clippath_create (GSList *reprs, SPDocument *document, NR::Matrix const* applyTransform) { Inkscape::XML::Node *defsrepr = SP_OBJECT_REPR (SP_DOCUMENT_DEFS (document)); @@ -384,7 +384,13 @@ sp_clippath_create (GSList *reprs, SPDocument *document) for (GSList *it = reprs; it != NULL; it = it->next) { Inkscape::XML::Node *node = (Inkscape::XML::Node *)(it->data); - clip_path_object->appendChildRepr(node); + SPItem *item = SP_ITEM(clip_path_object->appendChildRepr(node)); + + if (NULL != applyTransform) { + NR::Matrix transform (item->transform); + transform *= (*applyTransform); + sp_item_write_transform(item, SP_OBJECT_REPR(item), transform); + } } Inkscape::GC::release(repr); |
