From 94b74cf00f2d605cb8268d9fe05d0bad78077f1c Mon Sep 17 00:00:00 2001 From: Alvin Penner Date: Thu, 10 Jul 2014 15:13:09 -0400 Subject: refresh SPCurve in a cloned clip (Bug 1322940) Fixed bugs: - https://launchpad.net/bugs/1322940 (bzr r13448) --- src/sp-use.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'src/sp-use.cpp') diff --git a/src/sp-use.cpp b/src/sp-use.cpp index e8fe3687f..7d908a66a 100644 --- a/src/sp-use.cpp +++ b/src/sp-use.cpp @@ -37,6 +37,7 @@ #include "sp-symbol.h" #include "sp-use.h" #include "sp-use-reference.h" +#include "sp-shape.h" namespace { SPObject* createUse() { @@ -176,6 +177,8 @@ Inkscape::XML::Node* SPUse::write(Inkscape::XML::Document *xml_doc, Inkscape::XM g_free(uri_string); } + if (SP_IS_SHAPE(this->child)) + SP_SHAPE(this->child)->set_shape(); // evaluate SPCurve of child return repr; } -- cgit v1.2.3 From 962b4e5a31b1128cdb9dfcccac87e7449a3351f1 Mon Sep 17 00:00:00 2001 From: Alvin Penner Date: Fri, 25 Jul 2014 17:23:13 -0400 Subject: refresh text objects when clipping (Bug 1339305) Fixed bugs: - https://launchpad.net/bugs/1339305 (bzr r13470) --- src/sp-use.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) (limited to 'src/sp-use.cpp') diff --git a/src/sp-use.cpp b/src/sp-use.cpp index 7d908a66a..e3fcd252a 100644 --- a/src/sp-use.cpp +++ b/src/sp-use.cpp @@ -38,6 +38,8 @@ #include "sp-use.h" #include "sp-use-reference.h" #include "sp-shape.h" +#include "sp-text.h" +#include "sp-flowtext.h" namespace { SPObject* createUse() { @@ -177,8 +179,16 @@ Inkscape::XML::Node* SPUse::write(Inkscape::XML::Document *xml_doc, Inkscape::XM g_free(uri_string); } - if (SP_IS_SHAPE(this->child)) + if (SP_IS_SHAPE(this->child)) { SP_SHAPE(this->child)->set_shape(); // evaluate SPCurve of child + } else if (SP_IS_TEXT(this->child)) { + SP_TEXT(this->child)->rebuildLayout(); // refresh Layout, LP Bug 1339305 + } else if (SP_IS_FLOWTEXT(this->child)) { + if (SP_IS_FLOWREGION(SP_FLOWTEXT(this->child)->firstChild())) + SP_FLOWREGION(SP_FLOWTEXT(this->child)->firstChild())->UpdateComputed(); + SP_FLOWTEXT(this->child)->rebuildLayout(); + } + return repr; } -- cgit v1.2.3