[PATCH 2/2] Add support for the CSS list-style-type property

Fabienne Ducroquet <[email protected]> Tue, 2 Apr 2013 20:51:56 +0200
Newsgroups gmane.comp.web.links
Message-ID <[email protected]>
Use the same functions as for the list-style property since only the "type" part
of the list-style property is supported at this stage.

Signed-off-by: Fabienne Ducroquet <[email protected]>
---
 src/document/css/apply.c    |    1 +
 src/document/css/property.c |    1 +
 src/document/css/property.h |    1 +
 src/document/dom/util.c     |    1 +
 4 files changed, 4 insertions(+)

diff --git a/src/document/css/apply.c b/src/document/css/apply.c
index 8c3bd85..f94b481 100644
--- a/src/document/css/apply.c
+++ b/src/document/css/apply.c
@@ -149,6 +149,7 @@ static const css_applier_T css_appliers[CSS_PT_LAST] = {
 	/* CSS_PT_FONT_STYLE */		css_apply_font_attribute,
 	/* CSS_PT_FONT_WEIGHT */	css_apply_font_attribute,
 	/* CSS_PT_LIST_STYLE */		css_apply_list_style,
+	/* CSS_PT_LIST_STYLE_TYPE */	css_apply_list_style,
 	/* CSS_PT_TEXT_ALIGN */		css_apply_text_align,
 	/* CSS_PT_TEXT_DECORATION */	css_apply_font_attribute,
 	/* CSS_PT_WHITE_SPACE */	css_apply_font_attribute,
diff --git a/src/document/css/property.c b/src/document/css/property.c
index 3914fd1..570aeea 100644
--- a/src/document/css/property.c
+++ b/src/document/css/property.c
@@ -23,6 +23,7 @@ struct css_property_info css_property_info[CSS_PT_LAST] = {
 	{ "font-style",		CSS_PT_FONT_STYLE,	 CSS_VT_FONT_ATTRIBUTE,	css_parse_font_style_value },
 	{ "font-weight",	CSS_PT_FONT_WEIGHT,	 CSS_VT_FONT_ATTRIBUTE,	css_parse_font_weight_value },
 	{ "list-style",		CSS_PT_LIST_STYLE,	 CSS_VT_LIST_STYLE,	css_parse_list_style_value },
+	{ "list-style-type",	CSS_PT_LIST_STYLE_TYPE,	 CSS_VT_LIST_STYLE,	css_parse_list_style_value },
 	{ "text-align",		CSS_PT_TEXT_ALIGN,	 CSS_VT_TEXT_ALIGN,	css_parse_text_align_value },
 	{ "text-decoration",	CSS_PT_TEXT_DECORATION,	 CSS_VT_FONT_ATTRIBUTE,	css_parse_text_decoration_value },
 	{ "white-space",	CSS_PT_WHITE_SPACE,	 CSS_VT_FONT_ATTRIBUTE,	css_parse_white_space_value },
diff --git a/src/document/css/property.h b/src/document/css/property.h
index 3d96e66..9176624 100644
--- a/src/document/css/property.h
+++ b/src/document/css/property.h
@@ -25,6 +25,7 @@ struct css_property {
 		CSS_PT_FONT_STYLE,
 		CSS_PT_FONT_WEIGHT,
 		CSS_PT_LIST_STYLE,
+		CSS_PT_LIST_STYLE_TYPE,
 		CSS_PT_TEXT_ALIGN,
 		CSS_PT_TEXT_DECORATION,
 		CSS_PT_WHITE_SPACE,
diff --git a/src/document/dom/util.c b/src/document/dom/util.c
index fe03df7..a083a8b 100644
--- a/src/document/dom/util.c
+++ b/src/document/dom/util.c
@@ -63,6 +63,7 @@ init_template_by_style(struct screen_char *template, struct document_options *op
 			case CSS_PT_DISPLAY:
 			case CSS_PT_NONE:
 			case CSS_PT_LIST_STYLE:
+			case CSS_PT_LIST_STYLE_TYPE:
 			case CSS_PT_TEXT_ALIGN:
 			case CSS_PT_WHITE_SPACE:
 			case CSS_PT_LAST:
-- 
1.7.10.4