summaryrefslogtreecommitdiffstats
path: root/src/style-internal.cpp
diff options
context:
space:
mode:
authorTavmjong Bah <tavmjong@free.fr>2014-05-09 13:05:08 +0000
committertavmjong-free <tavmjong@free.fr>2014-05-09 13:05:08 +0000
commit8968a706971ba63e91ffe3704ee9a594d7a9b189 (patch)
tree84235863252d646414bb3d0b1418a1afc7933885 /src/style-internal.cpp
parentLatvian translation update (diff)
downloadinkscape-8968a706971ba63e91ffe3704ee9a594d7a9b189.tar.gz
inkscape-8968a706971ba63e91ffe3704ee9a594d7a9b189.zip
Style rewrite: correct 'text-decoration' CSS2 vs CSS3 behavior.
(bzr r13344)
Diffstat (limited to 'src/style-internal.cpp')
-rw-r--r--src/style-internal.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/style-internal.cpp b/src/style-internal.cpp
index c74683a7a..bfe708e7a 100644
--- a/src/style-internal.cpp
+++ b/src/style-internal.cpp
@@ -2425,11 +2425,21 @@ SPITextDecoration::read( gchar const *str ) {
free(frag);
if( style->text_decoration_color.set ) break;
style->text_decoration_color.read( "currentColor" ); // Default value
+ style->text_decoration_color.set = false;
if( *str == '\0' )break;
hstr = str + 1;
}
str++;
}
+
+ // If we read a style or color then we have CSS3 which require any non-set values to be
+ // set to their default values.
+ if( style->text_decoration_style.set == true ||
+ style->text_decoration_style.set == true ) {
+ style->text_decoration_line.set = true;
+ style->text_decoration_style.set = true;
+ style->text_decoration_color.set = true;
+ }
}
// Returns CSS2 'text-decoration' (using settings in SPTextDecorationLine)