summaryrefslogtreecommitdiff
path: root/src/parse/properties
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2012-01-28 20:25:01 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2012-01-28 20:25:01 +0000
commit32ed7d0984f0dd872b4aaac0ac12c18471f291a0 (patch)
tree39181671076458c8f379507e0585d376ebc7363f /src/parse/properties
parent6800a4d203fa62366720cc18993a74af92c0359c (diff)
downloadlibcss-32ed7d0984f0dd872b4aaac0ac12c18471f291a0.tar.gz
libcss-32ed7d0984f0dd872b4aaac0ac12c18471f291a0.tar.bz2
Add support for parsing CSS3 Multi-column layout properties:
+ break-after + break-before + break-inside + column-count + column-fill + column-gap + column-rule-color + column-rule-style + column_rule-width + column_span + column_width TODO: Shorthand properties (columns, column-rule) TODO: Selection svn path=/trunk/libcss/; revision=13412
Diffstat (limited to 'src/parse/properties')
-rw-r--r--src/parse/properties/properties.c11
-rw-r--r--src/parse/properties/properties.gen24
-rw-r--r--src/parse/properties/properties.h33
3 files changed, 68 insertions, 0 deletions
diff --git a/src/parse/properties/properties.c b/src/parse/properties/properties.c
index bc2f225..9918366 100644
--- a/src/parse/properties/properties.c
+++ b/src/parse/properties/properties.c
@@ -42,10 +42,21 @@ const css_prop_handler property_handlers[LAST_PROP + 1 - FIRST_PROP] =
css__parse_border_top_width,
css__parse_border_width,
css__parse_bottom,
+ css__parse_break_after,
+ css__parse_break_before,
+ css__parse_break_inside,
css__parse_caption_side,
css__parse_clear,
css__parse_clip,
css__parse_color,
+ css__parse_column_count,
+ css__parse_column_fill,
+ css__parse_column_gap,
+ css__parse_column_rule_color,
+ css__parse_column_rule_style,
+ css__parse_column_rule_width,
+ css__parse_column_span,
+ css__parse_column_width,
css__parse_content,
css__parse_counter_increment,
css__parse_counter_reset,
diff --git a/src/parse/properties/properties.gen b/src/parse/properties/properties.gen
index 016d7a0..5a4ebe0 100644
--- a/src/parse/properties/properties.gen
+++ b/src/parse/properties/properties.gen
@@ -188,3 +188,27 @@ width:CSS_PROP_WIDTH IDENT:( INHERIT: AUTO:0,WIDTH_AUTO IDENT:) LENGTH_UNIT:( UN
word_spacing:CSS_PROP_WORD_SPACING IDENT:( INHERIT: NORMAL:0,WORD_SPACING_NORMAL IDENT:) LENGTH_UNIT:( UNIT_PX:WORD_SPACING_SET DISALLOW:unit&UNIT_ANGLE||unit&UNIT_TIME||unit&UNIT_FREQ||unit&UNIT_PCT LENGTH_UNIT:)
z_index:CSS_PROP_Z_INDEX IDENT:( INHERIT: AUTO:0,Z_INDEX_AUTO IDENT:) NUMBER:( true:Z_INDEX_SET NUMBER:)
+
+
+break_after:CSS_PROP_BREAK_AFTER IDENT:( INHERIT: AUTO:0,BREAK_AFTER_AUTO ALWAYS:0,BREAK_AFTER_ALWAYS AVOID:0,BREAK_AFTER_AVOID LEFT:0,BREAK_AFTER_LEFT RIGHT:0,BREAK_AFTER_RIGHT PAGE:0,BREAK_AFTER_PAGE COLUMN:0,BREAK_AFTER_COLUMN AVOID_PAGE:0,BREAK_AFTER_AVOID_PAGE AVOID_COLUMN:0,BREAK_AFTER_AVOID_COLUMN IDENT:)
+
+break_before:CSS_PROP_BREAK_BEFORE IDENT:( INHERIT: AUTO:0,BREAK_BEFORE_AUTO ALWAYS:0,BREAK_BEFORE_ALWAYS AVOID:0,BREAK_BEFORE_AVOID LEFT:0,BREAK_BEFORE_LEFT RIGHT:0,BREAK_BEFORE_RIGHT PAGE:0,BREAK_BEFORE_PAGE COLUMN:0,BREAK_BEFORE_COLUMN AVOID_PAGE:0,BREAK_BEFORE_AVOID_PAGE AVOID_COLUMN:0,BREAK_BEFORE_AVOID_COLUMN IDENT:)
+
+break_inside:CSS_PROP_BREAK_INSIDE IDENT:( INHERIT: AUTO:0,BREAK_INSIDE_AUTO AVOID:0,BREAK_INSIDE_AVOID AVOID_PAGE:0,BREAK_INSIDE_AVOID_PAGE AVOID_COLUMN:0,BREAK_INSIDE_AVOID_COLUMN IDENT:)
+
+column_count:CSS_PROP_COLUMN_COUNT IDENT:( INHERIT: AUTO:0,COLUMN_COUNT_AUTO IDENT:) NUMBER:( true:COLUMN_COUNT_SET RANGE:num<0 NUMBER:)
+
+column_fill:CSS_PROP_COLUMN_FILL IDENT:( INHERIT: BALANCE:0,COLUMN_FILL_BALANCE AUTO:0,COLUMN_FILL_AUTO IDENT:)
+
+column_gap:CSS_PROP_COLUMN_GAP IDENT:( INHERIT: NORMAL:0,COLUMN_GAP_NORMAL IDENT:) LENGTH_UNIT:( UNIT_PX:COLUMN_GAP_SET RANGE:<0 DISALLOW:unit&UNIT_ANGLE||unit&UNIT_TIME||unit&UNIT_FREQ||unit&UNIT_PCT LENGTH_UNIT:)
+
+column_rule_color:CSS_PROP_COLUMN_RULE_COLOR IDENT:( INHERIT: IDENT:) COLOR:COLUMN_RULE_COLOR_SET
+
+column_rule_style:CSS_PROP_COLUMN_RULE_STYLE IDENT:( INHERIT: NONE:0,BORDER_STYLE_NONE HIDDEN:0,BORDER_STYLE_HIDDEN DOTTED:0,BORDER_STYLE_DOTTED DASHED:0,BORDER_STYLE_DASHED SOLID:0,BORDER_STYLE_SOLID LIBCSS_DOUBLE:0,BORDER_STYLE_DOUBLE GROOVE:0,BORDER_STYLE_GROOVE RIDGE:0,BORDER_STYLE_RIDGE INSET:0,BORDER_STYLE_INSET OUTSET:0,BORDER_STYLE_OUTSET IDENT:)
+
+column_rule_width:CSS_PROP_COLUMN_RULE_WIDTH WRAP:css__parse_border_side_width
+
+column_span:CSS_PROP_COLUMN_SPAN IDENT:( INHERIT: NONE:0,COLUMN_SPAN_NONE ALL:0,COLUMN_SPAN_ALL IDENT:)
+
+column_width:CSS_PROP_COLUMN_WIDTH IDENT:( INHERIT: AUTO:0,COLUMN_WIDTH_AUTO IDENT:) LENGTH_UNIT:( UNIT_PX:COLUMN_WIDTH_SET DISALLOW:unit&UNIT_ANGLE||unit&UNIT_TIME||unit&UNIT_FREQ||unit&UNIT_PCT LENGTH_UNIT:)
+
diff --git a/src/parse/properties/properties.h b/src/parse/properties/properties.h
index 6992f18..b3d2eb4 100644
--- a/src/parse/properties/properties.h
+++ b/src/parse/properties/properties.h
@@ -112,6 +112,15 @@ css_error css__parse_border_width(css_language *c,
css_error css__parse_bottom(css_language *c,
const parserutils_vector *vector, int *ctx,
css_style *result);
+css_error css__parse_break_after(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_break_before(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_break_inside(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
css_error css__parse_caption_side(css_language *c,
const parserutils_vector *vector, int *ctx,
css_style *result);
@@ -124,6 +133,30 @@ css_error css__parse_clip(css_language *c,
css_error css__parse_color(css_language *c,
const parserutils_vector *vector, int *ctx,
css_style *result);
+css_error css__parse_column_count(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_fill(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_gap(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_rule_color(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_rule_style(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_rule_width(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_span(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
+css_error css__parse_column_width(css_language *c,
+ const parserutils_vector *vector, int *ctx,
+ css_style *result);
css_error css__parse_content(css_language *c,
const parserutils_vector *vector, int *ctx,
css_style *result);