summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorTavmjong Bah <tavmjong@free.fr>2014-05-09 13:06:22 +0000
committertavmjong-free <tavmjong@free.fr>2014-05-09 13:06:22 +0000
commitd9496e287b19b63ad567b2ef95bc97f5b3100f6f (patch)
tree324109de012cd6e99120c383b89faa37363b97a2 /src
parentUpdate to tip. (diff)
downloadinkscape-d9496e287b19b63ad567b2ef95bc97f5b3100f6f.tar.gz
inkscape-d9496e287b19b63ad567b2ef95bc97f5b3100f6f.zip
Style rewrite: Correct 'text-decoration' CSS2 vs. CSS3 behavior.
(bzr r13341.1.3)
Diffstat (limited to 'src')
-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)