summaryrefslogtreecommitdiff
path: root/src/parse/properties/positioning.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/parse/properties/positioning.c')
-rw-r--r--src/parse/properties/positioning.c75
1 files changed, 25 insertions, 50 deletions
diff --git a/src/parse/properties/positioning.c b/src/parse/properties/positioning.c
index 813b113..c4393aa 100644
--- a/src/parse/properties/positioning.c
+++ b/src/parse/properties/positioning.c
@@ -133,28 +133,23 @@ css_error parse_position(css_language *c,
return CSS_INVALID;
}
- if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ if ((lwc_string_caseless_isequal(
ident->idata, c->strings[INHERIT],
&match) == lwc_error_ok && match)) {
flags |= FLAG_INHERIT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[STATIC],
&match) == lwc_error_ok && match)) {
value = POSITION_STATIC;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[RELATIVE],
&match) == lwc_error_ok && match)) {
value = POSITION_RELATIVE;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[ABSOLUTE],
&match) == lwc_error_ok && match)) {
value = POSITION_ABSOLUTE;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[FIXED],
&match) == lwc_error_ok && match)) {
value = POSITION_FIXED;
@@ -211,28 +206,23 @@ css_error parse_clear(css_language *c,
return CSS_INVALID;
}
- if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ if ((lwc_string_caseless_isequal(
ident->idata, c->strings[INHERIT],
&match) == lwc_error_ok && match)) {
flags |= FLAG_INHERIT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[RIGHT],
&match) == lwc_error_ok && match)) {
value = CLEAR_RIGHT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[LEFT],
&match) == lwc_error_ok && match)) {
value = CLEAR_LEFT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[BOTH],
&match) == lwc_error_ok && match)) {
value = CLEAR_BOTH;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[NONE],
&match) == lwc_error_ok && match)) {
value = CLEAR_NONE;
@@ -289,23 +279,19 @@ css_error parse_float(css_language *c,
return CSS_INVALID;
}
- if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ if ((lwc_string_caseless_isequal(
ident->idata, c->strings[INHERIT],
&match) == lwc_error_ok && match)) {
flags |= FLAG_INHERIT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[LEFT],
&match) == lwc_error_ok && match)) {
value = FLOAT_LEFT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[RIGHT],
&match) == lwc_error_ok && match)) {
value = FLOAT_RIGHT;
- } else if ((lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ } else if ((lwc_string_caseless_isequal(
ident->idata, c->strings[NONE],
&match) == lwc_error_ok && match)) {
value = FLOAT_NONE;
@@ -368,64 +354,55 @@ css_error parse_vertical_align(css_language *c,
}
if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[INHERIT],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
flags = FLAG_INHERIT;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[BASELINE],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_BASELINE;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[SUB],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_SUB;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[SUPER],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_SUPER;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[TOP],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_TOP;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[TEXT_TOP],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_TEXT_TOP;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[MIDDLE],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_MIDDLE;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[BOTTOM],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
value = VERTICAL_ALIGN_BOTTOM;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[TEXT_BOTTOM],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
@@ -509,15 +486,13 @@ css_error parse_side(css_language *c,
}
if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[INHERIT],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);
flags = FLAG_INHERIT;
} else if (token->type == CSS_TOKEN_IDENT &&
- (lwc_context_string_caseless_isequal(
- c->sheet->dictionary,
+ (lwc_string_caseless_isequal(
token->idata, c->strings[AUTO],
&match) == lwc_error_ok && match)) {
parserutils_vector_iterate(vector, ctx);