summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: c8186ab)
raw | patch | inline | side by side (parent: c8186ab)
author | scislac <scislac@users.sourceforge.net> | |
Mon, 5 Oct 2009 20:38:16 +0000 (20:38 +0000) | ||
committer | scislac <scislac@users.sourceforge.net> | |
Mon, 5 Oct 2009 20:38:16 +0000 (20:38 +0000) |
src/sp-lpe-item.cpp | patch | blob | history |
diff --git a/src/sp-lpe-item.cpp b/src/sp-lpe-item.cpp
index e4d278e34157df42bd7f0183b89e57da96430901..49264c684c5217b30205a16e08871a8e9f102731 100644 (file)
--- a/src/sp-lpe-item.cpp
+++ b/src/sp-lpe-item.cpp
@@ -543,7 +543,11 @@ void sp_lpe_item_remove_current_path_effect(SPLPEItem *lpeitem, bool keep_paths)
new_list.remove(lperef); //current lpe ref is always our 'own' pointer from the path_effect_list
std::string r = patheffectlist_write_svg(new_list);
- SP_OBJECT_REPR(lpeitem)->setAttribute("inkscape:path-effect", r.c_str());
+ if (!r.empty()) {
+ SP_OBJECT_REPR(lpeitem)->setAttribute("inkscape:path-effect", r.c_str());
+ } else {
+ SP_OBJECT_REPR(lpeitem)->setAttribute("inkscape:path-effect", NULL);
+ }
if (!keep_paths) {
sp_lpe_item_cleanup_original_path_recursive(lpeitem);