summaryrefslogtreecommitdiff
path: root/lib/skin_parser/skin_parser.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/skin_parser/skin_parser.c')
-rw-r--r--lib/skin_parser/skin_parser.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/lib/skin_parser/skin_parser.c b/lib/skin_parser/skin_parser.c
index 689a315bfa..5a5d746c8e 100644
--- a/lib/skin_parser/skin_parser.c
+++ b/lib/skin_parser/skin_parser.c
@@ -261,7 +261,7 @@ static struct skin_element* skin_parse_line(const char**document)
261 261
262/* 262/*
263 * If conditional is set to true, then this will break upon encountering 263 * If conditional is set to true, then this will break upon encountering
264 * SEPERATESYM. This should only be used when parsing a line inside a 264 * SEPARATESYM. This should only be used when parsing a line inside a
265 * conditional, otherwise just use the wrapper function skin_parse_line() 265 * conditional, otherwise just use the wrapper function skin_parse_line()
266 */ 266 */
267static struct skin_element* skin_parse_line_optional(const char** document, 267static struct skin_element* skin_parse_line_optional(const char** document,
@@ -280,9 +280,9 @@ static struct skin_element* skin_parse_line_optional(const char** document,
280 retval->type = LINE; 280 retval->type = LINE;
281 retval->line = skin_line; 281 retval->line = skin_line;
282 if(*cursor != '\0' && *cursor != '\n' && *cursor != MULTILINESYM 282 if(*cursor != '\0' && *cursor != '\n' && *cursor != MULTILINESYM
283 && !(conditional && (*cursor == ARGLISTSEPERATESYM 283 && !(conditional && (*cursor == ARGLISTSEPARATESYM
284 || *cursor == ARGLISTCLOSESYM 284 || *cursor == ARGLISTCLOSESYM
285 || *cursor == ENUMLISTSEPERATESYM 285 || *cursor == ENUMLISTSEPARATESYM
286 || *cursor == ENUMLISTCLOSESYM))) 286 || *cursor == ENUMLISTCLOSESYM)))
287 { 287 {
288 retval->children_count = 1; 288 retval->children_count = 1;
@@ -313,9 +313,9 @@ static struct skin_element* skin_parse_line_optional(const char** document,
313#endif 313#endif
314 314
315 while(*cursor != '\n' && *cursor != '\0' && *cursor != MULTILINESYM 315 while(*cursor != '\n' && *cursor != '\0' && *cursor != MULTILINESYM
316 && !((*cursor == ARGLISTSEPERATESYM 316 && !((*cursor == ARGLISTSEPARATESYM
317 || *cursor == ARGLISTCLOSESYM 317 || *cursor == ARGLISTCLOSESYM
318 || *cursor == ENUMLISTSEPERATESYM 318 || *cursor == ENUMLISTSEPARATESYM
319 || *cursor == ENUMLISTCLOSESYM) 319 || *cursor == ENUMLISTCLOSESYM)
320 && conditional) 320 && conditional)
321 && !(check_viewport(cursor) && cursor != *document)) 321 && !(check_viewport(cursor) && cursor != *document))
@@ -390,9 +390,9 @@ static struct skin_element* skin_parse_sublines_optional(const char** document,
390 390
391 /* First we count the sublines */ 391 /* First we count the sublines */
392 while(*cursor != '\0' && *cursor != '\n' 392 while(*cursor != '\0' && *cursor != '\n'
393 && !((*cursor == ARGLISTSEPERATESYM 393 && !((*cursor == ARGLISTSEPARATESYM
394 || *cursor == ARGLISTCLOSESYM 394 || *cursor == ARGLISTCLOSESYM
395 || *cursor == ENUMLISTSEPERATESYM 395 || *cursor == ENUMLISTSEPARATESYM
396 || *cursor == ENUMLISTCLOSESYM) 396 || *cursor == ENUMLISTCLOSESYM)
397 && conditional) 397 && conditional)
398 && !(check_viewport(cursor) && cursor != *document)) 398 && !(check_viewport(cursor) && cursor != *document))
@@ -565,7 +565,7 @@ static int skin_parse_tag(struct skin_element* element, const char** document)
565 { 565 {
566 skip_arglist(&cursor); 566 skip_arglist(&cursor);
567 } 567 }
568 else if(*cursor == ARGLISTSEPERATESYM) 568 else if(*cursor == ARGLISTSEPARATESYM)
569 { 569 {
570 num_args++; 570 num_args++;
571 cursor++; 571 cursor++;
@@ -753,9 +753,9 @@ static int skin_parse_tag(struct skin_element* element, const char** document)
753 753
754 skip_whitespace(&cursor); 754 skip_whitespace(&cursor);
755 755
756 if(*cursor != ARGLISTSEPERATESYM && i < num_args - 1) 756 if(*cursor != ARGLISTSEPARATESYM && i < num_args - 1)
757 { 757 {
758 skin_error(SEPERATOR_EXPECTED, cursor); 758 skin_error(SEPARATOR_EXPECTED, cursor);
759 return 0; 759 return 0;
760 } 760 }
761 else if(*cursor != ARGLISTCLOSESYM && i == num_args - 1) 761 else if(*cursor != ARGLISTCLOSESYM && i == num_args - 1)
@@ -801,7 +801,7 @@ static int skin_parse_tag(struct skin_element* element, const char** document)
801 801
802/* 802/*
803 * If the conditional flag is set true, then parsing text will stop at an 803 * If the conditional flag is set true, then parsing text will stop at an
804 * ARGLISTSEPERATESYM. Only set that flag when parsing within a conditional 804 * ARGLISTSEPARATESYM. Only set that flag when parsing within a conditional
805 */ 805 */
806static int skin_parse_text(struct skin_element* element, const char** document, 806static int skin_parse_text(struct skin_element* element, const char** document,
807 int conditional) 807 int conditional)
@@ -814,9 +814,9 @@ static int skin_parse_text(struct skin_element* element, const char** document,
814 /* First figure out how much text we're copying */ 814 /* First figure out how much text we're copying */
815 while(*cursor != '\0' && *cursor != '\n' && *cursor != MULTILINESYM 815 while(*cursor != '\0' && *cursor != '\n' && *cursor != MULTILINESYM
816 && *cursor != COMMENTSYM 816 && *cursor != COMMENTSYM
817 && !((*cursor == ARGLISTSEPERATESYM 817 && !((*cursor == ARGLISTSEPARATESYM
818 || *cursor == ARGLISTCLOSESYM 818 || *cursor == ARGLISTCLOSESYM
819 || *cursor == ENUMLISTSEPERATESYM 819 || *cursor == ENUMLISTSEPARATESYM
820 || *cursor == ENUMLISTCLOSESYM) 820 || *cursor == ENUMLISTCLOSESYM)
821 && conditional)) 821 && conditional))
822 { 822 {
@@ -932,7 +932,7 @@ static int skin_parse_conditional(struct skin_element* element, const char** doc
932 break; 932 break;
933 cursor++; 933 cursor++;
934 } 934 }
935 else if(*cursor == ENUMLISTSEPERATESYM) 935 else if(*cursor == ENUMLISTSEPARATESYM)
936 { 936 {
937 children++; 937 children++;
938 cursor++; 938 cursor++;
@@ -984,9 +984,9 @@ static int skin_parse_conditional(struct skin_element* element, const char** doc
984 cursor = conditional_end; 984 cursor = conditional_end;
985#endif 985#endif
986 986
987 if(i < children - 1 && *cursor != ENUMLISTSEPERATESYM) 987 if(i < children - 1 && *cursor != ENUMLISTSEPARATESYM)
988 { 988 {
989 skin_error(SEPERATOR_EXPECTED, cursor); 989 skin_error(SEPARATOR_EXPECTED, cursor);
990 return 0; 990 return 0;
991 } 991 }
992 else if(i == children - 1 && *cursor != ENUMLISTCLOSESYM) 992 else if(i == children - 1 && *cursor != ENUMLISTCLOSESYM)
@@ -1048,7 +1048,7 @@ static struct skin_element* skin_parse_code_as_arg(const char** document)
1048 1048
1049 /* Checking for sublines */ 1049 /* Checking for sublines */
1050 while(*cursor != '\n' && *cursor != '\0' 1050 while(*cursor != '\n' && *cursor != '\0'
1051 && *cursor != ENUMLISTSEPERATESYM && *cursor != ARGLISTSEPERATESYM 1051 && *cursor != ENUMLISTSEPARATESYM && *cursor != ARGLISTSEPARATESYM
1052 && *cursor != ENUMLISTCLOSESYM && *cursor != ARGLISTCLOSESYM) 1052 && *cursor != ENUMLISTCLOSESYM && *cursor != ARGLISTCLOSESYM)
1053 { 1053 {
1054 if(*cursor == MULTILINESYM) 1054 if(*cursor == MULTILINESYM)