libcss
Loading...
Searching...
No Matches
dump.h
Go to the documentation of this file.
1#ifndef test_dump_h_
2#define test_dump_h_
3
4#include <string.h>
5
6#include <libcss/types.h>
7
8#include "stylesheet.h"
9#include "bytecode/bytecode.h"
10#include "bytecode/opcodes.h"
11#include "select/font_face.h"
12
13#include "testutils.h"
14
15static void dump_sheet(css_stylesheet *sheet, char *buf, size_t *len);
16static void dump_rule_selector(css_rule_selector *s, char **buf,
17 size_t *buflen, uint32_t depth);
18static void dump_rule_charset(css_rule_charset *s, char **buf, size_t *buflen);
19static void dump_rule_import(css_rule_import *s, char **buf, size_t *buflen);
20static void dump_rule_media(css_rule_media *s, char **buf, size_t *buflen);
21static void dump_rule_page(css_rule_page *s, char **buf, size_t *buflen);
22static void dump_rule_font_face(css_rule_font_face *s,
23 char **buf, size_t *buflen);
24static void dump_selector_list(css_selector *list, char **ptr);
25static void dump_selector(css_selector *selector, char **ptr);
26static void dump_selector_detail(css_selector_detail *detail, char **ptr);
27static void dump_bytecode(css_style *style, char **ptr, uint32_t depth);
28static void dump_string(lwc_string *string, char **ptr);
29static void dump_font_face(css_font_face *font_face, char**ptr);
30
31void dump_sheet(css_stylesheet *sheet, char *buf, size_t *buflen)
32{
33 css_rule *rule;
34
35 for (rule = sheet->rule_list; rule != NULL; rule = rule->next) {
36 switch (rule->type) {
38 dump_rule_selector((css_rule_selector *) rule,
39 &buf, buflen, 1);
40 break;
42 dump_rule_charset((css_rule_charset *) rule,
43 &buf, buflen);
44 break;
45 case CSS_RULE_IMPORT:
46 dump_rule_import((css_rule_import *) rule,
47 &buf, buflen);
48 break;
49 case CSS_RULE_MEDIA:
50 dump_rule_media((css_rule_media *) rule,
51 &buf, buflen);
52 break;
53 case CSS_RULE_PAGE:
54 dump_rule_page((css_rule_page *) rule,
55 &buf, buflen);
56 break;
58 dump_rule_font_face((css_rule_font_face *) rule,
59 &buf, buflen);
60 break;
61 default:
62 {
63 int written = sprintf(buf, "Unhandled rule type %d\n",
64 rule->type);
65
66 *buflen -= written;
67 buf += written;
68 }
69 break;
70 }
71 }
72}
73
74void dump_rule_selector(css_rule_selector *s, char **buf, size_t *buflen,
75 uint32_t depth)
76{
77 uint32_t i;
78 char *ptr = *buf;
79
80 *ptr++ = '|';
81 for (i = 0; i < depth; i++)
82 *ptr++ = ' ';
83
84 /* Build selector string */
85 for (i = 0; i < s->base.items; i++) {
86 dump_selector_list(s->selectors[i], &ptr);
87 if (i != (uint32_t) (s->base.items - 1)) {
88 memcpy(ptr, ", ", 2);
89 ptr += 2;
90 }
91 }
92 *ptr++ = '\n';
93
94 if (s->style != NULL)
95 dump_bytecode(s->style, &ptr, depth + 1);
96
97 *buflen -= ptr - *buf;
98 *buf = ptr;
99}
100
101void dump_rule_charset(css_rule_charset *s, char **buf, size_t *buflen)
102{
103 char *ptr = *buf;
104
105 ptr += sprintf(ptr, "| @charset(");
106 dump_string(s->encoding, &ptr);
107 *ptr++ = ')';
108 *ptr++ = '\n';
109
110 *buflen -= ptr - *buf;
111 *buf = ptr;
112}
113
114void dump_rule_import(css_rule_import *s, char **buf, size_t *buflen)
115{
116 char *ptr = *buf;
117
118 ptr += sprintf(ptr, "| @import url(\"%.*s\")",
119 (int) lwc_string_length(s->url), lwc_string_data(s->url));
120
123 *ptr++ = '\n';
124
125 *buflen -= ptr - *buf;
126 *buf = ptr;
127}
128
129void dump_rule_media(css_rule_media *s, char **buf, size_t *buflen)
130{
131 char *ptr = *buf;
132 css_rule *rule;
133
134 ptr += sprintf(ptr, "| @media %s%03" PRIx64,
135 s->media->negate_type ? "not " : "",
136 s->media->type);
137
138 /* \todo media list */
139
140 *ptr++ = '\n';
141
142 for (rule = s->first_child; rule != NULL; rule = rule->next) {
143 size_t len = *buflen - (ptr - *buf);
144
145 dump_rule_selector((css_rule_selector *) rule, &ptr, &len, 2);
146 }
147
148 *buflen -= ptr - *buf;
149 *buf = ptr;
150}
151
152void dump_rule_page(css_rule_page *s, char **buf, size_t *buflen)
153{
154 char *ptr = *buf;
155
156 ptr += sprintf(ptr, "| @page ");
157
158 if (s->selector != NULL)
159 dump_selector_list(s->selector, &ptr);
160
161 *ptr++ = '\n';
162
163 if (s->style != NULL)
164 dump_bytecode(s->style, &ptr, 2);
165
166 *buflen -= ptr - *buf;
167 *buf = ptr;
168}
169
170void dump_rule_font_face(css_rule_font_face *s, char **buf, size_t *buflen)
171{
172 char *ptr = *buf;
173
174 ptr += sprintf(ptr, "| @font-face ");
175
176 if (s->font_face != NULL) {
177 dump_font_face(s->font_face, &ptr);
178 }
179
180 *ptr++ = '\n';
181
182 *buflen -= ptr - *buf;
183 *buf = ptr;
184}
185
186void dump_selector_list(css_selector *list, char **ptr)
187{
188 if (list->combinator != NULL) {
189 dump_selector_list(list->combinator, ptr);
190 }
191
192 switch (list->data.comb) {
194 break;
196 (*ptr)[0] = ' ';
197 *ptr += 1;
198 break;
200 memcpy(*ptr, " > ", 3);
201 *ptr += 3;
202 break;
204 memcpy(*ptr, " + ", 3);
205 *ptr += 3;
206 break;
208 memcpy(*ptr, " + ", 3);
209 *ptr += 3;
210 break;
211 }
212
213 dump_selector(list, ptr);
214}
215
216
217void dump_selector(css_selector *selector, char **ptr)
218{
219 css_selector_detail *d = &selector->data;
220
221 while (true) {
222 dump_selector_detail(d, ptr);
223
224 if (d->next == 0)
225 break;
226
227 d++;
228 }
229}
230
231void dump_selector_detail(css_selector_detail *detail, char **ptr)
232{
233 if (detail->negate)
234 *ptr += sprintf(*ptr, ":not(");
235
236 switch (detail->type) {
238 if (lwc_string_length(detail->qname.name) == 1 &&
239 lwc_string_data(detail->qname.name)[0] == '*' &&
240 detail->next == 0) {
241 dump_string(detail->qname.name, ptr);
242 } else if (lwc_string_length(detail->qname.name) != 1 ||
243 lwc_string_data(detail->qname.name)[0] != '*') {
244 dump_string(detail->qname.name, ptr);
245 }
246 break;
248 **ptr = '.';
249 *ptr += 1;
250 dump_string(detail->qname.name, ptr);
251 break;
252 case CSS_SELECTOR_ID:
253 **ptr = '#';
254 *ptr += 1;
255 dump_string(detail->qname.name, ptr);
256 break;
259 **ptr = ':';
260 *ptr += 1;
261 dump_string(detail->qname.name, ptr);
263 if (detail->value.string != NULL) {
264 **ptr = '(';
265 *ptr += 1;
266 dump_string(detail->value.string, ptr);
267 **ptr = ')';
268 *ptr += 1;
269 }
270 } else {
271 *ptr += sprintf(*ptr, "(%dn+%d)",
272 detail->value.nth.a,
273 detail->value.nth.b);
274 }
275 break;
277 **ptr = '[';
278 *ptr += 1;
279 dump_string(detail->qname.name, ptr);
280 **ptr = ']';
281 *ptr += 1;
282 break;
284 **ptr = '[';
285 *ptr += 1;
286 dump_string(detail->qname.name, ptr);
287 (*ptr)[0] = '=';
288 (*ptr)[1] = '"';
289 *ptr += 2;
290 dump_string(detail->value.string, ptr);
291 (*ptr)[0] = '"';
292 (*ptr)[1] = ']';
293 *ptr += 2;
294 break;
296 **ptr = '[';
297 *ptr += 1;
298 dump_string(detail->qname.name, ptr);
299 (*ptr)[0] = '|';
300 (*ptr)[1] = '=';
301 (*ptr)[2] = '"';
302 *ptr += 3;
303 dump_string(detail->value.string, ptr);
304 (*ptr)[0] = '"';
305 (*ptr)[1] = ']';
306 *ptr += 2;
307 break;
309 **ptr = '[';
310 *ptr += 1;
311 dump_string(detail->qname.name, ptr);
312 (*ptr)[0] = '~';
313 (*ptr)[1] = '=';
314 (*ptr)[2] = '"';
315 *ptr += 3;
316 dump_string(detail->value.string, ptr);
317 (*ptr)[0] = '"';
318 (*ptr)[1] = ']';
319 *ptr += 2;
320 break;
322 **ptr = '[';
323 *ptr += 1;
324 dump_string(detail->qname.name, ptr);
325 (*ptr)[0] = '^';
326 (*ptr)[1] = '=';
327 (*ptr)[2] = '"';
328 *ptr += 3;
329 dump_string(detail->value.string, ptr);
330 (*ptr)[0] = '"';
331 (*ptr)[1] = ']';
332 *ptr += 2;
333 break;
335 **ptr = '[';
336 *ptr += 1;
337 dump_string(detail->qname.name, ptr);
338 (*ptr)[0] = '$';
339 (*ptr)[1] = '=';
340 (*ptr)[2] = '"';
341 *ptr += 3;
342 dump_string(detail->value.string, ptr);
343 (*ptr)[0] = '"';
344 (*ptr)[1] = ']';
345 *ptr += 2;
346 break;
348 **ptr = '[';
349 *ptr += 1;
350 dump_string(detail->qname.name, ptr);
351 (*ptr)[0] = '*';
352 (*ptr)[1] = '=';
353 (*ptr)[2] = '"';
354 *ptr += 3;
355 dump_string(detail->value.string, ptr);
356 (*ptr)[0] = '"';
357 (*ptr)[1] = ']';
358 *ptr += 2;
359 break;
360 }
361
362 if (detail->negate)
363 *ptr += sprintf(*ptr, ")");
364}
365
369static const char *opcode_names[] = {
370 "azimuth",
371 "background-attachment",
372 "background-color",
373 "background-image",
374 "background-position",
375 "background-repeat",
376 "border-collapse",
377 "border-spacing",
378 "border-top-color",
379 "border-right-color",
380 "border-bottom-color",
381 "border-left-color",
382 "border-top-style",
383 "border-right-style",
384 "border-bottom-style",
385 "border-left-style",
386 "border-top-width",
387 "border-right-width",
388 "border-bottom-width",
389 "border-left-width",
390 "bottom",
391 "caption-side",
392 "clear",
393 "clip",
394 "color",
395 "content",
396 "counter-increment",
397 "counter-reset",
398 "cue-after",
399 "cue-before",
400 "cursor",
401 "direction",
402 "display",
403 "elevation",
404 "empty-cells",
405 "float",
406 "font-family",
407 "font-size",
408 "font-style",
409 "font-variant",
410 "font-weight",
411 "height",
412 "left",
413 "letter-spacing",
414 "line-height",
415 "list-style-image",
416 "list-style-position",
417 "list-style-type",
418 "margin-top",
419 "margin-right",
420 "margin-bottom",
421 "margin-left",
422 "max-height",
423 "max-width",
424 "min-height",
425 "min-width",
426 "orphans",
427 "outline-color",
428 "outline-style",
429 "outline-width",
430 "overflow-x",
431 "padding-top",
432 "padding-right",
433 "padding-bottom",
434 "padding-left",
435 "page-break-after",
436 "page-break-before",
437 "page-break-inside",
438 "pause-after",
439 "pause-before",
440 "pitch-range",
441 "pitch",
442 "play-during",
443 "position",
444 "quotes",
445 "richness",
446 "right",
447 "speak-header",
448 "speak-numeral",
449 "speak-punctuation",
450 "speak",
451 "speech-rate",
452 "stress",
453 "table-layout",
454 "text-align",
455 "text-decoration",
456 "text-indent",
457 "text-transform",
458 "top",
459 "unicode-bidi",
460 "vertical-align",
461 "visibility",
462 "voice-family",
463 "volume",
464 "white-space",
465 "widows",
466 "width",
467 "word-spacing",
468 "z-index",
469 "opacity",
470 "break-after",
471 "break-before",
472 "break-inside",
473 "column-count",
474 "column-fill",
475 "column-gap",
476 "column-rule-color",
477 "column-rule-style",
478 "column-rule-width",
479 "column-span",
480 "column-width",
481 "writing-mode",
482 "overflow-y",
483 "box-sizing",
484 "align-content",
485 "align-items",
486 "align-self",
487 "flex-basis",
488 "flex-direction",
489 "flex-grow",
490 "flex-shrink",
491 "flex-wrap",
492 "justify-content",
493 "order",
494 "fill-opacity",
495 "stroke-opacity",
496};
497
498static void dump_css_fixed(css_fixed f, char **ptr)
499{
500#define ABS(x) (uint32_t)((x) < 0 ? -(x) : (x))
501 uint32_t uintpart = FIXTOINT(ABS(f));
502 /* + 500 to ensure round to nearest (division will truncate) */
503 uint32_t fracpart = ((ABS(f) & 0x3ff) * 1000 + 500) / (1 << 10);
504#undef ABS
505 size_t flen = 0;
506 char tmp[20];
507 size_t tlen = 0;
508 char *buf = *ptr;
509
510 if (f < 0) {
511 buf[0] = '-';
512 buf++;
513 }
514
515 do {
516 tmp[tlen] = "0123456789"[uintpart % 10];
517 tlen++;
518
519 uintpart /= 10;
520 } while (tlen < 20 && uintpart != 0);
521
522 while (tlen > 0) {
523 buf[0] = tmp[--tlen];
524 buf++;
525 }
526
527 buf[0] = '.';
528 buf++;
529
530 do {
531 tmp[tlen] = "0123456789"[fracpart % 10];
532 tlen++;
533
534 fracpart /= 10;
535 } while (tlen < 20 && fracpart != 0);
536
537 while (tlen > 0) {
538 buf[0] = tmp[--tlen];
539 buf++;
540 flen++;
541 }
542
543 while (flen < 3) {
544 buf[0] = '0';
545 buf++;
546 flen++;
547 }
548
549 buf[0] = '\0';
550
551 *ptr = buf;
552}
553
554static void dump_number(css_fixed val, char **ptr)
555{
556 if (INTTOFIX(FIXTOINT(val)) == val)
557 *ptr += sprintf(*ptr, "%d", FIXTOINT(val));
558 else
559 dump_css_fixed(val, ptr);
560}
561
562static void dump_unit(css_fixed val, uint32_t unit, char **ptr)
563{
564 dump_number(val, ptr);
565
566 switch (unit) {
567 case UNIT_PX:
568 *ptr += sprintf(*ptr, "px");
569 break;
570 case UNIT_EX:
571 *ptr += sprintf(*ptr, "ex");
572 break;
573 case UNIT_EM:
574 *ptr += sprintf(*ptr, "em");
575 break;
576 case UNIT_IN:
577 *ptr += sprintf(*ptr, "in");
578 break;
579 case UNIT_CM:
580 *ptr += sprintf(*ptr, "cm");
581 break;
582 case UNIT_MM:
583 *ptr += sprintf(*ptr, "mm");
584 break;
585 case UNIT_PT:
586 *ptr += sprintf(*ptr, "pt");
587 break;
588 case UNIT_PC:
589 *ptr += sprintf(*ptr, "pc");
590 break;
591 case UNIT_CH:
592 *ptr += sprintf(*ptr, "ch");
593 break;
594 case UNIT_REM:
595 *ptr += sprintf(*ptr, "rem");
596 break;
597 case UNIT_LH:
598 *ptr += sprintf(*ptr, "lh");
599 break;
600 case UNIT_VH:
601 *ptr += sprintf(*ptr, "vh");
602 break;
603 case UNIT_VW:
604 *ptr += sprintf(*ptr, "vw");
605 break;
606 case UNIT_VI:
607 *ptr += sprintf(*ptr, "vi");
608 break;
609 case UNIT_VB:
610 *ptr += sprintf(*ptr, "vb");
611 break;
612 case UNIT_VMIN:
613 *ptr += sprintf(*ptr, "vmin");
614 break;
615 case UNIT_VMAX:
616 *ptr += sprintf(*ptr, "vmax");
617 break;
618 case UNIT_Q:
619 *ptr += sprintf(*ptr, "q");
620 break;
621 case UNIT_PCT:
622 *ptr += sprintf(*ptr, "%%");
623 break;
624 case UNIT_DEG:
625 *ptr += sprintf(*ptr, "deg");
626 break;
627 case UNIT_GRAD:
628 *ptr += sprintf(*ptr, "grad");
629 break;
630 case UNIT_RAD:
631 *ptr += sprintf(*ptr, "rad");
632 break;
633 case UNIT_MS:
634 *ptr += sprintf(*ptr, "ms");
635 break;
636 case UNIT_S:
637 *ptr += sprintf(*ptr, "s");
638 break;
639 case UNIT_HZ:
640 *ptr += sprintf(*ptr, "Hz");
641 break;
642 case UNIT_KHZ:
643 *ptr += sprintf(*ptr, "kHz");
644 break;
645 case UNIT_CALC_ANY:
646 *ptr += sprintf(*ptr, "any");
647 break;
648 case UNIT_CALC_NUMBER:
649 *ptr += sprintf(*ptr, "number");
650 break;
651 }
652}
653
654static void dump_counter(lwc_string *name, uint32_t value,
655 char **ptr)
656{
657 *ptr += sprintf(*ptr, "counter(%.*s",
658 (int) lwc_string_length(name), lwc_string_data(name));
659
661
662 switch (value) {
664 *ptr += sprintf(*ptr, ", disc");
665 break;
667 *ptr += sprintf(*ptr, ", circle");
668 break;
670 *ptr += sprintf(*ptr, ", square");
671 break;
673 break;
675 *ptr += sprintf(*ptr, ", decimal-leading-zero");
676 break;
678 *ptr += sprintf(*ptr, ", lower-roman");
679 break;
681 *ptr += sprintf(*ptr, ", upper-roman");
682 break;
684 *ptr += sprintf(*ptr, ", lower-greek");
685 break;
687 *ptr += sprintf(*ptr, ", lower-latin");
688 break;
690 *ptr += sprintf(*ptr, ", upper-latin");
691 break;
693 *ptr += sprintf(*ptr, ", armenian");
694 break;
696 *ptr += sprintf(*ptr, ", georgian");
697 break;
699 *ptr += sprintf(*ptr, ", lower-alpha");
700 break;
702 *ptr += sprintf(*ptr, ", upper-alpha");
703 break;
705 *ptr += sprintf(*ptr, ", none");
706 break;
707 }
708
709 *ptr += sprintf(*ptr, ")");
710}
711
712static void dump_counters(lwc_string *name, lwc_string *separator,
713 uint32_t value, char **ptr)
714{
715 *ptr += sprintf(*ptr, "counter(%.*s, %.*s",
716 (int) lwc_string_length(name),
717 lwc_string_data(name),
718 (int) lwc_string_length(separator),
719 lwc_string_data(separator));
720
722
723 switch (value) {
725 *ptr += sprintf(*ptr, ", disc");
726 break;
728 *ptr += sprintf(*ptr, ", circle");
729 break;
731 *ptr += sprintf(*ptr, ", square");
732 break;
734 break;
736 *ptr += sprintf(*ptr, ", decimal-leading-zero");
737 break;
739 *ptr += sprintf(*ptr, ", lower-roman");
740 break;
742 *ptr += sprintf(*ptr, ", upper-roman");
743 break;
745 *ptr += sprintf(*ptr, ", lower-greek");
746 break;
748 *ptr += sprintf(*ptr, ", lower-latin");
749 break;
751 *ptr += sprintf(*ptr, ", upper-latin");
752 break;
754 *ptr += sprintf(*ptr, ", armenian");
755 break;
757 *ptr += sprintf(*ptr, ", georgian");
758 break;
760 *ptr += sprintf(*ptr, ", lower-alpha");
761 break;
763 *ptr += sprintf(*ptr, ", upper-alpha");
764 break;
766 *ptr += sprintf(*ptr, ", none");
767 break;
768 }
769
770 *ptr += sprintf(*ptr, ")");
771}
772
773void dump_bytecode(css_style *style, char **ptr, uint32_t depth)
774{
775 void *bytecode = style->bytecode;
776 size_t length = (style->used * sizeof(css_code_t));
777 uint32_t offset = 0;
778
779#define ADVANCE(n) do { \
780 offset += (n); \
781 bytecode = ((uint8_t *) bytecode) + (n); \
782} while(0)
783
784 while (offset < length) {
785 opcode_t op;
786 uint32_t value;
787 uint32_t opv = *((uint32_t *) bytecode);
788 uint32_t i;
789
790 ADVANCE(sizeof(opv));
791
792 op = getOpcode(opv);
793
794 *((*ptr)++) = '|';
795 for (i = 0; i < depth; i++)
796 *((*ptr)++) = ' ';
797 *ptr += sprintf(*ptr, "%s: ", opcode_names[op]);
798
799 if (getFlagValue(opv) == FLAG_VALUE_INHERIT) {
800 *ptr += sprintf(*ptr, "inherit");
801 } else if (getFlagValue(opv) == FLAG_VALUE_INITIAL) {
802 *ptr += sprintf(*ptr, "initial");
803 } else if (getFlagValue(opv) == FLAG_VALUE_REVERT) {
804 *ptr += sprintf(*ptr, "revert");
805 } else if (getFlagValue(opv) == FLAG_VALUE_UNSET) {
806 *ptr += sprintf(*ptr, "unset");
807 } else if (isCalc(opv)) {
808 lwc_string *calc_expr = NULL;
809 const uint8_t *codeptr = NULL;
810 css_code_t calc_opcode;
811 uint32_t unit, snum;
812 /* First entry is a unit */
813 unit = *((uint32_t *)bytecode);
814 ADVANCE(sizeof(unit));
815 /* Second entry is an lwc_string of the expression */
816 snum = *((uint32_t *)bytecode);
817 ADVANCE(sizeof(snum));
818 css__stylesheet_string_get(style->sheet, snum, &calc_expr);
819 codeptr = (const uint8_t *)lwc_string_data(calc_expr);
820 *ptr += sprintf(*ptr, "/* -> ");
821 dump_unit(0, unit, ptr);
822 *ptr += sprintf(*ptr, " */ calc(");
823 while ((calc_opcode = *((css_code_t *)(void *)codeptr)) != CALC_FINISH) {
824 codeptr += sizeof(calc_opcode);
825 switch (calc_opcode) {
826 case CALC_ADD:
827 *ptr += sprintf(*ptr, "+ ");
828 break;
829 case CALC_SUBTRACT:
830 *ptr += sprintf(*ptr, "- ");
831 break;
832 case CALC_MULTIPLY:
833 *ptr += sprintf(*ptr, "* ");
834 break;
835 case CALC_DIVIDE:
836 *ptr += sprintf(*ptr, "/ ");
837 break;
838 case CALC_PUSH_VALUE: {
839 css_fixed num = *((css_fixed *)(void *)codeptr);
840 codeptr += sizeof(num);
841 uint32_t unit = *((uint32_t *)(void *)codeptr);
842 codeptr += sizeof(unit);
843 dump_unit(num, unit, ptr);
844 *ptr += sprintf(*ptr, " ");
845 break;
846 }
847 case CALC_PUSH_NUMBER: {
848 css_fixed num = *((css_fixed *)(void *)codeptr);
849 codeptr += sizeof(num);
850 dump_number(num, ptr);
851 *ptr += sprintf(*ptr, " ");
852 break;
853 }
854 default:
855 *ptr += sprintf(*ptr, "??%d ", calc_opcode);
856 break;
857 }
858 }
859 *ptr += sprintf(*ptr, "=)");
860 } else {
861 value = getValue(opv);
862
863 switch (op) {
865 switch (value) {
867 *ptr += sprintf(*ptr, "stretch");
868 break;
870 *ptr += sprintf(*ptr, "flex-start");
871 break;
873 *ptr += sprintf(*ptr, "flex-end");
874 break;
876 *ptr += sprintf(*ptr, "center");
877 break;
879 *ptr += sprintf(*ptr, "space-between");
880 break;
882 *ptr += sprintf(*ptr, "space-around");
883 break;
885 *ptr += sprintf(*ptr, "space-evenly");
886 break;
887 }
888 break;
890 switch (value) {
892 *ptr += sprintf(*ptr, "stretch");
893 break;
895 *ptr += sprintf(*ptr, "flex-start");
896 break;
898 *ptr += sprintf(*ptr, "flex-end");
899 break;
901 *ptr += sprintf(*ptr, "center");
902 break;
904 *ptr += sprintf(*ptr, "baseline");
905 break;
906 }
907 break;
909 switch (value) {
911 *ptr += sprintf(*ptr, "stretch");
912 break;
914 *ptr += sprintf(*ptr, "flex-start");
915 break;
917 *ptr += sprintf(*ptr, "flex-end");
918 break;
920 *ptr += sprintf(*ptr, "center");
921 break;
923 *ptr += sprintf(*ptr, "baseline");
924 break;
925 case ALIGN_SELF_AUTO:
926 *ptr += sprintf(*ptr, "auto");
927 break;
928 }
929 break;
930 case CSS_PROP_AZIMUTH:
931 switch (value & ~AZIMUTH_BEHIND) {
932 case AZIMUTH_ANGLE:
933 {
934 uint32_t unit;
935 css_fixed val = *((css_fixed *) bytecode);
936 ADVANCE(sizeof(val));
937 unit = *((uint32_t *) bytecode);
938 ADVANCE(sizeof(unit));
939 dump_unit(val, unit, ptr);
940 }
941 break;
943 *ptr += sprintf(*ptr, "leftwards");
944 break;
946 *ptr += sprintf(*ptr, "rightwards");
947 break;
949 *ptr += sprintf(*ptr, "left-side");
950 break;
951 case AZIMUTH_FAR_LEFT:
952 *ptr += sprintf(*ptr, "far-left");
953 break;
954 case AZIMUTH_LEFT:
955 *ptr += sprintf(*ptr, "left");
956 break;
958 *ptr += sprintf(*ptr, "center-left");
959 break;
960 case AZIMUTH_CENTER:
961 *ptr += sprintf(*ptr, "center");
962 break;
964 *ptr += sprintf(*ptr, "center-right");
965 break;
966 case AZIMUTH_RIGHT:
967 *ptr += sprintf(*ptr, "right");
968 break;
970 *ptr += sprintf(*ptr, "far-right");
971 break;
973 *ptr += sprintf(*ptr, "right-side");
974 break;
975 }
976 if (value & AZIMUTH_BEHIND)
977 *ptr += sprintf(*ptr, " behind");
978 break;
980 switch (value) {
982 *ptr += sprintf(*ptr, "fixed");
983 break;
985 *ptr += sprintf(*ptr, "scroll");
986 break;
987 }
988 break;
1002 (enum op_background_color)
1004
1005 switch (value) {
1007 *ptr += sprintf(*ptr, "transparent");
1008 break;
1010 *ptr += sprintf(*ptr, "currentColor");
1011 break;
1013 {
1014 uint32_t colour =
1015 *((uint32_t *) bytecode);
1016 ADVANCE(sizeof(colour));
1017 *ptr += sprintf(*ptr, "#%08x", colour);
1018 }
1019 break;
1020 }
1021 break;
1023 case CSS_PROP_CUE_AFTER:
1027 (enum op_background_image)
1030 (enum op_background_image)
1033 (enum op_background_image)
1036 (enum op_background_image)
1039 (enum op_background_image)
1042 (enum op_background_image)
1044
1045 switch (value) {
1047 *ptr += sprintf(*ptr, "none");
1048 break;
1050 {
1051 uint32_t snum = *((uint32_t *) bytecode);
1052 lwc_string *he;
1054 snum,
1055 &he);
1056 ADVANCE(sizeof(snum));
1057 *ptr += sprintf(*ptr, "url('%.*s')",
1058 (int) lwc_string_length(he),
1059 lwc_string_data(he));
1060 }
1061 break;
1062 }
1063 break;
1065 switch (value & 0xf0) {
1067 {
1068 uint32_t unit;
1069 css_fixed val = *((css_fixed *) bytecode);
1070 ADVANCE(sizeof(val));
1071 unit = *((uint32_t *) bytecode);
1072 ADVANCE(sizeof(unit));
1073 dump_unit(val, unit, ptr);
1074 }
1075 break;
1077 *ptr += sprintf(*ptr, "center");
1078 break;
1080 *ptr += sprintf(*ptr, "right");
1081 break;
1083 *ptr += sprintf(*ptr, "left");
1084 break;
1085 }
1086 *ptr += sprintf(*ptr, " ");
1087 switch (value & 0x0f) {
1089 {
1090 uint32_t unit;
1091 css_fixed val = *((css_fixed *) bytecode);
1092 ADVANCE(sizeof(val));
1093 unit = *((uint32_t *) bytecode);
1094 ADVANCE(sizeof(unit));
1095 dump_unit(val, unit, ptr);
1096 }
1097 break;
1099 *ptr += sprintf(*ptr, "center");
1100 break;
1102 *ptr += sprintf(*ptr, "bottom");
1103 break;
1105 *ptr += sprintf(*ptr, "top");
1106 break;
1107 }
1108 break;
1110 switch (value) {
1112 *ptr += sprintf(*ptr, "no-repeat");
1113 break;
1115 *ptr += sprintf(*ptr, "repeat-x");
1116 break;
1118 *ptr += sprintf(*ptr, "repeat-y");
1119 break;
1121 *ptr += sprintf(*ptr, "repeat");
1122 break;
1123 }
1124 break;
1126 switch (value) {
1128 *ptr += sprintf(*ptr, "separate");
1129 break;
1131 *ptr += sprintf(*ptr, "collapse");
1132 break;
1133 }
1134 break;
1136 switch (value) {
1137 case BORDER_SPACING_SET:
1138 {
1139 uint32_t unit;
1140 css_fixed val = *((css_fixed *) bytecode);
1141 ADVANCE(sizeof(val));
1142 unit = *((uint32_t *) bytecode);
1143 ADVANCE(sizeof(unit));
1144 dump_unit(val, unit, ptr);
1145
1146 val = *((css_fixed *) bytecode);
1147 ADVANCE(sizeof(val));
1148 unit = *((uint32_t *) bytecode);
1149 ADVANCE(sizeof(unit));
1150 dump_unit(val, unit, ptr);
1151 }
1152 break;
1153 }
1154 break;
1156 switch (value) {
1158 *ptr += sprintf(*ptr, "content-box");
1159 break;
1161 *ptr += sprintf(*ptr, "border-box");
1162 break;
1163 }
1164 break;
1172 (enum op_border_style)
1175 (enum op_border_style)
1178 (enum op_border_style)
1181 (enum op_border_style)
1184 (enum op_border_style)
1187 (enum op_border_style)
1190 (enum op_border_style)
1193 (enum op_border_style)
1196 (enum op_border_style)
1199 (enum op_border_style)
1202 (enum op_border_style)
1205 (enum op_border_style)
1208 (enum op_border_style)
1211 (enum op_border_style)
1214 (enum op_border_style)
1217 (enum op_border_style)
1220 (enum op_border_style)
1223 (enum op_border_style)
1226 (enum op_border_style)
1229 (enum op_border_style)
1231
1232 switch (value) {
1233 case BORDER_STYLE_NONE:
1234 *ptr += sprintf(*ptr, "none");
1235 break;
1237 *ptr += sprintf(*ptr, "hidden");
1238 break;
1240 *ptr += sprintf(*ptr, "dotted");
1241 break;
1243 *ptr += sprintf(*ptr, "dashed");
1244 break;
1245 case BORDER_STYLE_SOLID:
1246 *ptr += sprintf(*ptr, "solid");
1247 break;
1249 *ptr += sprintf(*ptr, "double");
1250 break;
1252 *ptr += sprintf(*ptr, "groove");
1253 break;
1254 case BORDER_STYLE_RIDGE:
1255 *ptr += sprintf(*ptr, "ridge");
1256 break;
1257 case BORDER_STYLE_INSET:
1258 *ptr += sprintf(*ptr, "inset");
1259 break;
1261 *ptr += sprintf(*ptr, "outset");
1262 break;
1263 }
1264 break;
1272 (enum op_border_width)
1275 (enum op_border_width)
1278 (enum op_border_width)
1281 (enum op_border_width)
1283
1284 switch (value) {
1285 case BORDER_WIDTH_SET:
1286 {
1287 uint32_t unit;
1288 css_fixed val = *((css_fixed *) bytecode);
1289 ADVANCE(sizeof(val));
1290 unit = *((uint32_t *) bytecode);
1291 ADVANCE(sizeof(unit));
1292 dump_unit(val, unit, ptr);
1293 }
1294 break;
1295 case BORDER_WIDTH_THIN:
1296 *ptr += sprintf(*ptr, "thin");
1297 break;
1299 *ptr += sprintf(*ptr, "medium");
1300 break;
1301 case BORDER_WIDTH_THICK:
1302 *ptr += sprintf(*ptr, "thick");
1303 break;
1304 }
1305 break;
1310 case CSS_PROP_BOTTOM:
1311 case CSS_PROP_LEFT:
1312 case CSS_PROP_RIGHT:
1313 case CSS_PROP_TOP:
1314 case CSS_PROP_HEIGHT:
1315 case CSS_PROP_WIDTH:
1318 (enum op_bottom) LEFT_SET);
1320 (enum op_bottom) LEFT_AUTO);
1322 (enum op_bottom) RIGHT_SET);
1324 (enum op_bottom) RIGHT_AUTO);
1326 (enum op_bottom) TOP_SET);
1328 (enum op_bottom) TOP_AUTO);
1330 (enum op_bottom) HEIGHT_SET);
1332 (enum op_bottom) HEIGHT_AUTO);
1334 (enum op_bottom) MARGIN_SET);
1336 (enum op_bottom) MARGIN_AUTO);
1338 (enum op_bottom) WIDTH_SET);
1340 (enum op_bottom) WIDTH_AUTO);
1342 (enum op_bottom)
1345 (enum op_bottom)
1347
1348 switch (value) {
1349 case BOTTOM_SET:
1350 {
1351 uint32_t unit;
1352 css_fixed val = *((css_fixed *) bytecode);
1353 ADVANCE(sizeof(val));
1354 unit = *((uint32_t *) bytecode);
1355 ADVANCE(sizeof(unit));
1356 dump_unit(val, unit, ptr);
1357 }
1358 break;
1359 case BOTTOM_AUTO:
1360 *ptr += sprintf(*ptr, "auto");
1361 break;
1362 }
1363 break;
1367 (enum op_break_after)
1370 (enum op_break_after)
1373 (enum op_break_after)
1376 (enum op_break_after)
1379 (enum op_break_after)
1382 (enum op_break_after)
1385 (enum op_break_after)
1388 (enum op_break_after)
1391 (enum op_break_after)
1393
1394 switch (value) {
1395 case BREAK_AFTER_AUTO:
1396 *ptr += sprintf(*ptr, "auto");
1397 break;
1398 case BREAK_AFTER_ALWAYS:
1399 *ptr += sprintf(*ptr, "always");
1400 break;
1401 case BREAK_AFTER_AVOID:
1402 *ptr += sprintf(*ptr, "avoid");
1403 break;
1404 case BREAK_AFTER_LEFT:
1405 *ptr += sprintf(*ptr, "left");
1406 break;
1407 case BREAK_AFTER_RIGHT:
1408 *ptr += sprintf(*ptr, "right");
1409 break;
1410 case BREAK_AFTER_PAGE:
1411 *ptr += sprintf(*ptr, "page");
1412 break;
1413 case BREAK_AFTER_COLUMN:
1414 *ptr += sprintf(*ptr, "column");
1415 break;
1417 *ptr += sprintf(*ptr, "avoid-page");
1418 break;
1420 *ptr += sprintf(*ptr, "avoid-column");
1421 break;
1422 }
1423 break;
1425 switch (value) {
1426 case BREAK_INSIDE_AUTO:
1427 *ptr += sprintf(*ptr, "auto");
1428 break;
1429 case BREAK_INSIDE_AVOID:
1430 *ptr += sprintf(*ptr, "avoid");
1431 break;
1433 *ptr += sprintf(*ptr, "avoid-page");
1434 break;
1436 *ptr += sprintf(*ptr, "avoid-column");
1437 break;
1438 }
1439 break;
1441 switch (value) {
1442 case CAPTION_SIDE_TOP:
1443 *ptr += sprintf(*ptr, "top");
1444 break;
1446 *ptr += sprintf(*ptr, "bottom");
1447 break;
1448 }
1449 break;
1450 case CSS_PROP_CLEAR:
1451 switch (value) {
1452 case CLEAR_NONE:
1453 *ptr += sprintf(*ptr, "none");
1454 break;
1455 case CLEAR_LEFT:
1456 *ptr += sprintf(*ptr, "left");
1457 break;
1458 case CLEAR_RIGHT:
1459 *ptr += sprintf(*ptr, "right");
1460 break;
1461 case CLEAR_BOTH:
1462 *ptr += sprintf(*ptr, "both");
1463 break;
1464 }
1465 break;
1466 case CSS_PROP_CLIP:
1467 if ((value & CLIP_SHAPE_MASK) ==
1469 *ptr += sprintf(*ptr, "rect(");
1470 if (value & CLIP_RECT_TOP_AUTO) {
1471 *ptr += sprintf(*ptr, "auto");
1472 } else {
1473 uint32_t unit;
1474 css_fixed val =
1475 *((css_fixed *) bytecode);
1476 ADVANCE(sizeof(val));
1477 unit = *((uint32_t *) bytecode);
1478 ADVANCE(sizeof(unit));
1479 dump_unit(val, unit, ptr);
1480 }
1481 *ptr += sprintf(*ptr, ", ");
1482 if (value & CLIP_RECT_RIGHT_AUTO) {
1483 *ptr += sprintf(*ptr, "auto");
1484 } else {
1485 uint32_t unit;
1486 css_fixed val =
1487 *((css_fixed *) bytecode);
1488 ADVANCE(sizeof(val));
1489 unit = *((uint32_t *) bytecode);
1490 ADVANCE(sizeof(unit));
1491 dump_unit(val, unit, ptr);
1492 }
1493 *ptr += sprintf(*ptr, ", ");
1494 if (value & CLIP_RECT_BOTTOM_AUTO) {
1495 *ptr += sprintf(*ptr, "auto");
1496 } else {
1497 uint32_t unit;
1498 css_fixed val =
1499 *((css_fixed *) bytecode);
1500 ADVANCE(sizeof(val));
1501 unit = *((uint32_t *) bytecode);
1502 ADVANCE(sizeof(unit));
1503 dump_unit(val, unit, ptr);
1504 }
1505 *ptr += sprintf(*ptr, ", ");
1506 if (value & CLIP_RECT_LEFT_AUTO) {
1507 *ptr += sprintf(*ptr, "auto");
1508 } else {
1509 uint32_t unit;
1510 css_fixed val =
1511 *((css_fixed *) bytecode);
1512 ADVANCE(sizeof(val));
1513 unit = *((uint32_t *) bytecode);
1514 ADVANCE(sizeof(unit));
1515 dump_unit(val, unit, ptr);
1516 }
1517 *ptr += sprintf(*ptr, ")");
1518 } else
1519 *ptr += sprintf(*ptr, "auto");
1520 break;
1521 case CSS_PROP_COLOR:
1522 switch (value) {
1523 case COLOR_TRANSPARENT:
1524 *ptr += sprintf(*ptr, "transparent");
1525 break;
1527 *ptr += sprintf(*ptr, "currentColor");
1528 break;
1529 case COLOR_SET:
1530 {
1531 uint32_t colour =
1532 *((uint32_t *) bytecode);
1533 ADVANCE(sizeof(colour));
1534 *ptr += sprintf(*ptr, "#%08x", colour);
1535 }
1536 break;
1537 }
1538 break;
1540 switch (value) {
1541 case COLUMN_COUNT_SET:
1542 {
1543 css_fixed val = *((css_fixed *) bytecode);
1544 ADVANCE(sizeof(val));
1545 dump_number(val, ptr);
1546 }
1547 break;
1548 case COLUMN_COUNT_AUTO:
1549 *ptr += sprintf(*ptr, "auto");
1550 break;
1551 }
1552 break;
1554 switch (value) {
1556 *ptr += sprintf(*ptr, "balance");
1557 break;
1558 case COLUMN_FILL_AUTO:
1559 *ptr += sprintf(*ptr, "auto");
1560 break;
1561 }
1562 break;
1564 switch (value) {
1565 case COLUMN_GAP_SET:
1566 {
1567 uint32_t unit;
1568 css_fixed val = *((css_fixed *) bytecode);
1569 ADVANCE(sizeof(val));
1570 unit = *((uint32_t *) bytecode);
1571 ADVANCE(sizeof(unit));
1572 dump_unit(val, unit, ptr);
1573 }
1574 break;
1575 case COLUMN_GAP_NORMAL:
1576 *ptr += sprintf(*ptr, "normal");
1577 break;
1578 }
1579 break;
1581 switch (value) {
1582 case COLUMN_SPAN_NONE:
1583 *ptr += sprintf(*ptr, "none");
1584 break;
1585 case COLUMN_SPAN_ALL:
1586 *ptr += sprintf(*ptr, "all");
1587 break;
1588 }
1589 break;
1590 case CSS_PROP_CONTENT:
1591 if (value == CONTENT_NORMAL) {
1592 *ptr += sprintf(*ptr, "normal");
1593 break;
1594 } else if (value == CONTENT_NONE) {
1595 *ptr += sprintf(*ptr, "none");
1596 break;
1597 }
1598
1599 while (value != CONTENT_NORMAL) {
1600 uint32_t snum = *((uint32_t *) bytecode);
1601 lwc_string *he;
1602 const char *end = "";
1603
1604 switch (value & 0xff) {
1605 case CONTENT_COUNTER:
1606 css__stylesheet_string_get(style->sheet, snum, &he);
1607 ADVANCE(sizeof(snum));
1608 dump_counter(he, value, ptr);
1609 break;
1610
1611 case CONTENT_COUNTERS:
1612 {
1613 lwc_string *sep;
1614 css__stylesheet_string_get(style->sheet, snum, &he);
1615 ADVANCE(sizeof(snum));
1616
1617 sep = *((lwc_string **) bytecode);
1618 ADVANCE(sizeof(sep));
1619
1620 dump_counters(he, sep, value,
1621 ptr);
1622 }
1623 break;
1624
1625 case CONTENT_URI:
1626 case CONTENT_ATTR:
1627 case CONTENT_STRING:
1628 css__stylesheet_string_get(style->sheet, snum, &he);
1629 if (value == CONTENT_URI)
1630 *ptr += sprintf(*ptr, "url(");
1631 if (value == CONTENT_ATTR)
1632 *ptr += sprintf(*ptr, "attr(");
1633 if (value != CONTENT_STRING)
1634 end = ")";
1635
1636 ADVANCE(sizeof(snum));
1637
1638 *ptr += sprintf(*ptr, "'%.*s'%s",
1639 (int) lwc_string_length(he),
1640 lwc_string_data(he),
1641 end);
1642 break;
1643
1644 case CONTENT_OPEN_QUOTE:
1645 *ptr += sprintf(*ptr, "open-quote");
1646 break;
1647
1649 *ptr += sprintf(*ptr, "close-quote");
1650 break;
1651
1653 *ptr += sprintf(*ptr, "no-open-quote");
1654 break;
1655
1657 *ptr += sprintf(*ptr, "no-close-quote");
1658 break;
1659 }
1660
1661 value = *((uint32_t *) bytecode);
1662 ADVANCE(sizeof(value));
1663
1664 if (value != CONTENT_NORMAL)
1665 *ptr += sprintf(*ptr, " ");
1666 }
1667 break;
1676
1677 switch (value) {
1679 while (value != COUNTER_INCREMENT_NONE) {
1680 css_fixed val;
1681 uint32_t snum = *((uint32_t *) bytecode); lwc_string *he;
1683 snum,
1684 &he);
1685 ADVANCE(sizeof(snum));
1686 *ptr += sprintf(*ptr, "%.*s ",
1687 (int)lwc_string_length(he),
1688 lwc_string_data(he));
1689 val = *((css_fixed *) bytecode);
1690 ADVANCE(sizeof(val));
1691 dump_number(val, ptr);
1692
1693 value = *((uint32_t *) bytecode);
1694 ADVANCE(sizeof(value));
1695
1696 if (value !=
1698 *ptr += sprintf(*ptr,
1699 " ");
1700 }
1701 break;
1703 *ptr += sprintf(*ptr, "none");
1704 break;
1705 }
1706 break;
1707 case CSS_PROP_CURSOR:
1708 while (value == CURSOR_URI) {
1709 uint32_t snum = *((uint32_t *) bytecode); lwc_string *he;
1711 snum,
1712 &he);
1713 ADVANCE(sizeof(snum));
1714 *ptr += sprintf(*ptr, "url('%.*s'), ",
1715 (int) lwc_string_length(he),
1716 lwc_string_data(he));
1717
1718 value = *((uint32_t *) bytecode);
1719 ADVANCE(sizeof(value));
1720 }
1721
1722 switch (value) {
1723 case CURSOR_AUTO:
1724 *ptr += sprintf(*ptr, "auto");
1725 break;
1726 case CURSOR_CROSSHAIR:
1727 *ptr += sprintf(*ptr, "crosshair");
1728 break;
1729 case CURSOR_DEFAULT:
1730 *ptr += sprintf(*ptr, "default");
1731 break;
1732 case CURSOR_POINTER:
1733 *ptr += sprintf(*ptr, "pointer");
1734 break;
1735 case CURSOR_MOVE:
1736 *ptr += sprintf(*ptr, "move");
1737 break;
1738 case CURSOR_E_RESIZE:
1739 *ptr += sprintf(*ptr, "e-resize");
1740 break;
1741 case CURSOR_NE_RESIZE:
1742 *ptr += sprintf(*ptr, "ne-resize");
1743 break;
1744 case CURSOR_NW_RESIZE:
1745 *ptr += sprintf(*ptr, "nw-resize");
1746 break;
1747 case CURSOR_N_RESIZE:
1748 *ptr += sprintf(*ptr, "n-resize");
1749 break;
1750 case CURSOR_SE_RESIZE:
1751 *ptr += sprintf(*ptr, "se-resize");
1752 break;
1753 case CURSOR_SW_RESIZE:
1754 *ptr += sprintf(*ptr, "sw-resize");
1755 break;
1756 case CURSOR_S_RESIZE:
1757 *ptr += sprintf(*ptr, "s-resize");
1758 break;
1759 case CURSOR_W_RESIZE:
1760 *ptr += sprintf(*ptr, "w-resize");
1761 break;
1762 case CURSOR_TEXT:
1763 *ptr += sprintf(*ptr, "text");
1764 break;
1765 case CURSOR_WAIT:
1766 *ptr += sprintf(*ptr, "wait");
1767 break;
1768 case CURSOR_HELP:
1769 *ptr += sprintf(*ptr, "help");
1770 break;
1771 case CURSOR_PROGRESS:
1772 *ptr += sprintf(*ptr, "progress");
1773 break;
1774 }
1775 break;
1776 case CSS_PROP_DIRECTION:
1777 switch (value) {
1778 case DIRECTION_LTR:
1779 *ptr += sprintf(*ptr, "ltr");
1780 break;
1781 case DIRECTION_RTL:
1782 *ptr += sprintf(*ptr, "rtl");
1783 break;
1784 }
1785 break;
1786 case CSS_PROP_DISPLAY:
1787 switch (value) {
1788 case DISPLAY_INLINE:
1789 *ptr += sprintf(*ptr, "inline");
1790 break;
1791 case DISPLAY_BLOCK:
1792 *ptr += sprintf(*ptr, "block");
1793 break;
1794 case DISPLAY_LIST_ITEM:
1795 *ptr += sprintf(*ptr, "list-item");
1796 break;
1797 case DISPLAY_RUN_IN:
1798 *ptr += sprintf(*ptr, "run-in");
1799 break;
1801 *ptr += sprintf(*ptr, "inline-block");
1802 break;
1803 case DISPLAY_TABLE:
1804 *ptr += sprintf(*ptr, "table");
1805 break;
1807 *ptr += sprintf(*ptr, "inline-table");
1808 break;
1810 *ptr += sprintf(*ptr, "table-row-group");
1811 break;
1813 *ptr += sprintf(*ptr, "table-header-group");
1814 break;
1816 *ptr += sprintf(*ptr, "table-footer-group");
1817 break;
1818 case DISPLAY_TABLE_ROW:
1819 *ptr += sprintf(*ptr, "table-row");
1820 break;
1822 *ptr += sprintf(*ptr, "table-column-group");
1823 break;
1825 *ptr += sprintf(*ptr, "table-column");
1826 break;
1827 case DISPLAY_TABLE_CELL:
1828 *ptr += sprintf(*ptr, "table-cell");
1829 break;
1831 *ptr += sprintf(*ptr, "table-caption");
1832 break;
1833 case DISPLAY_NONE:
1834 *ptr += sprintf(*ptr, "none");
1835 break;
1836 case DISPLAY_FLEX:
1837 *ptr += sprintf(*ptr, "flex");
1838 break;
1840 *ptr += sprintf(*ptr, "inline-flex");
1841 break;
1842 }
1843 break;
1844 case CSS_PROP_ELEVATION:
1845 switch (value) {
1846 case ELEVATION_ANGLE:
1847 {
1848 uint32_t unit;
1849 css_fixed val = *((css_fixed *) bytecode);
1850 ADVANCE(sizeof(val));
1851 unit = *((uint32_t *) bytecode);
1852 ADVANCE(sizeof(unit));
1853 dump_unit(val, unit, ptr);
1854 }
1855 break;
1856 case ELEVATION_BELOW:
1857 *ptr += sprintf(*ptr, "below");
1858 break;
1859 case ELEVATION_LEVEL:
1860 *ptr += sprintf(*ptr, "level");
1861 break;
1862 case ELEVATION_ABOVE:
1863 *ptr += sprintf(*ptr, "above");
1864 break;
1865 case ELEVATION_HIGHER:
1866 *ptr += sprintf(*ptr, "higher");
1867 break;
1868 case ELEVATION_LOWER:
1869 *ptr += sprintf(*ptr, "lower");
1870 break;
1871 }
1872 break;
1874 switch (value) {
1875 case EMPTY_CELLS_SHOW:
1876 *ptr += sprintf(*ptr, "show");
1877 break;
1878 case EMPTY_CELLS_HIDE:
1879 *ptr += sprintf(*ptr, "hide");
1880 break;
1881 }
1882 break;
1884 switch (value) {
1885 case FILL_OPACITY_SET:
1886 {
1887 css_fixed val = *((css_fixed *) bytecode);
1888 ADVANCE(sizeof(val));
1889 dump_number(val, ptr);
1890 }
1891 break;
1892 }
1893 break;
1895 switch (value) {
1896 case STROKE_OPACITY_SET:
1897 {
1898 css_fixed val = *((css_fixed *) bytecode);
1899 ADVANCE(sizeof(val));
1900 dump_number(val, ptr);
1901 }
1902 break;
1903 }
1904 break;
1906 switch (value) {
1907 case FLEX_BASIS_AUTO:
1908 *ptr += sprintf(*ptr, "auto");
1909 break;
1910 case FLEX_BASIS_CONTENT:
1911 *ptr += sprintf(*ptr, "content");
1912 break;
1913 case FLEX_BASIS_SET:
1914 {
1915 uint32_t unit;
1916 css_fixed val = *((css_fixed *) bytecode);
1917 ADVANCE(sizeof(val));
1918 unit = *((uint32_t *) bytecode);
1919 ADVANCE(sizeof(unit));
1920 dump_unit(val, unit, ptr);
1921 }
1922 break;
1923 }
1924 break;
1926 switch (value) {
1927 case FLEX_DIRECTION_ROW:
1928 *ptr += sprintf(*ptr, "row");
1929 break;
1931 *ptr += sprintf(*ptr, "column");
1932 break;
1934 *ptr += sprintf(*ptr, "row-reverse");
1935 break;
1937 *ptr += sprintf(*ptr, "column-reverse");
1938 break;
1939 }
1940 break;
1941 case CSS_PROP_FLEX_GROW:
1942 switch (value) {
1943 case FLEX_GROW_SET:
1944 {
1945 css_fixed val = *((css_fixed *) bytecode);
1946 ADVANCE(sizeof(val));
1947 dump_number(val, ptr);
1948 }
1949 break;
1950 }
1951 break;
1953 switch (value) {
1954 case FLEX_SHRINK_SET:
1955 {
1956 css_fixed val = *((css_fixed *) bytecode);
1957 ADVANCE(sizeof(val));
1958 dump_number(val, ptr);
1959 }
1960 break;
1961 }
1962 break;
1963 case CSS_PROP_FLEX_WRAP:
1964 switch (value) {
1965 case FLEX_WRAP_NOWRAP:
1966 *ptr += sprintf(*ptr, "nowrap");
1967 break;
1968 case FLEX_WRAP_WRAP:
1969 *ptr += sprintf(*ptr, "wrap");
1970 break;
1972 *ptr += sprintf(*ptr, "wrap-reverse");
1973 break;
1974 }
1975 break;
1976 case CSS_PROP_FLOAT:
1977 switch (value) {
1978 case FLOAT_LEFT:
1979 *ptr += sprintf(*ptr, "left");
1980 break;
1981 case FLOAT_RIGHT:
1982 *ptr += sprintf(*ptr, "right");
1983 break;
1984 case FLOAT_NONE:
1985 *ptr += sprintf(*ptr, "none");
1986 break;
1987 }
1988 break;
1990 while (value != FONT_FAMILY_END) {
1991 switch (value) {
1992 case FONT_FAMILY_STRING:
1994 {
1995 uint32_t snum = *((uint32_t *) bytecode);
1996 lwc_string *he;
1997 css__stylesheet_string_get(style->sheet, snum, &he);
1998 ADVANCE(sizeof(snum));
1999 *ptr += sprintf(*ptr, "'%.*s'",
2000 (int) lwc_string_length(he),
2001 lwc_string_data(he));
2002 }
2003 break;
2004 case FONT_FAMILY_SERIF:
2005 *ptr += sprintf(*ptr, "serif");
2006 break;
2008 *ptr += sprintf(*ptr, "sans-serif");
2009 break;
2011 *ptr += sprintf(*ptr, "cursive");
2012 break;
2014 *ptr += sprintf(*ptr, "fantasy");
2015 break;
2017 *ptr += sprintf(*ptr, "monospace");
2018 break;
2019 }
2020
2021 value = *((uint32_t *) bytecode);
2022 ADVANCE(sizeof(value));
2023
2024 if (value != FONT_FAMILY_END)
2025 *ptr += sprintf(*ptr, ", ");
2026 }
2027 break;
2028 case CSS_PROP_FONT_SIZE:
2029 switch (value) {
2031 {
2032 uint32_t unit;
2033 css_fixed val = *((css_fixed *) bytecode);
2034 ADVANCE(sizeof(val));
2035 unit = *((uint32_t *) bytecode);
2036 ADVANCE(sizeof(unit));
2037 dump_unit(val, unit, ptr);
2038 }
2039 break;
2040 case FONT_SIZE_XX_SMALL:
2041 *ptr += sprintf(*ptr, "xx-small");
2042 break;
2043 case FONT_SIZE_X_SMALL:
2044 *ptr += sprintf(*ptr, "x-small");
2045 break;
2046 case FONT_SIZE_SMALL:
2047 *ptr += sprintf(*ptr, "small");
2048 break;
2049 case FONT_SIZE_MEDIUM:
2050 *ptr += sprintf(*ptr, "medium");
2051 break;
2052 case FONT_SIZE_LARGE:
2053 *ptr += sprintf(*ptr, "large");
2054 break;
2055 case FONT_SIZE_X_LARGE:
2056 *ptr += sprintf(*ptr, "x-large");
2057 break;
2058 case FONT_SIZE_XX_LARGE:
2059 *ptr += sprintf(*ptr, "xx-large");
2060 break;
2061 case FONT_SIZE_LARGER:
2062 *ptr += sprintf(*ptr, "larger");
2063 break;
2064 case FONT_SIZE_SMALLER:
2065 *ptr += sprintf(*ptr, "smaller");
2066 break;
2067 }
2068 break;
2070 switch (value) {
2071 case FONT_STYLE_NORMAL:
2072 *ptr += sprintf(*ptr, "normal");
2073 break;
2074 case FONT_STYLE_ITALIC:
2075 *ptr += sprintf(*ptr, "italic");
2076 break;
2077 case FONT_STYLE_OBLIQUE:
2078 *ptr += sprintf(*ptr, "oblique");
2079 break;
2080 }
2081 break;
2083 switch (value) {
2085 *ptr += sprintf(*ptr, "normal");
2086 break;
2088 *ptr += sprintf(*ptr, "small-caps");
2089 break;
2090 }
2091 break;
2093 switch (value) {
2094 case FONT_WEIGHT_NORMAL:
2095 *ptr += sprintf(*ptr, "normal");
2096 break;
2097 case FONT_WEIGHT_BOLD:
2098 *ptr += sprintf(*ptr, "bold");
2099 break;
2100 case FONT_WEIGHT_BOLDER:
2101 *ptr += sprintf(*ptr, "bolder");
2102 break;
2104 *ptr += sprintf(*ptr, "lighter");
2105 break;
2106 case FONT_WEIGHT_100:
2107 *ptr += sprintf(*ptr, "100");
2108 break;
2109 case FONT_WEIGHT_200:
2110 *ptr += sprintf(*ptr, "200");
2111 break;
2112 case FONT_WEIGHT_300:
2113 *ptr += sprintf(*ptr, "300");
2114 break;
2115 case FONT_WEIGHT_400:
2116 *ptr += sprintf(*ptr, "400");
2117 break;
2118 case FONT_WEIGHT_500:
2119 *ptr += sprintf(*ptr, "500");
2120 break;
2121 case FONT_WEIGHT_600:
2122 *ptr += sprintf(*ptr, "600");
2123 break;
2124 case FONT_WEIGHT_700:
2125 *ptr += sprintf(*ptr, "700");
2126 break;
2127 case FONT_WEIGHT_800:
2128 *ptr += sprintf(*ptr, "800");
2129 break;
2130 case FONT_WEIGHT_900:
2131 *ptr += sprintf(*ptr, "900");
2132 break;
2133 }
2134 break;
2136 switch (value) {
2138 *ptr += sprintf(*ptr, "flex-start");
2139 break;
2141 *ptr += sprintf(*ptr, "flex-end");
2142 break;
2144 *ptr += sprintf(*ptr, "center");
2145 break;
2147 *ptr += sprintf(*ptr, "space-between");
2148 break;
2150 *ptr += sprintf(*ptr, "space-around");
2151 break;
2153 *ptr += sprintf(*ptr, "space-evenly");
2154 break;
2155 }
2156 break;
2157
2161 (enum op_letter_spacing)
2164 (enum op_letter_spacing)
2166
2167 switch (value) {
2168 case LETTER_SPACING_SET:
2169 {
2170 uint32_t unit;
2171 css_fixed val = *((css_fixed *) bytecode);
2172 ADVANCE(sizeof(val));
2173 unit = *((uint32_t *) bytecode);
2174 ADVANCE(sizeof(unit));
2175 dump_unit(val, unit, ptr);
2176 }
2177 break;
2179 *ptr += sprintf(*ptr, "normal");
2180 break;
2181 }
2182 break;
2184 switch (value) {
2185 case LINE_HEIGHT_NUMBER:
2186 {
2187 css_fixed val = *((css_fixed *) bytecode);
2188 ADVANCE(sizeof(val));
2189 dump_number(val, ptr);
2190 }
2191 break;
2193 {
2194 uint32_t unit;
2195 css_fixed val = *((css_fixed *) bytecode);
2196 ADVANCE(sizeof(val));
2197 unit = *((uint32_t *) bytecode);
2198 ADVANCE(sizeof(unit));
2199 dump_unit(val, unit, ptr);
2200 }
2201 break;
2202 case LINE_HEIGHT_NORMAL:
2203 *ptr += sprintf(*ptr, "normal");
2204 break;
2205 }
2206 break;
2208 switch (value) {
2210 *ptr += sprintf(*ptr, "inside");
2211 break;
2213 *ptr += sprintf(*ptr, "outside");
2214 break;
2215 }
2216 break;
2218 switch (value) {
2220 *ptr += sprintf(*ptr, "disc");
2221 break;
2223 *ptr += sprintf(*ptr, "circle");
2224 break;
2226 *ptr += sprintf(*ptr, "square");
2227 break;
2229 *ptr += sprintf(*ptr, "decimal");
2230 break;
2232 *ptr += sprintf(*ptr, "decimal-leading-zero");
2233 break;
2235 *ptr += sprintf(*ptr, "lower-roman");
2236 break;
2238 *ptr += sprintf(*ptr, "upper-roman");
2239 break;
2241 *ptr += sprintf(*ptr, "lower-greek");
2242 break;
2244 *ptr += sprintf(*ptr, "lower-latin");
2245 break;
2247 *ptr += sprintf(*ptr, "upper-latin");
2248 break;
2250 *ptr += sprintf(*ptr, "armenian");
2251 break;
2253 *ptr += sprintf(*ptr, "georgian");
2254 break;
2256 *ptr += sprintf(*ptr, "lower-alpha");
2257 break;
2259 *ptr += sprintf(*ptr, "upper-alpha");
2260 break;
2262 *ptr += sprintf(*ptr, "none");
2263 break;
2264 }
2265 break;
2267 case CSS_PROP_MAX_WIDTH:
2269 (enum op_max_height)
2272 (enum op_max_height)
2274
2275 switch (value) {
2276 case MAX_HEIGHT_SET:
2277 {
2278 uint32_t unit;
2279 css_fixed val = *((css_fixed *) bytecode);
2280 ADVANCE(sizeof(val));
2281 unit = *((uint32_t *) bytecode);
2282 ADVANCE(sizeof(unit));
2283 dump_unit(val, unit, ptr);
2284 }
2285 break;
2286 case MAX_HEIGHT_NONE:
2287 *ptr += sprintf(*ptr, "none");
2288 break;
2289 }
2290 break;
2292 case CSS_PROP_MIN_WIDTH:
2294 (enum op_min_height)
2297 (enum op_min_height)
2299
2300 switch (value) {
2301 case MIN_HEIGHT_SET:
2302 {
2303 uint32_t unit;
2304 css_fixed val = *((css_fixed *) bytecode);
2305 ADVANCE(sizeof(val));
2306 unit = *((uint32_t *) bytecode);
2307 ADVANCE(sizeof(unit));
2308 dump_unit(val, unit, ptr);
2309 }
2310 break;
2311 case MIN_HEIGHT_AUTO:
2312 *ptr += sprintf(*ptr, "auto");
2313 break;
2314 }
2315 break;
2316 case CSS_PROP_OPACITY:
2317 switch (value) {
2318 case OPACITY_SET:
2319 {
2320 css_fixed val = *((css_fixed *) bytecode);
2321 ADVANCE(sizeof(val));
2322 dump_number(val, ptr);
2323 }
2324 break;
2325 }
2326 break;
2327 case CSS_PROP_ORDER:
2328 switch (value) {
2329 case ORDER_SET:
2330 {
2331 css_fixed val = *((css_fixed *) bytecode);
2332 ADVANCE(sizeof(val));
2333 dump_number(val, ptr);
2334 }
2335 break;
2336 }
2337 break;
2346 (enum op_text_indent)
2347 PADDING_SET);
2349 (enum op_text_indent)
2352 (enum op_text_indent)
2354
2355 switch (value) {
2356 case TEXT_INDENT_SET:
2357 {
2358 uint32_t unit;
2359 css_fixed val = *((css_fixed *) bytecode);
2360 ADVANCE(sizeof(val));
2361 unit = *((uint32_t *) bytecode);
2362 ADVANCE(sizeof(unit));
2363 dump_unit(val, unit, ptr);
2364 }
2365 break;
2366 }
2367 break;
2368 case CSS_PROP_ORPHANS:
2370 case CSS_PROP_RICHNESS:
2371 case CSS_PROP_STRESS:
2372 case CSS_PROP_WIDOWS:
2374 (enum op_orphans)
2377 (enum op_orphans)
2378 RICHNESS_SET);
2380 (enum op_orphans)
2381 STRESS_SET);
2383 (enum op_orphans)
2384 WIDOWS_SET);
2385
2386 switch (value) {
2387 case ORPHANS_SET:
2388 {
2389 css_fixed val = *((css_fixed *) bytecode);
2390 ADVANCE(sizeof(val));
2391 dump_number(val, ptr);
2392 }
2393 break;
2394 }
2395 break;
2397 switch (value) {
2399 *ptr += sprintf(*ptr, "transparent");
2400 break;
2402 *ptr += sprintf(*ptr, "currentColor");
2403 break;
2404 case OUTLINE_COLOR_SET:
2405 {
2406 uint32_t colour =
2407 *((uint32_t *) bytecode);
2408 ADVANCE(sizeof(colour));
2409 *ptr += sprintf(*ptr, "#%08x", colour);
2410 }
2411 break;
2413 *ptr += sprintf(*ptr, "invert");
2414 break;
2415 }
2416 break;
2419 switch (value) {
2420 case OVERFLOW_VISIBLE:
2421 *ptr += sprintf(*ptr, "visible");
2422 break;
2423 case OVERFLOW_HIDDEN:
2424 *ptr += sprintf(*ptr, "hidden");
2425 break;
2426 case OVERFLOW_SCROLL:
2427 *ptr += sprintf(*ptr, "scroll");
2428 break;
2429 case OVERFLOW_AUTO:
2430 *ptr += sprintf(*ptr, "auto");
2431 break;
2432 }
2433 break;
2437 (enum op_page_break_after)
2440 (enum op_page_break_after)
2443 (enum op_page_break_after)
2446 (enum op_page_break_after)
2449 (enum op_page_break_after)
2451
2452 switch (value) {
2454 *ptr += sprintf(*ptr, "auto");
2455 break;
2457 *ptr += sprintf(*ptr, "always");
2458 break;
2460 *ptr += sprintf(*ptr, "avoid");
2461 break;
2463 *ptr += sprintf(*ptr, "left");
2464 break;
2466 *ptr += sprintf(*ptr, "right");
2467 break;
2468 }
2469 break;
2471 switch (value) {
2473 *ptr += sprintf(*ptr, "auto");
2474 break;
2476 *ptr += sprintf(*ptr, "avoid");
2477 break;
2478 }
2479 break;
2480 case CSS_PROP_PITCH:
2481 switch (value) {
2482 case PITCH_FREQUENCY:
2483 {
2484 uint32_t unit;
2485 css_fixed val = *((css_fixed *) bytecode);
2486 ADVANCE(sizeof(val));
2487 unit = *((uint32_t *) bytecode);
2488 ADVANCE(sizeof(unit));
2489 dump_unit(val, unit, ptr);
2490 }
2491 break;
2492 case PITCH_X_LOW:
2493 *ptr += sprintf(*ptr, "x-low");
2494 break;
2495 case PITCH_LOW:
2496 *ptr += sprintf(*ptr, "low");
2497 break;
2498 case PITCH_MEDIUM:
2499 *ptr += sprintf(*ptr, "medium");
2500 break;
2501 case PITCH_HIGH:
2502 *ptr += sprintf(*ptr, "high");
2503 break;
2504 case PITCH_X_HIGH:
2505 *ptr += sprintf(*ptr, "x-high");
2506 break;
2507 }
2508 break;
2510 switch (value) {
2511 case PLAY_DURING_URI:
2512 {
2513 uint32_t snum = *((uint32_t *) bytecode);
2514 lwc_string *he;
2515 css__stylesheet_string_get(style->sheet, snum, &he);
2516 ADVANCE(sizeof(snum));
2517 *ptr += sprintf(*ptr, "'%.*s'",
2518 (int) lwc_string_length(he),
2519 lwc_string_data(he));
2520 }
2521 break;
2522 case PLAY_DURING_AUTO:
2523 *ptr += sprintf(*ptr, "auto");
2524 break;
2525 case PLAY_DURING_NONE:
2526 *ptr += sprintf(*ptr, "none");
2527 break;
2528 }
2529
2530 if (value & PLAY_DURING_MIX)
2531 *ptr += sprintf(*ptr, " mix");
2532 if (value & PLAY_DURING_REPEAT)
2533 *ptr += sprintf(*ptr, " repeat");
2534 break;
2535 case CSS_PROP_POSITION:
2536 switch (value) {
2537 case POSITION_STATIC:
2538 *ptr += sprintf(*ptr, "static");
2539 break;
2540 case POSITION_RELATIVE:
2541 *ptr += sprintf(*ptr, "relative");
2542 break;
2543 case POSITION_ABSOLUTE:
2544 *ptr += sprintf(*ptr, "absolute");
2545 break;
2546 case POSITION_FIXED:
2547 *ptr += sprintf(*ptr, "fixed");
2548 break;
2549 }
2550 break;
2551 case CSS_PROP_QUOTES:
2552 switch (value) {
2553 case QUOTES_STRING:
2554 while (value != QUOTES_NONE) {
2555 uint32_t snum = *((uint32_t *) bytecode);
2556 lwc_string *he;
2557 css__stylesheet_string_get(style->sheet, snum, &he);
2558 ADVANCE(sizeof(snum));
2559 *ptr += sprintf(*ptr, " '%.*s' ",
2560 (int) lwc_string_length(he),
2561 lwc_string_data(he));
2562
2563 css__stylesheet_string_get(style->sheet, snum, &he);
2564 ADVANCE(sizeof(he));
2565 *ptr += sprintf(*ptr, " '%.*s' ",
2566 (int) lwc_string_length(he),
2567 lwc_string_data(he));
2568
2569 value = *((uint32_t *) bytecode);
2570 ADVANCE(sizeof(value));
2571 }
2572 break;
2573 case QUOTES_NONE:
2574 *ptr += sprintf(*ptr, "none");
2575 break;
2576 }
2577 break;
2579 switch (value) {
2580 case SPEAK_HEADER_ONCE:
2581 *ptr += sprintf(*ptr, "once");
2582 break;
2584 *ptr += sprintf(*ptr, "always");
2585 break;
2586 }
2587 break;
2589 switch (value) {
2591 *ptr += sprintf(*ptr, "digits");
2592 break;
2594 *ptr += sprintf(*ptr, "continuous");
2595 break;
2596 }
2597 break;
2599 switch (value) {
2601 *ptr += sprintf(*ptr, "code");
2602 break;
2604 *ptr += sprintf(*ptr, "none");
2605 break;
2606 }
2607 break;
2608 case CSS_PROP_SPEAK:
2609 switch (value) {
2610 case SPEAK_NORMAL:
2611 *ptr += sprintf(*ptr, "normal");
2612 break;
2613 case SPEAK_NONE:
2614 *ptr += sprintf(*ptr, "none");
2615 break;
2616 case SPEAK_SPELL_OUT:
2617 *ptr += sprintf(*ptr, "spell-out");
2618 break;
2619 }
2620 break;
2622 switch (value) {
2623 case SPEECH_RATE_SET:
2624 {
2625 css_fixed val = *((css_fixed *) bytecode);
2626 ADVANCE(sizeof(val));
2627 dump_number(val, ptr);
2628 }
2629 break;
2630 case SPEECH_RATE_X_SLOW:
2631 *ptr += sprintf(*ptr, "x-slow");
2632 break;
2633 case SPEECH_RATE_SLOW:
2634 *ptr += sprintf(*ptr, "slow");
2635 break;
2636 case SPEECH_RATE_MEDIUM:
2637 *ptr += sprintf(*ptr, "medium");
2638 break;
2639 case SPEECH_RATE_FAST:
2640 *ptr += sprintf(*ptr, "fast");
2641 break;
2642 case SPEECH_RATE_X_FAST:
2643 *ptr += sprintf(*ptr, "x-fast");
2644 break;
2645 case SPEECH_RATE_FASTER:
2646 *ptr += sprintf(*ptr, "faster");
2647 break;
2648 case SPEECH_RATE_SLOWER:
2649 *ptr += sprintf(*ptr, "slower");
2650 break;
2651 }
2652 break;
2654 switch (value) {
2655 case TABLE_LAYOUT_AUTO:
2656 *ptr += sprintf(*ptr, "auto");
2657 break;
2658 case TABLE_LAYOUT_FIXED:
2659 *ptr += sprintf(*ptr, "fixed");
2660 break;
2661 }
2662 break;
2664 switch (value) {
2665 case TEXT_ALIGN_LEFT:
2666 *ptr += sprintf(*ptr, "left");
2667 break;
2668 case TEXT_ALIGN_RIGHT:
2669 *ptr += sprintf(*ptr, "right");
2670 break;
2671 case TEXT_ALIGN_CENTER:
2672 *ptr += sprintf(*ptr, "center");
2673 break;
2674 case TEXT_ALIGN_JUSTIFY:
2675 *ptr += sprintf(*ptr, "justify");
2676 break;
2678 *ptr += sprintf(*ptr, "-libcss-left");
2679 break;
2681 *ptr += sprintf(*ptr, "-libcss-center");
2682 break;
2684 *ptr += sprintf(*ptr, "-libcss-right");
2685 break;
2686 }
2687 break;
2689 if (value == TEXT_DECORATION_NONE)
2690 *ptr += sprintf(*ptr, "none");
2691
2692 if (value & TEXT_DECORATION_UNDERLINE)
2693 *ptr += sprintf(*ptr, " underline");
2694 if (value & TEXT_DECORATION_OVERLINE)
2695 *ptr += sprintf(*ptr, " overline");
2696 if (value & TEXT_DECORATION_LINE_THROUGH)
2697 *ptr += sprintf(*ptr, " line-through");
2698 if (value & TEXT_DECORATION_BLINK)
2699 *ptr += sprintf(*ptr, " blink");
2700 break;
2702 switch (value) {
2704 *ptr += sprintf(*ptr, "capitalize");
2705 break;
2707 *ptr += sprintf(*ptr, "uppercase");
2708 break;
2710 *ptr += sprintf(*ptr, "lowercase");
2711 break;
2713 *ptr += sprintf(*ptr, "none");
2714 break;
2715 }
2716 break;
2718 switch (value) {
2720 *ptr += sprintf(*ptr, "normal");
2721 break;
2722 case UNICODE_BIDI_EMBED:
2723 *ptr += sprintf(*ptr, "embed");
2724 break;
2726 *ptr += sprintf(*ptr, "bidi-override");
2727 break;
2728 }
2729 break;
2731 switch (value) {
2732 case VERTICAL_ALIGN_SET:
2733 {
2734 uint32_t unit;
2735 css_fixed val = *((css_fixed *) bytecode);
2736 ADVANCE(sizeof(val));
2737 unit = *((uint32_t *) bytecode);
2738 ADVANCE(sizeof(unit));
2739 dump_unit(val, unit, ptr);
2740 }
2741 break;
2743 *ptr += sprintf(*ptr, "baseline");
2744 break;
2745 case VERTICAL_ALIGN_SUB:
2746 *ptr += sprintf(*ptr, "sub");
2747 break;
2749 *ptr += sprintf(*ptr, "super");
2750 break;
2751 case VERTICAL_ALIGN_TOP:
2752 *ptr += sprintf(*ptr, "top");
2753 break;
2755 *ptr += sprintf(*ptr, "text-top");
2756 break;
2758 *ptr += sprintf(*ptr, "middle");
2759 break;
2761 *ptr += sprintf(*ptr, "bottom");
2762 break;
2764 *ptr += sprintf(*ptr, "text-bottom");
2765 break;
2766 }
2767 break;
2769 switch (value) {
2770 case VISIBILITY_VISIBLE:
2771 *ptr += sprintf(*ptr, "visible");
2772 break;
2773 case VISIBILITY_HIDDEN:
2774 *ptr += sprintf(*ptr, "hidden");
2775 break;
2777 *ptr += sprintf(*ptr, "collapse");
2778 break;
2779 }
2780 break;
2782 while (value != VOICE_FAMILY_END) {
2783 switch (value) {
2786 {
2787 uint32_t snum = *((uint32_t *) bytecode);
2788 lwc_string *he;
2789 css__stylesheet_string_get(style->sheet, snum, &he);
2790 ADVANCE(sizeof(snum));
2791 *ptr += sprintf(*ptr, "'%.*s'",
2792 (int) lwc_string_length(he),
2793 lwc_string_data(he));
2794 }
2795 break;
2796 case VOICE_FAMILY_MALE:
2797 *ptr += sprintf(*ptr, "male");
2798 break;
2800 *ptr += sprintf(*ptr, "female");
2801 break;
2802 case VOICE_FAMILY_CHILD:
2803 *ptr += sprintf(*ptr, "child");
2804 break;
2805 }
2806
2807 value = *((uint32_t *) bytecode);
2808 ADVANCE(sizeof(value));
2809
2810 if (value != VOICE_FAMILY_END)
2811 *ptr += sprintf(*ptr, ", ");
2812 }
2813 break;
2814 case CSS_PROP_VOLUME:
2815 switch (value) {
2816 case VOLUME_NUMBER:
2817 {
2818 css_fixed val = *((css_fixed *) bytecode);
2819 ADVANCE(sizeof(val));
2820 dump_number(val, ptr);
2821 }
2822 break;
2823 case VOLUME_DIMENSION:
2824 {
2825 uint32_t unit;
2826 css_fixed val = *((css_fixed *) bytecode);
2827 ADVANCE(sizeof(val));
2828 unit = *((uint32_t *) bytecode);
2829 ADVANCE(sizeof(unit));
2830 dump_unit(val, unit, ptr);
2831 }
2832 break;
2833 case VOLUME_SILENT:
2834 *ptr += sprintf(*ptr, "silent");
2835 break;
2836 case VOLUME_X_SOFT:
2837 *ptr += sprintf(*ptr, "x-soft");
2838 break;
2839 case VOLUME_SOFT:
2840 *ptr += sprintf(*ptr, "soft");
2841 break;
2842 case VOLUME_MEDIUM:
2843 *ptr += sprintf(*ptr, "medium");
2844 break;
2845 case VOLUME_LOUD:
2846 *ptr += sprintf(*ptr, "loud");
2847 break;
2848 case VOLUME_X_LOUD:
2849 *ptr += sprintf(*ptr, "x-loud");
2850 break;
2851 }
2852 break;
2854 switch (value) {
2855 case WHITE_SPACE_NORMAL:
2856 *ptr += sprintf(*ptr, "normal");
2857 break;
2858 case WHITE_SPACE_PRE:
2859 *ptr += sprintf(*ptr, "pre");
2860 break;
2861 case WHITE_SPACE_NOWRAP:
2862 *ptr += sprintf(*ptr, "nowrap");
2863 break;
2865 *ptr += sprintf(*ptr, "pre-wrap");
2866 break;
2868 *ptr += sprintf(*ptr, "pre-line");
2869 break;
2870 }
2871 break;
2873 switch (value) {
2875 *ptr += sprintf(*ptr, "horizontal-tb");
2876 break;
2878 *ptr += sprintf(*ptr, "vertical-rl");
2879 break;
2881 *ptr += sprintf(*ptr, "vertical-lr");
2882 break;
2883 }
2884 break;
2885 case CSS_PROP_Z_INDEX:
2886 switch (value) {
2887 case Z_INDEX_SET:
2888 {
2889 css_fixed val = *((css_fixed *) bytecode);
2890 ADVANCE(sizeof(val));
2891 dump_number(val, ptr);
2892 }
2893 break;
2894 case Z_INDEX_AUTO:
2895 *ptr += sprintf(*ptr, "auto");
2896 break;
2897 }
2898 break;
2899 default:
2900 *ptr += sprintf(*ptr, "Unknown opcode %x", op);
2901 return;
2902 }
2903 }
2904
2905 if (isImportant(opv))
2906 *ptr += sprintf(*ptr, " !important");
2907
2908 *ptr += sprintf(*ptr, "\n");
2909 }
2910
2911#undef ADVANCE
2912
2913}
2914
2915void dump_string(lwc_string *string, char **ptr)
2916{
2917 *ptr += sprintf(*ptr, "%.*s",
2918 (int) lwc_string_length(string),
2919 lwc_string_data(string));
2920}
2921
2922void dump_font_face(css_font_face *font_face, char **ptr)
2923{
2924 uint8_t style, weight;
2925
2926 if (font_face->font_family != NULL) {
2927 *(*ptr)++ = '\n';
2928 *ptr += sprintf(*ptr, "| font-family: %.*s",
2929 (int) lwc_string_length(font_face->font_family),
2930 lwc_string_data(font_face->font_family));
2931 }
2932
2933 *ptr += sprintf(*ptr, "\n| font-style: ");
2934 style = css_font_face_font_style(font_face);
2935 switch (style) {
2937 *ptr += sprintf(*ptr, "unspecified");
2938 break;
2940 *ptr += sprintf(*ptr, "normal");
2941 break;
2943 *ptr += sprintf(*ptr, "italic");
2944 break;
2946 *ptr += sprintf(*ptr, "oblique");
2947 break;
2948 }
2949
2950 *ptr += sprintf(*ptr, "\n| font-weight: ");
2951 weight = css_font_face_font_weight(font_face);
2952 switch (weight) {
2954 *ptr += sprintf(*ptr, "unspecified");
2955 break;
2957 *ptr += sprintf(*ptr, "normal");
2958 break;
2960 *ptr += sprintf(*ptr, "bold");
2961 break;
2963 *ptr += sprintf(*ptr, "100");
2964 break;
2966 *ptr += sprintf(*ptr, "200");
2967 break;
2969 *ptr += sprintf(*ptr, "300");
2970 break;
2972 *ptr += sprintf(*ptr, "400");
2973 break;
2975 *ptr += sprintf(*ptr, "500");
2976 break;
2978 *ptr += sprintf(*ptr, "600");
2979 break;
2981 *ptr += sprintf(*ptr, "700");
2982 break;
2984 *ptr += sprintf(*ptr, "800");
2985 break;
2987 *ptr += sprintf(*ptr, "900");
2988 break;
2989 default:
2990 *ptr += sprintf(*ptr, "Unhandled weight %d\n", (int)weight);
2991 break;
2992 }
2993
2994
2995 if (font_face->srcs != NULL) {
2996 uint32_t i;
2997 css_font_face_src *srcs = font_face->srcs;
2998 for (i = 0; i < font_face->n_srcs; ++i) {
2999 css_font_face_format format;
3000 *ptr += sprintf(*ptr, "\n| src: ");
3001
3002 format = css_font_face_src_format(&srcs[i]);
3003
3004 *ptr += sprintf(*ptr, "\n| format: ");
3005
3006 switch (format) {
3008 *ptr += sprintf(*ptr, "unspecified");
3009 break;
3011 *ptr += sprintf(*ptr, "WOFF");
3012 break;
3014 *ptr += sprintf(*ptr, "OTF");
3015 break;
3017 *ptr += sprintf(*ptr, "EOTF");
3018 break;
3020 *ptr += sprintf(*ptr, "SVG");
3021 break;
3023 *ptr += sprintf(*ptr, "unknown");
3024 break;
3025 default:
3026 *ptr += sprintf(*ptr, "UNEXPECTED");
3027 break;
3028 }
3029
3030 if (srcs[i].location != NULL) {
3031 *ptr += sprintf(*ptr, "\n| location: ");
3032
3034 &srcs[i])) {
3036 *ptr += sprintf(*ptr, "local");
3037 break;
3039 *ptr += sprintf(*ptr, "url");
3040 break;
3041 default:
3042 *ptr += sprintf(*ptr, "UNKNOWN");
3043 break;
3044 }
3045
3046 *ptr += sprintf(*ptr, "(%.*s)",
3047 (int) lwc_string_length(
3048 srcs[i].location),
3049 lwc_string_data(srcs[i].location));
3050 }
3051 }
3052 }
3053}
3054
3055#endif
uint32_t colour
Definition bytecode.h:96
unit
Definition bytecode.h:49
@ UNIT_VW
Definition bytecode.h:63
@ UNIT_CH
Definition bytecode.h:59
@ UNIT_GRAD
Definition bytecode.h:74
@ UNIT_PCT
Definition bytecode.h:70
@ UNIT_PT
Definition bytecode.h:57
@ UNIT_Q
Definition bytecode.h:68
@ UNIT_VB
Definition bytecode.h:65
@ UNIT_KHZ
Definition bytecode.h:84
@ UNIT_VMIN
Definition bytecode.h:66
@ UNIT_CALC_NUMBER
Definition bytecode.h:93
@ UNIT_S
Definition bytecode.h:80
@ UNIT_CM
Definition bytecode.h:55
@ UNIT_REM
Definition bytecode.h:60
@ UNIT_IN
Definition bytecode.h:54
@ UNIT_EX
Definition bytecode.h:52
@ UNIT_MM
Definition bytecode.h:56
@ UNIT_HZ
Definition bytecode.h:83
@ UNIT_VMAX
Definition bytecode.h:67
@ UNIT_CALC_ANY
Definition bytecode.h:92
@ UNIT_DEG
Definition bytecode.h:73
@ UNIT_PC
Definition bytecode.h:58
@ UNIT_EM
Definition bytecode.h:53
@ UNIT_PX
Definition bytecode.h:51
@ UNIT_VI
Definition bytecode.h:64
@ UNIT_RAD
Definition bytecode.h:75
@ UNIT_LH
Definition bytecode.h:61
@ UNIT_VH
Definition bytecode.h:62
@ UNIT_MS
Definition bytecode.h:79
@ FLAG_VALUE_INHERIT
Definition bytecode.h:25
@ FLAG_VALUE_REVERT
Definition bytecode.h:27
@ FLAG_VALUE_INITIAL
Definition bytecode.h:26
@ FLAG_VALUE_UNSET
Definition bytecode.h:28
uint32_t css_code_t
Definition bytecode.h:19
@ CALC_PUSH_VALUE
Definition bytecode.h:41
@ CALC_FINISH
Definition bytecode.h:46
@ CALC_ADD
Definition bytecode.h:42
@ CALC_MULTIPLY
Definition bytecode.h:44
@ CALC_DIVIDE
Definition bytecode.h:45
@ CALC_PUSH_NUMBER
Definition bytecode.h:40
@ CALC_SUBTRACT
Definition bytecode.h:43
enum css_properties_e opcode_t
Definition bytecode.h:21
#define ADVANCE(n)
#define ABS(x)
#define INTTOFIX(a)
Definition fpmath.h:127
#define FIXTOINT(a)
Definition fpmath.h:129
int32_t css_fixed
Definition fpmath.h:23
css_font_face_format
Definition font_face.h:24
@ CSS_FONT_FACE_FORMAT_EMBEDDED_OPENTYPE
Definition font_face.h:31
@ CSS_FONT_FACE_FORMAT_WOFF
Definition font_face.h:27
@ CSS_FONT_FACE_FORMAT_SVG
Definition font_face.h:33
@ CSS_FONT_FACE_FORMAT_UNSPECIFIED
Definition font_face.h:25
@ CSS_FONT_FACE_FORMAT_UNKNOWN
Definition font_face.h:36
@ CSS_FONT_FACE_FORMAT_OPENTYPE
Definition font_face.h:29
@ CSS_FONT_FACE_LOCATION_TYPE_URI
Definition font_face.h:52
@ CSS_FONT_FACE_LOCATION_TYPE_LOCAL
Definition font_face.h:51
css_font_face_format css_font_face_src_format(const css_font_face_src *src)
Definition font_face.c:223
css_font_face_location_type css_font_face_src_location_type(const css_font_face_src *src)
Definition font_face.c:211
uint8_t css_font_face_font_style(const css_font_face *font_face)
Definition font_face.c:128
uint8_t css_font_face_font_weight(const css_font_face *font_face)
Definition font_face.c:139
@ CSS_FONT_STYLE_OBLIQUE
Definition properties.h:528
@ CSS_FONT_STYLE_ITALIC
Definition properties.h:527
@ CSS_FONT_STYLE_NORMAL
Definition properties.h:526
@ CSS_FONT_STYLE_INHERIT
Definition properties.h:525
@ CSS_FONT_WEIGHT_500
Definition properties.h:547
@ CSS_FONT_WEIGHT_100
Definition properties.h:543
@ CSS_FONT_WEIGHT_600
Definition properties.h:548
@ CSS_FONT_WEIGHT_300
Definition properties.h:545
@ CSS_FONT_WEIGHT_700
Definition properties.h:549
@ CSS_FONT_WEIGHT_INHERIT
Definition properties.h:538
@ CSS_FONT_WEIGHT_800
Definition properties.h:550
@ CSS_FONT_WEIGHT_200
Definition properties.h:544
@ CSS_FONT_WEIGHT_NORMAL
Definition properties.h:539
@ CSS_FONT_WEIGHT_400
Definition properties.h:546
@ CSS_FONT_WEIGHT_900
Definition properties.h:551
@ CSS_FONT_WEIGHT_BOLD
Definition properties.h:540
@ CSS_PROP_LIST_STYLE_TYPE
Definition properties.h:64
@ CSS_PROP_COLUMN_WIDTH
Definition properties.h:127
@ CSS_PROP_PADDING_RIGHT
Definition properties.h:79
@ CSS_PROP_ELEVATION
Definition properties.h:50
@ CSS_PROP_ORPHANS
Definition properties.h:73
@ CSS_PROP_MIN_HEIGHT
Definition properties.h:71
@ CSS_PROP_AZIMUTH
Definition properties.h:17
@ CSS_PROP_OUTLINE_STYLE
Definition properties.h:75
@ CSS_PROP_FONT_VARIANT
Definition properties.h:56
@ CSS_PROP_BOTTOM
Definition properties.h:37
@ CSS_PROP_WRITING_MODE
Definition properties.h:128
@ CSS_PROP_PADDING_TOP
Definition properties.h:78
@ CSS_PROP_COLUMN_RULE_COLOR
Definition properties.h:123
@ CSS_PROP_BORDER_LEFT_COLOR
Definition properties.h:28
@ CSS_PROP_OUTLINE_WIDTH
Definition properties.h:76
@ CSS_PROP_CUE_BEFORE
Definition properties.h:46
@ CSS_PROP_BREAK_INSIDE
Definition properties.h:119
@ CSS_PROP_WORD_SPACING
Definition properties.h:114
@ CSS_PROP_PITCH
Definition properties.h:88
@ CSS_PROP_CLEAR
Definition properties.h:39
@ CSS_PROP_ORDER
Definition properties.h:140
@ CSS_PROP_UNICODE_BIDI
Definition properties.h:106
@ CSS_PROP_VOICE_FAMILY
Definition properties.h:109
@ CSS_PROP_LIST_STYLE_IMAGE
Definition properties.h:62
@ CSS_PROP_BORDER_COLLAPSE
Definition properties.h:23
@ CSS_PROP_COLUMN_RULE_WIDTH
Definition properties.h:125
@ CSS_PROP_HEIGHT
Definition properties.h:58
@ CSS_PROP_BORDER_RIGHT_WIDTH
Definition properties.h:34
@ CSS_PROP_CURSOR
Definition properties.h:47
@ CSS_PROP_PAGE_BREAK_INSIDE
Definition properties.h:84
@ CSS_PROP_FLEX_BASIS
Definition properties.h:134
@ CSS_PROP_TOP
Definition properties.h:105
@ CSS_PROP_COLUMN_COUNT
Definition properties.h:120
@ CSS_PROP_BORDER_SPACING
Definition properties.h:24
@ CSS_PROP_BACKGROUND_REPEAT
Definition properties.h:22
@ CSS_PROP_FONT_FAMILY
Definition properties.h:53
@ CSS_PROP_TEXT_ALIGN
Definition properties.h:101
@ CSS_PROP_STROKE_OPACITY
Definition properties.h:142
@ CSS_PROP_BREAK_AFTER
Definition properties.h:117
@ CSS_PROP_BORDER_TOP_STYLE
Definition properties.h:29
@ CSS_PROP_OUTLINE_COLOR
Definition properties.h:74
@ CSS_PROP_RIGHT
Definition properties.h:93
@ CSS_PROP_PADDING_BOTTOM
Definition properties.h:80
@ CSS_PROP_FLOAT
Definition properties.h:52
@ CSS_PROP_SPEECH_RATE
Definition properties.h:98
@ CSS_PROP_BORDER_TOP_WIDTH
Definition properties.h:33
@ CSS_PROP_MAX_WIDTH
Definition properties.h:70
@ CSS_PROP_COLUMN_SPAN
Definition properties.h:126
@ CSS_PROP_BORDER_RIGHT_STYLE
Definition properties.h:30
@ CSS_PROP_FILL_OPACITY
Definition properties.h:141
@ CSS_PROP_MAX_HEIGHT
Definition properties.h:69
@ CSS_PROP_TEXT_DECORATION
Definition properties.h:102
@ CSS_PROP_BACKGROUND_IMAGE
Definition properties.h:20
@ CSS_PROP_FONT_WEIGHT
Definition properties.h:57
@ CSS_PROP_DISPLAY
Definition properties.h:49
@ CSS_PROP_LEFT
Definition properties.h:59
@ CSS_PROP_RICHNESS
Definition properties.h:92
@ CSS_PROP_BORDER_TOP_COLOR
Definition properties.h:25
@ CSS_PROP_PITCH_RANGE
Definition properties.h:87
@ CSS_PROP_BACKGROUND_COLOR
Definition properties.h:19
@ CSS_PROP_EMPTY_CELLS
Definition properties.h:51
@ CSS_PROP_PAGE_BREAK_BEFORE
Definition properties.h:83
@ CSS_PROP_WIDTH
Definition properties.h:113
@ CSS_PROP_BORDER_LEFT_STYLE
Definition properties.h:32
@ CSS_PROP_COLUMN_FILL
Definition properties.h:121
@ CSS_PROP_ALIGN_CONTENT
Definition properties.h:131
@ CSS_PROP_COLUMN_RULE_STYLE
Definition properties.h:124
@ CSS_PROP_FONT_SIZE
Definition properties.h:54
@ CSS_PROP_BORDER_BOTTOM_WIDTH
Definition properties.h:35
@ CSS_PROP_BORDER_BOTTOM_STYLE
Definition properties.h:31
@ CSS_PROP_STRESS
Definition properties.h:99
@ CSS_PROP_FLEX_SHRINK
Definition properties.h:137
@ CSS_PROP_TEXT_TRANSFORM
Definition properties.h:104
@ CSS_PROP_BOX_SIZING
Definition properties.h:130
@ CSS_PROP_WHITE_SPACE
Definition properties.h:111
@ CSS_PROP_BREAK_BEFORE
Definition properties.h:118
@ CSS_PROP_BORDER_RIGHT_COLOR
Definition properties.h:26
@ CSS_PROP_MARGIN_RIGHT
Definition properties.h:66
@ CSS_PROP_COUNTER_RESET
Definition properties.h:44
@ CSS_PROP_OVERFLOW_Y
Definition properties.h:129
@ CSS_PROP_FONT_STYLE
Definition properties.h:55
@ CSS_PROP_CAPTION_SIDE
Definition properties.h:38
@ CSS_PROP_VERTICAL_ALIGN
Definition properties.h:107
@ CSS_PROP_OPACITY
Definition properties.h:116
@ CSS_PROP_VOLUME
Definition properties.h:110
@ CSS_PROP_LINE_HEIGHT
Definition properties.h:61
@ CSS_PROP_COUNTER_INCREMENT
Definition properties.h:43
@ CSS_PROP_MARGIN_LEFT
Definition properties.h:68
@ CSS_PROP_SPEAK_NUMERAL
Definition properties.h:95
@ CSS_PROP_PAGE_BREAK_AFTER
Definition properties.h:82
@ CSS_PROP_DIRECTION
Definition properties.h:48
@ CSS_PROP_JUSTIFY_CONTENT
Definition properties.h:139
@ CSS_PROP_TABLE_LAYOUT
Definition properties.h:100
@ CSS_PROP_LETTER_SPACING
Definition properties.h:60
@ CSS_PROP_Z_INDEX
Definition properties.h:115
@ CSS_PROP_ALIGN_ITEMS
Definition properties.h:132
@ CSS_PROP_MARGIN_TOP
Definition properties.h:65
@ CSS_PROP_MIN_WIDTH
Definition properties.h:72
@ CSS_PROP_BACKGROUND_ATTACHMENT
Definition properties.h:18
@ CSS_PROP_VISIBILITY
Definition properties.h:108
@ CSS_PROP_WIDOWS
Definition properties.h:112
@ CSS_PROP_FLEX_DIRECTION
Definition properties.h:135
@ CSS_PROP_PLAY_DURING
Definition properties.h:89
@ CSS_PROP_CUE_AFTER
Definition properties.h:45
@ CSS_PROP_CLIP
Definition properties.h:40
@ CSS_PROP_FLEX_GROW
Definition properties.h:136
@ CSS_PROP_PADDING_LEFT
Definition properties.h:81
@ CSS_PROP_PAUSE_BEFORE
Definition properties.h:86
@ CSS_PROP_OVERFLOW_X
Definition properties.h:77
@ CSS_PROP_SPEAK_PUNCTUATION
Definition properties.h:96
@ CSS_PROP_FLEX_WRAP
Definition properties.h:138
@ CSS_PROP_BORDER_LEFT_WIDTH
Definition properties.h:36
@ CSS_PROP_SPEAK
Definition properties.h:97
@ CSS_PROP_ALIGN_SELF
Definition properties.h:133
@ CSS_PROP_BORDER_BOTTOM_COLOR
Definition properties.h:27
@ CSS_PROP_COLUMN_GAP
Definition properties.h:122
@ CSS_PROP_CONTENT
Definition properties.h:42
@ CSS_PROP_MARGIN_BOTTOM
Definition properties.h:67
@ CSS_PROP_COLOR
Definition properties.h:41
@ CSS_PROP_LIST_STYLE_POSITION
Definition properties.h:63
@ CSS_PROP_QUOTES
Definition properties.h:91
@ CSS_PROP_BACKGROUND_POSITION
Definition properties.h:21
@ CSS_PROP_POSITION
Definition properties.h:90
@ CSS_PROP_SPEAK_HEADER
Definition properties.h:94
@ CSS_PROP_PAUSE_AFTER
Definition properties.h:85
@ CSS_PROP_TEXT_INDENT
Definition properties.h:103
dict style
Definition select_config.py:26
@ ELEVATION_LOWER
Definition opcodes.h:354
@ ELEVATION_LEVEL
Definition opcodes.h:351
@ ELEVATION_HIGHER
Definition opcodes.h:353
@ ELEVATION_BELOW
Definition opcodes.h:350
@ ELEVATION_ABOVE
Definition opcodes.h:352
@ ELEVATION_ANGLE
Definition opcodes.h:349
@ RIGHT_AUTO
Definition opcodes.h:718
@ RIGHT_SET
Definition opcodes.h:717
@ PADDING_SET
Definition opcodes.h:637
@ COUNTER_RESET_NONE
Definition opcodes.h:285
@ COUNTER_RESET_NAMED
Definition opcodes.h:283
@ COLUMN_SPAN_NONE
Definition opcodes.h:248
@ COLUMN_SPAN_ALL
Definition opcodes.h:249
@ COLUMN_FILL_AUTO
Definition opcodes.h:211
@ COLUMN_FILL_BALANCE
Definition opcodes.h:210
@ UNICODE_BIDI_EMBED
Definition opcodes.h:808
@ UNICODE_BIDI_NORMAL
Definition opcodes.h:807
@ UNICODE_BIDI_BIDI_OVERRIDE
Definition opcodes.h:809
@ BREAK_INSIDE_AUTO
Definition opcodes.h:167
@ BREAK_INSIDE_AVOID_PAGE
Definition opcodes.h:169
@ BREAK_INSIDE_AVOID
Definition opcodes.h:168
@ BREAK_INSIDE_AVOID_COLUMN
Definition opcodes.h:170
@ TEXT_DECORATION_UNDERLINE
Definition opcodes.h:785
@ TEXT_DECORATION_LINE_THROUGH
Definition opcodes.h:783
@ TEXT_DECORATION_NONE
Definition opcodes.h:780
@ TEXT_DECORATION_BLINK
Definition opcodes.h:782
@ TEXT_DECORATION_OVERLINE
Definition opcodes.h:784
op_text_indent
Definition opcodes.h:788
@ TEXT_INDENT_SET
Definition opcodes.h:790
@ BACKGROUND_ATTACHMENT_FIXED
Definition opcodes.h:61
@ BACKGROUND_ATTACHMENT_SCROLL
Definition opcodes.h:62
@ PITCH_RANGE_SET
Definition opcodes.h:673
@ EMPTY_CELLS_HIDE
Definition opcodes.h:359
@ EMPTY_CELLS_SHOW
Definition opcodes.h:358
@ FLEX_SHRINK_SET
Definition opcodes.h:388
@ VOICE_FAMILY_FEMALE
Definition opcodes.h:839
@ VOICE_FAMILY_STRING
Definition opcodes.h:833
@ VOICE_FAMILY_MALE
Definition opcodes.h:838
@ VOICE_FAMILY_IDENT_LIST
Definition opcodes.h:834
@ VOICE_FAMILY_END
Definition opcodes.h:836
@ VOICE_FAMILY_CHILD
Definition opcodes.h:840
@ VOLUME_DIMENSION
Definition opcodes.h:846
@ VOLUME_SOFT
Definition opcodes.h:850
@ VOLUME_MEDIUM
Definition opcodes.h:851
@ VOLUME_SILENT
Definition opcodes.h:848
@ VOLUME_LOUD
Definition opcodes.h:852
@ VOLUME_X_LOUD
Definition opcodes.h:853
@ VOLUME_NUMBER
Definition opcodes.h:845
@ VOLUME_X_SOFT
Definition opcodes.h:849
@ ALIGN_CONTENT_SPACE_AROUND
Definition opcodes.h:21
@ ALIGN_CONTENT_CENTER
Definition opcodes.h:19
@ ALIGN_CONTENT_FLEX_START
Definition opcodes.h:17
@ ALIGN_CONTENT_SPACE_BETWEEN
Definition opcodes.h:20
@ ALIGN_CONTENT_SPACE_EVENLY
Definition opcodes.h:22
@ ALIGN_CONTENT_STRETCH
Definition opcodes.h:16
@ ALIGN_CONTENT_FLEX_END
Definition opcodes.h:18
@ SPEAK_NUMERAL_CONTINUOUS
Definition opcodes.h:728
@ SPEAK_NUMERAL_DIGITS
Definition opcodes.h:727
op_min_height
Definition opcodes.h:575
@ MIN_HEIGHT_SET
Definition opcodes.h:577
@ MIN_HEIGHT_AUTO
Definition opcodes.h:578
op_background_image
Definition opcodes.h:71
@ BACKGROUND_IMAGE_NONE
Definition opcodes.h:73
@ BACKGROUND_IMAGE_URI
Definition opcodes.h:72
@ SPEAK_HEADER_ALWAYS
Definition opcodes.h:723
@ SPEAK_HEADER_ONCE
Definition opcodes.h:722
@ VERTICAL_ALIGN_TEXT_BOTTOM
Definition opcodes.h:823
@ VERTICAL_ALIGN_BASELINE
Definition opcodes.h:816
@ VERTICAL_ALIGN_SUB
Definition opcodes.h:817
@ VERTICAL_ALIGN_TEXT_TOP
Definition opcodes.h:820
@ VERTICAL_ALIGN_SET
Definition opcodes.h:814
@ VERTICAL_ALIGN_SUPER
Definition opcodes.h:818
@ VERTICAL_ALIGN_BOTTOM
Definition opcodes.h:822
@ VERTICAL_ALIGN_MIDDLE
Definition opcodes.h:821
@ VERTICAL_ALIGN_TOP
Definition opcodes.h:819
@ SPEECH_RATE_SET
Definition opcodes.h:744
@ SPEECH_RATE_SLOW
Definition opcodes.h:747
@ SPEECH_RATE_MEDIUM
Definition opcodes.h:748
@ SPEECH_RATE_X_SLOW
Definition opcodes.h:746
@ SPEECH_RATE_FASTER
Definition opcodes.h:751
@ SPEECH_RATE_X_FAST
Definition opcodes.h:750
@ SPEECH_RATE_FAST
Definition opcodes.h:749
@ SPEECH_RATE_SLOWER
Definition opcodes.h:752
@ BORDER_SPACING_SET
Definition opcodes.h:101
@ PAUSE_AFTER_SET
Definition opcodes.h:663
@ BACKGROUND_POSITION_VERT_SET
Definition opcodes.h:82
@ BACKGROUND_POSITION_VERT_CENTER
Definition opcodes.h:83
@ BACKGROUND_POSITION_HORZ_RIGHT
Definition opcodes.h:79
@ BACKGROUND_POSITION_HORZ_SET
Definition opcodes.h:77
@ BACKGROUND_POSITION_VERT_BOTTOM
Definition opcodes.h:84
@ BACKGROUND_POSITION_VERT_TOP
Definition opcodes.h:85
@ BACKGROUND_POSITION_HORZ_CENTER
Definition opcodes.h:78
@ BACKGROUND_POSITION_HORZ_LEFT
Definition opcodes.h:80
op_letter_spacing
Definition opcodes.h:479
@ LETTER_SPACING_SET
Definition opcodes.h:481
@ LETTER_SPACING_NORMAL
Definition opcodes.h:482
@ BORDER_COLOR_SET
Definition opcodes.h:107
@ BORDER_COLOR_TRANSPARENT
Definition opcodes.h:105
@ BORDER_COLOR_CURRENT_COLOR
Definition opcodes.h:106
op_border_style
Definition opcodes.h:110
@ BORDER_STYLE_DOTTED
Definition opcodes.h:113
@ BORDER_STYLE_DOUBLE
Definition opcodes.h:116
@ BORDER_STYLE_NONE
Definition opcodes.h:111
@ BORDER_STYLE_OUTSET
Definition opcodes.h:120
@ BORDER_STYLE_DASHED
Definition opcodes.h:114
@ BORDER_STYLE_GROOVE
Definition opcodes.h:117
@ BORDER_STYLE_HIDDEN
Definition opcodes.h:112
@ BORDER_STYLE_SOLID
Definition opcodes.h:115
@ BORDER_STYLE_INSET
Definition opcodes.h:119
@ BORDER_STYLE_RIDGE
Definition opcodes.h:118
@ BOX_SIZING_CONTENT_BOX
Definition opcodes.h:138
@ BOX_SIZING_BORDER_BOX
Definition opcodes.h:139
@ LIST_STYLE_TYPE_CIRCLE
Definition opcodes.h:504
@ LIST_STYLE_TYPE_LOWER_GREEK
Definition opcodes.h:510
@ LIST_STYLE_TYPE_LOWER_ALPHA
Definition opcodes.h:515
@ LIST_STYLE_TYPE_DECIMAL
Definition opcodes.h:506
@ LIST_STYLE_TYPE_UPPER_ALPHA
Definition opcodes.h:516
@ LIST_STYLE_TYPE_SQUARE
Definition opcodes.h:505
@ LIST_STYLE_TYPE_UPPER_LATIN
Definition opcodes.h:512
@ LIST_STYLE_TYPE_LOWER_ROMAN
Definition opcodes.h:508
@ LIST_STYLE_TYPE_ARMENIAN
Definition opcodes.h:513
@ LIST_STYLE_TYPE_UPPER_ROMAN
Definition opcodes.h:509
@ LIST_STYLE_TYPE_LOWER_LATIN
Definition opcodes.h:511
@ LIST_STYLE_TYPE_DISC
Definition opcodes.h:503
@ LIST_STYLE_TYPE_GEORGIAN
Definition opcodes.h:514
@ LIST_STYLE_TYPE_NONE
Definition opcodes.h:517
@ LIST_STYLE_TYPE_DECIMAL_LEADING_ZERO
Definition opcodes.h:507
@ BREAK_BEFORE_PAGE
Definition opcodes.h:160
@ BREAK_BEFORE_AVOID_PAGE
Definition opcodes.h:162
@ BREAK_BEFORE_RIGHT
Definition opcodes.h:159
@ BREAK_BEFORE_COLUMN
Definition opcodes.h:161
@ BREAK_BEFORE_AVOID_COLUMN
Definition opcodes.h:163
@ BREAK_BEFORE_LEFT
Definition opcodes.h:158
@ BREAK_BEFORE_AUTO
Definition opcodes.h:155
@ BREAK_BEFORE_AVOID
Definition opcodes.h:157
@ BREAK_BEFORE_ALWAYS
Definition opcodes.h:156
op_border_width
Definition opcodes.h:123
@ BORDER_WIDTH_MEDIUM
Definition opcodes.h:127
@ BORDER_WIDTH_THIN
Definition opcodes.h:126
@ BORDER_WIDTH_SET
Definition opcodes.h:125
@ BORDER_WIDTH_THICK
Definition opcodes.h:128
@ ALIGN_SELF_AUTO
Definition opcodes.h:39
@ ALIGN_SELF_BASELINE
Definition opcodes.h:38
@ ALIGN_SELF_FLEX_START
Definition opcodes.h:35
@ ALIGN_SELF_FLEX_END
Definition opcodes.h:36
@ ALIGN_SELF_CENTER
Definition opcodes.h:37
@ ALIGN_SELF_STRETCH
Definition opcodes.h:34
@ QUOTES_STRING
Definition opcodes.h:706
@ QUOTES_NONE
Definition opcodes.h:708
@ PLAY_DURING_AUTO
Definition opcodes.h:693
@ PLAY_DURING_URI
Definition opcodes.h:689
@ PLAY_DURING_REPEAT
Definition opcodes.h:691
@ PLAY_DURING_MIX
Definition opcodes.h:690
@ PLAY_DURING_NONE
Definition opcodes.h:694
@ TABLE_LAYOUT_AUTO
Definition opcodes.h:765
@ TABLE_LAYOUT_FIXED
Definition opcodes.h:766
@ LIST_STYLE_POSITION_INSIDE
Definition opcodes.h:498
@ LIST_STYLE_POSITION_OUTSIDE
Definition opcodes.h:499
@ HEIGHT_SET
Definition opcodes.h:460
@ HEIGHT_AUTO
Definition opcodes.h:461
@ OPACITY_SET
Definition opcodes.h:588
@ FLEX_DIRECTION_COLUMN
Definition opcodes.h:377
@ FLEX_DIRECTION_ROW
Definition opcodes.h:375
@ FLEX_DIRECTION_COLUMN_REVERSE
Definition opcodes.h:378
@ FLEX_DIRECTION_ROW_REVERSE
Definition opcodes.h:376
@ OUTLINE_WIDTH_THIN
Definition opcodes.h:623
@ OUTLINE_WIDTH_THICK
Definition opcodes.h:625
@ OUTLINE_WIDTH_MEDIUM
Definition opcodes.h:624
@ OUTLINE_WIDTH_SET
Definition opcodes.h:622
@ CAPTION_SIDE_BOTTOM
Definition opcodes.h:175
@ CAPTION_SIDE_TOP
Definition opcodes.h:174
@ COLUMN_COUNT_SET
Definition opcodes.h:206
@ COLUMN_COUNT_AUTO
Definition opcodes.h:204
@ WIDTH_SET
Definition opcodes.h:871
@ WIDTH_AUTO
Definition opcodes.h:873
@ LEFT_SET
Definition opcodes.h:475
@ LEFT_AUTO
Definition opcodes.h:476
op_max_height
Definition opcodes.h:563
@ MAX_HEIGHT_SET
Definition opcodes.h:565
@ MAX_HEIGHT_NONE
Definition opcodes.h:566
@ MIN_WIDTH_AUTO
Definition opcodes.h:584
@ MIN_WIDTH_SET
Definition opcodes.h:583
@ BORDER_COLLAPSE_COLLAPSE
Definition opcodes.h:97
@ BORDER_COLLAPSE_SEPARATE
Definition opcodes.h:96
@ Z_INDEX_SET
Definition opcodes.h:891
@ Z_INDEX_AUTO
Definition opcodes.h:893
@ OUTLINE_STYLE_DOTTED
Definition opcodes.h:611
@ OUTLINE_STYLE_DASHED
Definition opcodes.h:612
@ OUTLINE_STYLE_DOUBLE
Definition opcodes.h:614
@ OUTLINE_STYLE_RIDGE
Definition opcodes.h:616
@ OUTLINE_STYLE_HIDDEN
Definition opcodes.h:610
@ OUTLINE_STYLE_GROOVE
Definition opcodes.h:615
@ OUTLINE_STYLE_SOLID
Definition opcodes.h:613
@ OUTLINE_STYLE_NONE
Definition opcodes.h:609
@ OUTLINE_STYLE_OUTSET
Definition opcodes.h:618
@ OUTLINE_STYLE_INSET
Definition opcodes.h:617
@ LIST_STYLE_IMAGE_URI
Definition opcodes.h:493
@ LIST_STYLE_IMAGE_NONE
Definition opcodes.h:494
@ PAGE_BREAK_BEFORE_LEFT
Definition opcodes.h:652
@ PAGE_BREAK_BEFORE_ALWAYS
Definition opcodes.h:650
@ PAGE_BREAK_BEFORE_RIGHT
Definition opcodes.h:653
@ PAGE_BREAK_BEFORE_AUTO
Definition opcodes.h:649
@ PAGE_BREAK_BEFORE_AVOID
Definition opcodes.h:651
@ FLEX_WRAP_NOWRAP
Definition opcodes.h:392
@ FLEX_WRAP_WRAP
Definition opcodes.h:393
@ FLEX_WRAP_WRAP_REVERSE
Definition opcodes.h:394
@ MAX_WIDTH_SET
Definition opcodes.h:571
@ MAX_WIDTH_NONE
Definition opcodes.h:572
@ CURSOR_URI
Definition opcodes.h:299
@ CURSOR_W_RESIZE
Definition opcodes.h:313
@ CURSOR_E_RESIZE
Definition opcodes.h:306
@ CURSOR_N_RESIZE
Definition opcodes.h:309
@ CURSOR_SE_RESIZE
Definition opcodes.h:310
@ CURSOR_S_RESIZE
Definition opcodes.h:312
@ CURSOR_POINTER
Definition opcodes.h:304
@ CURSOR_AUTO
Definition opcodes.h:301
@ CURSOR_SW_RESIZE
Definition opcodes.h:311
@ CURSOR_PROGRESS
Definition opcodes.h:317
@ CURSOR_HELP
Definition opcodes.h:316
@ CURSOR_NE_RESIZE
Definition opcodes.h:307
@ CURSOR_WAIT
Definition opcodes.h:315
@ CURSOR_MOVE
Definition opcodes.h:305
@ CURSOR_DEFAULT
Definition opcodes.h:303
@ CURSOR_TEXT
Definition opcodes.h:314
@ CURSOR_CROSSHAIR
Definition opcodes.h:302
@ CURSOR_NW_RESIZE
Definition opcodes.h:308
@ TOP_AUTO
Definition opcodes.h:803
@ TOP_SET
Definition opcodes.h:802
@ WRITING_MODE_HORIZONTAL_TB
Definition opcodes.h:884
@ WRITING_MODE_VERTICAL_RL
Definition opcodes.h:885
@ WRITING_MODE_VERTICAL_LR
Definition opcodes.h:886
@ FLEX_BASIS_AUTO
Definition opcodes.h:368
@ FLEX_BASIS_CONTENT
Definition opcodes.h:369
@ FLEX_BASIS_SET
Definition opcodes.h:371
@ AZIMUTH_LEFT
Definition opcodes.h:51
@ AZIMUTH_RIGHT_SIDE
Definition opcodes.h:57
@ AZIMUTH_FAR_RIGHT
Definition opcodes.h:56
@ AZIMUTH_RIGHTWARDS
Definition opcodes.h:46
@ AZIMUTH_RIGHT
Definition opcodes.h:55
@ AZIMUTH_LEFTWARDS
Definition opcodes.h:45
@ AZIMUTH_ANGLE
Definition opcodes.h:43
@ AZIMUTH_LEFT_SIDE
Definition opcodes.h:49
@ AZIMUTH_BEHIND
Definition opcodes.h:48
@ AZIMUTH_CENTER_LEFT
Definition opcodes.h:52
@ AZIMUTH_CENTER
Definition opcodes.h:53
@ AZIMUTH_FAR_LEFT
Definition opcodes.h:50
@ AZIMUTH_CENTER_RIGHT
Definition opcodes.h:54
@ CUE_AFTER_NONE
Definition opcodes.h:290
@ CUE_AFTER_URI
Definition opcodes.h:289
@ OVERFLOW_SCROLL
Definition opcodes.h:631
@ OVERFLOW_VISIBLE
Definition opcodes.h:629
@ OVERFLOW_AUTO
Definition opcodes.h:632
@ OVERFLOW_HIDDEN
Definition opcodes.h:630
@ CLIP_RECT_BOTTOM_AUTO
Definition opcodes.h:191
@ CLIP_RECT_TOP_AUTO
Definition opcodes.h:189
@ CLIP_RECT_RIGHT_AUTO
Definition opcodes.h:190
@ CLIP_RECT_LEFT_AUTO
Definition opcodes.h:192
@ CLIP_SHAPE_RECT
Definition opcodes.h:187
@ CLIP_SHAPE_MASK
Definition opcodes.h:186
op_counter_increment
Definition opcodes.h:276
@ COUNTER_INCREMENT_NAMED
Definition opcodes.h:277
@ COUNTER_INCREMENT_NONE
Definition opcodes.h:279
@ STROKE_OPACITY_SET
Definition opcodes.h:761
@ OUTLINE_COLOR_CURRENT_COLOR
Definition opcodes.h:603
@ OUTLINE_COLOR_INVERT
Definition opcodes.h:604
@ OUTLINE_COLOR_TRANSPARENT
Definition opcodes.h:602
@ OUTLINE_COLOR_SET
Definition opcodes.h:605
@ RICHNESS_SET
Definition opcodes.h:713
@ COLUMN_GAP_NORMAL
Definition opcodes.h:215
@ COLUMN_GAP_SET
Definition opcodes.h:217
@ CUE_BEFORE_URI
Definition opcodes.h:294
@ CUE_BEFORE_NONE
Definition opcodes.h:295
@ LINE_HEIGHT_NORMAL
Definition opcodes.h:489
@ LINE_HEIGHT_DIMENSION
Definition opcodes.h:488
@ LINE_HEIGHT_NUMBER
Definition opcodes.h:487
@ FILL_OPACITY_SET
Definition opcodes.h:363
@ STRESS_SET
Definition opcodes.h:757
@ WORD_SPACING_SET
Definition opcodes.h:878
@ WORD_SPACING_NORMAL
Definition opcodes.h:880
@ COLOR_SET
Definition opcodes.h:200
@ COLOR_CURRENT_COLOR
Definition opcodes.h:199
@ COLOR_TRANSPARENT
Definition opcodes.h:198
op_orphans
Definition opcodes.h:596
@ ORPHANS_SET
Definition opcodes.h:598
@ COLUMN_WIDTH_SET
Definition opcodes.h:255
@ COLUMN_WIDTH_AUTO
Definition opcodes.h:253
@ WHITE_SPACE_PRE_WRAP
Definition opcodes.h:860
@ WHITE_SPACE_NOWRAP
Definition opcodes.h:859
@ WHITE_SPACE_PRE_LINE
Definition opcodes.h:861
@ WHITE_SPACE_NORMAL
Definition opcodes.h:857
@ WHITE_SPACE_PRE
Definition opcodes.h:858
@ WIDOWS_SET
Definition opcodes.h:866
op_break_after
Definition opcodes.h:142
@ BREAK_AFTER_AUTO
Definition opcodes.h:143
@ BREAK_AFTER_RIGHT
Definition opcodes.h:147
@ BREAK_AFTER_AVOID_PAGE
Definition opcodes.h:150
@ BREAK_AFTER_AVOID_COLUMN
Definition opcodes.h:151
@ BREAK_AFTER_LEFT
Definition opcodes.h:146
@ BREAK_AFTER_COLUMN
Definition opcodes.h:149
@ BREAK_AFTER_AVOID
Definition opcodes.h:145
@ BREAK_AFTER_PAGE
Definition opcodes.h:148
@ BREAK_AFTER_ALWAYS
Definition opcodes.h:144
@ CONTENT_NO_CLOSE_QUOTE
Definition opcodes.h:273
@ CONTENT_NORMAL
Definition opcodes.h:268
@ CONTENT_COUNTERS
Definition opcodes.h:262
@ CONTENT_ATTR
Definition opcodes.h:263
@ CONTENT_CLOSE_QUOTE
Definition opcodes.h:271
@ CONTENT_NO_OPEN_QUOTE
Definition opcodes.h:272
@ CONTENT_COUNTER
Definition opcodes.h:261
@ CONTENT_NONE
Definition opcodes.h:269
@ CONTENT_URI
Definition opcodes.h:260
@ CONTENT_STRING
Definition opcodes.h:259
@ CONTENT_OPEN_QUOTE
Definition opcodes.h:270
@ CONTENT_COUNTER_STYLE_SHIFT
Definition opcodes.h:265
@ PAGE_BREAK_INSIDE_AVOID
Definition opcodes.h:658
@ PAGE_BREAK_INSIDE_AUTO
Definition opcodes.h:657
@ DIRECTION_LTR
Definition opcodes.h:321
@ DIRECTION_RTL
Definition opcodes.h:322
@ VISIBILITY_HIDDEN
Definition opcodes.h:828
@ VISIBILITY_VISIBLE
Definition opcodes.h:827
@ VISIBILITY_COLLAPSE
Definition opcodes.h:829
@ COLUMN_RULE_STYLE_OUTSET
Definition opcodes.h:236
@ COLUMN_RULE_STYLE_DOTTED
Definition opcodes.h:229
@ COLUMN_RULE_STYLE_DOUBLE
Definition opcodes.h:232
@ COLUMN_RULE_STYLE_GROOVE
Definition opcodes.h:233
@ COLUMN_RULE_STYLE_INSET
Definition opcodes.h:235
@ COLUMN_RULE_STYLE_RIDGE
Definition opcodes.h:234
@ COLUMN_RULE_STYLE_HIDDEN
Definition opcodes.h:228
@ COLUMN_RULE_STYLE_DASHED
Definition opcodes.h:230
@ COLUMN_RULE_STYLE_SOLID
Definition opcodes.h:231
@ COLUMN_RULE_STYLE_NONE
Definition opcodes.h:227
@ FONT_WEIGHT_300
Definition opcodes.h:449
@ FONT_WEIGHT_100
Definition opcodes.h:447
@ FONT_WEIGHT_BOLDER
Definition opcodes.h:445
@ FONT_WEIGHT_200
Definition opcodes.h:448
@ FONT_WEIGHT_400
Definition opcodes.h:450
@ FONT_WEIGHT_600
Definition opcodes.h:452
@ FONT_WEIGHT_LIGHTER
Definition opcodes.h:446
@ FONT_WEIGHT_BOLD
Definition opcodes.h:444
@ FONT_WEIGHT_900
Definition opcodes.h:455
@ FONT_WEIGHT_800
Definition opcodes.h:454
@ FONT_WEIGHT_NORMAL
Definition opcodes.h:443
@ FONT_WEIGHT_700
Definition opcodes.h:453
@ FONT_WEIGHT_500
Definition opcodes.h:451
@ FLOAT_NONE
Definition opcodes.h:400
@ FLOAT_LEFT
Definition opcodes.h:398
@ FLOAT_RIGHT
Definition opcodes.h:399
@ ORDER_SET
Definition opcodes.h:593
@ ALIGN_ITEMS_FLEX_END
Definition opcodes.h:28
@ ALIGN_ITEMS_FLEX_START
Definition opcodes.h:27
@ ALIGN_ITEMS_CENTER
Definition opcodes.h:29
@ ALIGN_ITEMS_STRETCH
Definition opcodes.h:26
@ ALIGN_ITEMS_BASELINE
Definition opcodes.h:30
@ JUSTIFY_CONTENT_SPACE_EVENLY
Definition opcodes.h:470
@ JUSTIFY_CONTENT_SPACE_AROUND
Definition opcodes.h:469
@ JUSTIFY_CONTENT_FLEX_END
Definition opcodes.h:466
@ JUSTIFY_CONTENT_CENTER
Definition opcodes.h:467
@ JUSTIFY_CONTENT_FLEX_START
Definition opcodes.h:465
@ JUSTIFY_CONTENT_SPACE_BETWEEN
Definition opcodes.h:468
@ TEXT_TRANSFORM_UPPERCASE
Definition opcodes.h:795
@ TEXT_TRANSFORM_LOWERCASE
Definition opcodes.h:796
@ TEXT_TRANSFORM_NONE
Definition opcodes.h:797
@ TEXT_TRANSFORM_CAPITALIZE
Definition opcodes.h:794
@ PAUSE_BEFORE_SET
Definition opcodes.h:668
@ FONT_VARIANT_SMALL_CAPS
Definition opcodes.h:439
@ FONT_VARIANT_NORMAL
Definition opcodes.h:438
@ FONT_SIZE_SMALLER
Definition opcodes.h:428
@ FONT_SIZE_DIMENSION
Definition opcodes.h:418
@ FONT_SIZE_XX_LARGE
Definition opcodes.h:426
@ FONT_SIZE_LARGE
Definition opcodes.h:424
@ FONT_SIZE_LARGER
Definition opcodes.h:427
@ FONT_SIZE_MEDIUM
Definition opcodes.h:423
@ FONT_SIZE_X_LARGE
Definition opcodes.h:425
@ FONT_SIZE_SMALL
Definition opcodes.h:422
@ FONT_SIZE_XX_SMALL
Definition opcodes.h:420
@ FONT_SIZE_X_SMALL
Definition opcodes.h:421
@ FONT_FAMILY_SANS_SERIF
Definition opcodes.h:410
@ FONT_FAMILY_MONOSPACE
Definition opcodes.h:413
@ FONT_FAMILY_IDENT_LIST
Definition opcodes.h:405
@ FONT_FAMILY_STRING
Definition opcodes.h:404
@ FONT_FAMILY_END
Definition opcodes.h:407
@ FONT_FAMILY_CURSIVE
Definition opcodes.h:411
@ FONT_FAMILY_SERIF
Definition opcodes.h:409
@ FONT_FAMILY_FANTASY
Definition opcodes.h:412
op_bottom
Definition opcodes.h:131
@ BOTTOM_AUTO
Definition opcodes.h:134
@ BOTTOM_SET
Definition opcodes.h:133
@ FONT_STYLE_NORMAL
Definition opcodes.h:432
@ FONT_STYLE_OBLIQUE
Definition opcodes.h:434
@ FONT_STYLE_ITALIC
Definition opcodes.h:433
@ DISPLAY_INLINE_BLOCK
Definition opcodes.h:330
@ DISPLAY_LIST_ITEM
Definition opcodes.h:328
@ DISPLAY_TABLE
Definition opcodes.h:331
@ DISPLAY_TABLE_COLUMN
Definition opcodes.h:338
@ DISPLAY_INLINE
Definition opcodes.h:326
@ DISPLAY_TABLE_CELL
Definition opcodes.h:339
@ DISPLAY_TABLE_COLUMN_GROUP
Definition opcodes.h:337
@ DISPLAY_TABLE_ROW_GROUP
Definition opcodes.h:333
@ DISPLAY_TABLE_ROW
Definition opcodes.h:336
@ DISPLAY_FLEX
Definition opcodes.h:342
@ DISPLAY_INLINE_FLEX
Definition opcodes.h:343
@ DISPLAY_TABLE_FOOTER_GROUP
Definition opcodes.h:335
@ DISPLAY_INLINE_TABLE
Definition opcodes.h:332
@ DISPLAY_BLOCK
Definition opcodes.h:327
@ DISPLAY_TABLE_HEADER_GROUP
Definition opcodes.h:334
@ DISPLAY_RUN_IN
Definition opcodes.h:329
@ DISPLAY_NONE
Definition opcodes.h:341
@ DISPLAY_TABLE_CAPTION
Definition opcodes.h:340
@ PITCH_X_HIGH
Definition opcodes.h:684
@ PITCH_FREQUENCY
Definition opcodes.h:678
@ PITCH_X_LOW
Definition opcodes.h:680
@ PITCH_LOW
Definition opcodes.h:681
@ PITCH_HIGH
Definition opcodes.h:683
@ PITCH_MEDIUM
Definition opcodes.h:682
@ BACKGROUND_REPEAT_REPEAT_Y
Definition opcodes.h:91
@ BACKGROUND_REPEAT_NO_REPEAT
Definition opcodes.h:89
@ BACKGROUND_REPEAT_REPEAT_X
Definition opcodes.h:90
@ BACKGROUND_REPEAT_REPEAT
Definition opcodes.h:92
@ SPEAK_NONE
Definition opcodes.h:738
@ SPEAK_SPELL_OUT
Definition opcodes.h:739
@ SPEAK_NORMAL
Definition opcodes.h:737
op_page_break_after
Definition opcodes.h:640
@ PAGE_BREAK_AFTER_AVOID
Definition opcodes.h:643
@ PAGE_BREAK_AFTER_RIGHT
Definition opcodes.h:645
@ PAGE_BREAK_AFTER_ALWAYS
Definition opcodes.h:642
@ PAGE_BREAK_AFTER_LEFT
Definition opcodes.h:644
@ PAGE_BREAK_AFTER_AUTO
Definition opcodes.h:641
@ SPEAK_PUNCTUATION_CODE
Definition opcodes.h:732
@ SPEAK_PUNCTUATION_NONE
Definition opcodes.h:733
@ MARGIN_SET
Definition opcodes.h:559
@ MARGIN_AUTO
Definition opcodes.h:560
op_background_color
Definition opcodes.h:65
@ BACKGROUND_COLOR_TRANSPARENT
Definition opcodes.h:66
@ BACKGROUND_COLOR_CURRENT_COLOR
Definition opcodes.h:67
@ BACKGROUND_COLOR_SET
Definition opcodes.h:68
@ POSITION_FIXED
Definition opcodes.h:701
@ POSITION_RELATIVE
Definition opcodes.h:699
@ POSITION_STATIC
Definition opcodes.h:698
@ POSITION_ABSOLUTE
Definition opcodes.h:700
@ TEXT_ALIGN_LIBCSS_CENTER
Definition opcodes.h:775
@ TEXT_ALIGN_LEFT
Definition opcodes.h:770
@ TEXT_ALIGN_JUSTIFY
Definition opcodes.h:773
@ TEXT_ALIGN_CENTER
Definition opcodes.h:772
@ TEXT_ALIGN_LIBCSS_LEFT
Definition opcodes.h:774
@ TEXT_ALIGN_LIBCSS_RIGHT
Definition opcodes.h:776
@ TEXT_ALIGN_RIGHT
Definition opcodes.h:771
@ CLEAR_LEFT
Definition opcodes.h:180
@ CLEAR_BOTH
Definition opcodes.h:182
@ CLEAR_NONE
Definition opcodes.h:179
@ CLEAR_RIGHT
Definition opcodes.h:181
@ FLEX_GROW_SET
Definition opcodes.h:383
@ CSS_RULE_PAGE
Definition stylesheet.h:105
@ CSS_RULE_SELECTOR
Definition stylesheet.h:100
@ CSS_RULE_MEDIA
Definition stylesheet.h:103
@ CSS_RULE_CHARSET
Definition stylesheet.h:101
@ CSS_RULE_IMPORT
Definition stylesheet.h:102
@ CSS_RULE_FONT_FACE
Definition stylesheet.h:104
@ CSS_SELECTOR_DETAIL_VALUE_STRING
Definition stylesheet.h:60
@ CSS_COMBINATOR_ANCESTOR
Definition stylesheet.h:53
@ CSS_COMBINATOR_GENERIC_SIBLING
Definition stylesheet.h:56
@ CSS_COMBINATOR_SIBLING
Definition stylesheet.h:55
@ CSS_COMBINATOR_PARENT
Definition stylesheet.h:54
@ CSS_COMBINATOR_NONE
Definition stylesheet.h:52
@ CSS_SELECTOR_ATTRIBUTE_PREFIX
Definition stylesheet.h:46
@ CSS_SELECTOR_ATTRIBUTE_SUBSTRING
Definition stylesheet.h:48
@ CSS_SELECTOR_ATTRIBUTE_INCLUDES
Definition stylesheet.h:45
@ CSS_SELECTOR_CLASS
Definition stylesheet.h:38
@ CSS_SELECTOR_ID
Definition stylesheet.h:39
@ CSS_SELECTOR_ATTRIBUTE_EQUAL
Definition stylesheet.h:43
@ CSS_SELECTOR_ATTRIBUTE_DASHMATCH
Definition stylesheet.h:44
@ CSS_SELECTOR_ATTRIBUTE_SUFFIX
Definition stylesheet.h:47
@ CSS_SELECTOR_PSEUDO_CLASS
Definition stylesheet.h:40
@ CSS_SELECTOR_PSEUDO_ELEMENT
Definition stylesheet.h:41
@ CSS_SELECTOR_ELEMENT
Definition stylesheet.h:37
@ CSS_SELECTOR_ATTRIBUTE
Definition stylesheet.h:42
Definition font_face.h:15
Definition font_face.h:26
uint32_t n_srcs
Definition font_face.h:29
css_font_face_src * srcs
Definition font_face.h:28
lwc_string * font_family
Definition font_face.h:27
uint32_t negate_type
Definition mq.h:80
lwc_string * name
Definition types.h:259
Definition stylesheet.h:164
lwc_string * encoding
Definition stylesheet.h:167
Definition stylesheet.h:142
css_font_face * font_face
Definition stylesheet.h:145
Definition stylesheet.h:155
lwc_string * url
Definition stylesheet.h:158
Definition stylesheet.h:133
css_mq_query * media
Definition stylesheet.h:136
css_rule * first_child
Definition stylesheet.h:138
Definition stylesheet.h:148
css_selector * selector
Definition stylesheet.h:151
css_style * style
Definition stylesheet.h:152
Definition stylesheet.h:126
css_style * style
Definition stylesheet.h:130
css_selector ** selectors
Definition stylesheet.h:129
css_rule base
Definition stylesheet.h:127
Definition stylesheet.h:113
css_rule * next
Definition stylesheet.h:117
uint16_t items
Definition stylesheet.h:121
uint8_t type
Definition stylesheet.h:122
Definition stylesheet.h:72
unsigned int negate
Definition stylesheet.h:81
unsigned int type
Definition stylesheet.h:76
css_qname qname
Definition stylesheet.h:73
unsigned int comb
Definition stylesheet.h:77
unsigned int next
Definition stylesheet.h:79
unsigned int value_type
Definition stylesheet.h:80
css_selector_detail_value value
Definition stylesheet.h:74
Definition stylesheet.h:84
css_selector_detail data
Definition stylesheet.h:95
css_selector * combinator
Definition stylesheet.h:85
Definition stylesheet.h:29
Definition stylesheet.h:170
css_rule * rule_list
Definition stylesheet.h:174
css_error css__stylesheet_string_get(css_stylesheet *sheet, uint32_t string_number, lwc_string **string)
Definition stylesheet.c:105
#define assert(expr)
Definition testutils.h:32
lwc_string * string
Definition stylesheet.h:65
struct css_selector_detail_value::@23 nth
int32_t a
Definition stylesheet.h:67
int32_t b
Definition stylesheet.h:68