summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Drake <tlsa@netsurf-browser.org>2014-12-31 13:29:57 (GMT)
committer Michael Drake <tlsa@netsurf-browser.org>2014-12-31 13:29:57 (GMT)
commit5c5e38224c349ef810b8d5acebf194d06e431970 (patch)
treef64e0c6dbae4a8c55690e9cc138bcf6e4f837f46
parentd64a9192f0b59a725abcfe3e6fb30467d4ce06fd (diff)
downloadlibcss-5c5e38224c349ef810b8d5acebf194d06e431970.tar.gz
libcss-5c5e38224c349ef810b8d5acebf194d06e431970.tar.bz2
Fix.
-rw-r--r--src/select/propget.h72
1 files changed, 38 insertions, 34 deletions
diff --git a/src/select/propget.h b/src/select/propget.h
index 45c773f..2a263aa 100644
--- a/src/select/propget.h
+++ b/src/select/propget.h
@@ -36,8 +36,8 @@ static inline uint8_t get_letter_spacing(
return (bits & 3);
}
- /* Inherited */
- return CSS_LETTER_SPACING_INHERIT;
+ /* Initial value */
+ return CSS_LETTER_SPACING_NORMAL;
}
#undef LETTER_SPACING_MASK
#undef LETTER_SPACING_SHIFT
@@ -63,7 +63,7 @@ static inline uint8_t get_outline_color(
return (bits & 3);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_OUTLINE_COLOR_INVERT;
}
#undef OUTLINE_COLOR_MASK
@@ -92,7 +92,7 @@ static inline uint8_t get_outline_width(
return (bits & 7);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_OUTLINE_WIDTH_MEDIUM;
}
#undef OUTLINE_WIDTH_MASK
@@ -134,8 +134,10 @@ static inline uint8_t get_border_spacing(
return bits;
}
- /* Inherited */
- return CSS_BORDER_SPACING_INHERIT;
+ /* Initial value */
+ *hlength = *vlength = 0;
+ *hunit = *vunit = CSS_UNIT_PX;
+ return CSS_BORDER_SPACING_SET;
}
#undef BORDER_SPACING_MASK1
#undef BORDER_SPACING_SHIFT1
@@ -159,7 +161,7 @@ static inline uint8_t get_break_after(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_BREAK_AFTER_AUTO;
}
#undef BREAK_AFTER_MASK
@@ -181,7 +183,7 @@ static inline uint8_t get_break_before(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_BREAK_BEFORE_AUTO;
}
#undef BREAK_BEFORE_MASK
@@ -203,7 +205,7 @@ static inline uint8_t get_break_inside(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_BREAK_INSIDE_AUTO;
}
#undef BREAK_INSIDE_MASK
@@ -232,8 +234,8 @@ static inline uint8_t get_word_spacing(
return (bits & 3);
}
- /* Inherited */
- return CSS_WORD_SPACING_INHERIT;
+ /* Initial value */
+ return CSS_WORD_SPACING_NORMAL;
}
#undef WORD_SPACING_MASK
#undef WORD_SPACING_SHIFT
@@ -254,8 +256,8 @@ static inline uint8_t get_writing_mode(
return bits;
}
- /* Inherited */
- return CSS_WRITING_MODE_INHERIT;
+ /* Initial value */
+ return CSS_WRITING_MODE_HORIZONTAL_TB;
}
#undef WRITING_MODE_INDEX
#undef WRITING_MODE_MASK
@@ -279,7 +281,7 @@ static inline uint8_t get_counter_increment(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COUNTER_INCREMENT_NONE;
}
#undef COUNTER_INCREMENT_MASK
@@ -304,7 +306,7 @@ static inline uint8_t get_counter_reset(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COUNTER_RESET_NONE;
}
#undef COUNTER_RESET_MASK
@@ -329,8 +331,8 @@ static inline uint8_t get_cursor(
return bits;
}
- /* Inherited */
- return CSS_CURSOR_INHERIT;
+ /* Initial value */
+ return CSS_CURSOR_AUTO;
}
#undef CURSOR_MASK
#undef CURSOR_SHIFT
@@ -399,7 +401,7 @@ static inline uint8_t get_clip(
return (bits & 0x3);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_CLIP_AUTO;
}
#undef CLIP_MASK2
@@ -429,7 +431,7 @@ static inline uint8_t get_column_count(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_COUNT_AUTO;
}
#undef COLUMN_COUNT_MASK
@@ -451,7 +453,7 @@ static inline uint8_t get_column_fill(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_FILL_BALANCE;
}
#undef COLUMN_FILL_MASK
@@ -479,7 +481,7 @@ static inline uint8_t get_column_gap(
return (bits & 0x3);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_GAP_NORMAL;
}
#undef COLUMN_GAP_MASK
@@ -504,7 +506,7 @@ static inline uint8_t get_column_rule_color(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
*color = 0;
return CSS_COLUMN_RULE_COLOR_CURRENT_COLOR;
}
@@ -527,7 +529,7 @@ static inline uint8_t get_column_rule_style(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_RULE_STYLE_NONE;
}
#undef COLUMN_RULE_STYLE_MASK
@@ -555,7 +557,7 @@ static inline uint8_t get_column_rule_width(
return (bits & 0x7);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_RULE_WIDTH_MEDIUM;
}
#undef COLUMN_RULE_WIDTH_MASK
@@ -577,7 +579,7 @@ static inline uint8_t get_column_span(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_SPAN_NONE;
}
#undef COLUMN_SPAN_MASK
@@ -605,7 +607,7 @@ static inline uint8_t get_column_width(
return (bits & 0x3);
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_COLUMN_WIDTH_AUTO;
}
#undef COLUMN_WIDTH_MASK
@@ -630,7 +632,7 @@ static inline uint8_t get_content(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_CONTENT_NORMAL;
}
#undef CONTENT_MASK
@@ -2067,7 +2069,7 @@ static inline uint8_t get_page_break_after(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_PAGE_BREAK_AFTER_AUTO;
}
#undef PAGE_BREAK_AFTER_MASK
@@ -2089,7 +2091,7 @@ static inline uint8_t get_page_break_before(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_PAGE_BREAK_BEFORE_AUTO;
}
#undef PAGE_BREAK_BEFORE_MASK
@@ -2111,7 +2113,7 @@ static inline uint8_t get_page_break_inside(
return bits;
}
- /* Not inherited; initial value */
+ /* Initial value */
return CSS_PAGE_BREAK_INSIDE_AUTO;
}
#undef PAGE_BREAK_INSIDE_MASK
@@ -2136,8 +2138,9 @@ static inline uint8_t get_orphans(
return bits;
}
- /* Inherited */
- return CSS_ORPHANS_INHERIT;
+ /* Initial value */
+ *orphans = 2;
+ return CSS_ORPHANS_SET;
}
#undef ORPHANS_MASK
#undef ORPHANS_SHIFT
@@ -2161,8 +2164,9 @@ static inline uint8_t get_widows(
return bits;
}
- /* Inherited */
- return CSS_WIDOWS_INHERIT;
+ /* Initial value */
+ *widows = 2;
+ return CSS_WIDOWS_SET;
}
#undef WIDOWS_MASK
#undef WIDOWS_SHIFT