summaryrefslogtreecommitdiff
path: root/src/select/properties
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2014-11-16 11:59:13 +0000
committerMichael Drake <tlsa@netsurf-browser.org>2014-11-16 13:31:20 +0000
commit32d6b37b16f9c8a840ccc2b6d4d7ef4b706097f4 (patch)
treeb01fa6c634577140c03fcf48836d06fd878c4c92 /src/select/properties
parent9914d06fcc48c87a46d47e6a47ffb80817981258 (diff)
downloadlibcss-32d6b37b16f9c8a840ccc2b6d4d7ef4b706097f4.tar.gz
libcss-32d6b37b16f9c8a840ccc2b6d4d7ef4b706097f4.tar.bz2
Add column_rule_style to computed styles.
Diffstat (limited to 'src/select/properties')
-rw-r--r--src/select/properties/column_rule_style.c47
1 files changed, 11 insertions, 36 deletions
diff --git a/src/select/properties/column_rule_style.c b/src/select/properties/column_rule_style.c
index ba558a2..586ce5d 100644
--- a/src/select/properties/column_rule_style.c
+++ b/src/select/properties/column_rule_style.c
@@ -17,57 +17,32 @@
css_error css__cascade_column_rule_style(uint32_t opv, css_style *style,
css_select_state *state)
{
- UNUSED(style);
-
- if (isInherit(opv) == false) {
- switch (getValue(opv)) {
- case COLUMN_RULE_STYLE_NONE:
- case COLUMN_RULE_STYLE_HIDDEN:
- case COLUMN_RULE_STYLE_DOTTED:
- case COLUMN_RULE_STYLE_DASHED:
- case COLUMN_RULE_STYLE_SOLID:
- case COLUMN_RULE_STYLE_DOUBLE:
- case COLUMN_RULE_STYLE_GROOVE:
- case COLUMN_RULE_STYLE_RIDGE:
- case COLUMN_RULE_STYLE_INSET:
- case COLUMN_RULE_STYLE_OUTSET:
- /** \todo convert to public values */
- break;
- }
- }
-
- if (css__outranks_existing(getOpcode(opv), isImportant(opv), state,
- isInherit(opv))) {
- /** \todo set computed elevation */
- }
-
- return CSS_OK;
+ return css__cascade_border_style(opv, style, state,
+ set_column_rule_style);
}
css_error css__set_column_rule_style_from_hint(const css_hint *hint,
css_computed_style *style)
{
- UNUSED(hint);
- UNUSED(style);
-
- return CSS_OK;
+ return set_column_rule_style(style, hint->status);
}
css_error css__initial_column_rule_style(css_select_state *state)
{
- UNUSED(state);
-
- return CSS_OK;
+ return set_column_rule_style(state->computed,
+ CSS_COLUMN_RULE_STYLE_NONE);
}
css_error css__compose_column_rule_style(const css_computed_style *parent,
const css_computed_style *child,
css_computed_style *result)
{
- UNUSED(parent);
- UNUSED(child);
- UNUSED(result);
+ uint8_t type = get_column_rule_style(child);
+
+ if (type == CSS_COLUMN_RULE_STYLE_INHERIT) {
+ type = get_column_rule_style(parent);
+ }
- return CSS_OK;
+ return set_column_rule_style(result, type);
}