summaryrefslogtreecommitdiffstats
path: root/src/sp-clippath.cpp
diff options
context:
space:
mode:
authorAndrius Ramanauskas <knutux@gmail.com>2006-03-22 06:22:39 +0000
committerknutux <knutux@users.sourceforge.net>2006-03-22 06:22:39 +0000
commitf8d3775aab7d8bebe9b39edca936673c29176570 (patch)
tree4cd772f51d0ec73ed040877c6ab10fe79d4ee204 /src/sp-clippath.cpp
parenta more informative warning (diff)
downloadinkscape-f8d3775aab7d8bebe9b39edca936673c29176570.tar.gz
inkscape-f8d3775aab7d8bebe9b39edca936673c29176570.zip
Mask/Clippath transformations on masking/unmasking
(bzr r269)
Diffstat (limited to 'src/sp-clippath.cpp')
-rw-r--r--src/sp-clippath.cpp10
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);