diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2013-08-18 21:05:56 +0000 |
|---|---|---|
| committer | Javiertxo <jtx@jtx.marker.es> | 2013-08-18 21:05:56 +0000 |
| commit | ac014eea08f219ba91c6c31240e140c0b7e67ad5 (patch) | |
| tree | 76ca4df51a837392a25c701a5c1c8810d7364b98 /src/attribute-rel-util.cpp | |
| parent | update to trunk (diff) | |
| parent | Prevent writing out empty style strings. (diff) | |
| download | inkscape-ac014eea08f219ba91c6c31240e140c0b7e67ad5.tar.gz inkscape-ac014eea08f219ba91c6c31240e140c0b7e67ad5.zip | |
update to trunk
(bzr r11950.1.128)
Diffstat (limited to 'src/attribute-rel-util.cpp')
| -rw-r--r-- | src/attribute-rel-util.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/attribute-rel-util.cpp b/src/attribute-rel-util.cpp index 933339632..15c71daa7 100644 --- a/src/attribute-rel-util.cpp +++ b/src/attribute-rel-util.cpp @@ -141,7 +141,11 @@ void sp_attribute_clean_style(Node *repr, unsigned int flags) { // sp_repr_css_set( repr, css, "style"); // Don't use as it will cause loop. Glib::ustring value; sp_repr_css_write_string(css, value); - repr->setAttribute("style", value.c_str()); + if( value.empty() ) { + repr->setAttribute("style", NULL ); + } else { + repr->setAttribute("style", value.c_str()); + } sp_repr_css_attr_unref( css ); } |
