33 #define DECLARATION_INDENT_NB 2 35 static void cr_statement_clear (
CRStatement * a_this);
38 parse_font_face_start_font_face_cb (
CRDocHandler * a_this,
45 g_return_if_fail (stmt);
48 g_return_if_fail (status ==
CR_OK);
52 parse_font_face_unrecoverable_error_cb (
CRDocHandler * a_this)
58 g_return_if_fail (a_this);
62 if (status !=
CR_OK) {
64 "This may lead to some memory leaks.");
77 CRTerm * a_value, gboolean a_important)
85 g_return_if_fail (a_this && a_name);
89 g_return_if_fail (status ==
CR_OK && stmt);
93 g_return_if_fail (name);
120 parse_font_face_end_font_face_cb (
CRDocHandler * a_this)
126 g_return_if_fail (a_this);
130 g_return_if_fail (status ==
CR_OK && result);
134 g_return_if_fail (status ==
CR_OK);
145 CRString *page_name = NULL, *pseudo_name = NULL ;
157 g_return_if_fail (stmt);
159 g_return_if_fail (status ==
CR_OK);
163 parse_page_unrecoverable_error_cb (
CRDocHandler * a_this)
169 g_return_if_fail (a_this);
173 if (status !=
CR_OK) {
175 "This may lead to some memory leaks.");
188 CRTerm * a_expression, gboolean a_important)
201 g_return_if_fail (name);
204 g_return_if_fail (decl);
222 g_return_if_fail (status ==
CR_OK && stmt);
226 g_return_if_fail (status ==
CR_OK);
231 GList * a_media_list,
236 GList *media_list = NULL;
238 g_return_if_fail (a_this && a_this->priv);
246 g_return_if_fail (media_list);
252 g_return_if_fail (status ==
CR_OK);
254 g_return_if_fail (status ==
CR_OK);
258 parse_at_media_unrecoverable_error_cb (
CRDocHandler * a_this)
264 g_return_if_fail (a_this);
268 if (status !=
CR_OK) {
270 "This may lead to some memory leaks.");
282 parse_at_media_start_selector_cb (
CRDocHandler * a_this,
290 g_return_if_fail (a_this && a_this->priv && a_sellist);
292 at_media_ptr = &at_media;
294 g_return_if_fail (status ==
CR_OK && at_media);
297 g_return_if_fail (ruleset);
299 g_return_if_fail (status ==
CR_OK);
305 gboolean a_important)
318 g_return_if_fail (a_this && a_name);
321 g_return_if_fail (name);
325 (gpointer *) stmtptr);
326 g_return_if_fail (status ==
CR_OK && stmt);
330 g_return_if_fail (decl);
333 g_return_if_fail (status ==
CR_OK);
349 g_return_if_fail (a_this && a_sellist);
353 g_return_if_fail (status ==
CR_OK && stmt
359 g_return_if_fail (status ==
CR_OK);
364 GList * a_media_list)
370 g_return_if_fail (a_this && a_this->priv);
372 at_media_ptr = &at_media;
374 (gpointer *) at_media_ptr);
375 g_return_if_fail (status ==
CR_OK && at_media);
385 g_return_if_fail (a_this && a_this->priv && a_sellist);
388 g_return_if_fail (ruleset);
394 parse_ruleset_unrecoverable_error_cb (
CRDocHandler * a_this)
402 if (status !=
CR_OK) {
404 "This may lead to some memory leaks.");
417 CRTerm * a_value, gboolean a_important)
425 g_return_if_fail (a_this && a_this->priv && a_name);
428 g_return_if_fail (stringue);
430 rulesetptr = &ruleset;
432 g_return_if_fail (status ==
CR_OK 437 g_return_if_fail (decl);
440 g_return_if_fail (status ==
CR_OK);
451 g_return_if_fail (a_this && a_sellist);
456 g_return_if_fail (status ==
CR_OK 464 g_return_if_fail (a_this);
466 switch (a_this->
type) {
509 cur; cur = cur->next) {
589 cr_statement_ruleset_to_string (
CRStatement const * a_this, glong a_indent)
591 GString *stringue = NULL;
592 gchar *tmp_str = NULL,
597 stringue = g_string_new (NULL);
607 g_string_append (stringue, tmp_str);
612 g_string_append (stringue,
" {\n");
618 g_string_append (stringue, tmp_str);
622 g_string_append (stringue,
"\n");
625 g_string_append (stringue,
"}");
626 result = stringue->str;
629 g_string_free (stringue, FALSE);
653 cr_statement_font_face_rule_to_string (
CRStatement const * a_this,
656 gchar *result = NULL, *tmp_str = NULL ;
657 GString *stringue = NULL ;
659 g_return_val_if_fail (a_this
664 stringue = g_string_new (NULL) ;
665 g_return_val_if_fail (stringue, NULL) ;
669 g_string_append (stringue,
"@font-face {\n");
674 g_string_append (stringue,
679 g_string_append (stringue,
"\n}");
682 result = stringue->str ;
683 g_string_free (stringue, FALSE) ;
701 cr_statement_charset_to_string (
CRStatement const *a_this,
705 GString *stringue = NULL ;
707 g_return_val_if_fail (a_this
717 g_return_val_if_fail (str, NULL);
718 stringue = g_string_new (NULL) ;
719 g_return_val_if_fail (stringue, NULL) ;
721 g_string_append_printf (stringue,
722 "@charset \"%s\" ;", str);
729 str = stringue->str ;
730 g_string_free (stringue, FALSE) ;
746 cr_statement_at_page_rule_to_string (
CRStatement const *a_this,
749 GString *stringue = NULL;
750 gchar *result = NULL ;
752 stringue = g_string_new (NULL) ;
755 g_string_append (stringue,
"@page");
758 g_string_append_printf
762 g_string_append (stringue,
" ");
766 g_string_append_printf
772 g_string_append (stringue,
" {\n");
777 g_string_append (stringue, str) ;
781 g_string_append (stringue,
"\n}\n");
783 result = stringue->str ;
784 g_string_free (stringue, FALSE) ;
798 cr_statement_media_rule_to_string (
CRStatement const *a_this,
802 GString *stringue = NULL ;
803 GList
const *cur = NULL;
809 stringue = g_string_new (NULL) ;
811 g_string_append (stringue,
"@media");
825 g_string_append_printf
833 g_string_append (stringue,
" {\n");
838 g_string_append (stringue, str) ;
842 g_string_append (stringue,
"\n}");
845 str = stringue->str ;
846 g_string_free (stringue, FALSE) ;
853 cr_statement_import_rule_to_string (
CRStatement const *a_this,
856 GString *stringue = NULL ;
859 g_return_val_if_fail (a_this
866 stringue = g_string_new (NULL) ;
867 g_return_val_if_fail (stringue, NULL) ;
872 g_string_append_printf (stringue,
873 "@import url(\"%s\")",
881 GList
const *cur = NULL;
884 cur; cur = cur->next) {
894 && crstr->stryng->str) {
898 crstr->stryng->len) ;
903 g_string_append (stringue,
" ;");
906 str = stringue->str ;
907 g_string_free (stringue, FALSE) ;
936 gboolean result = FALSE;
940 g_return_val_if_fail (parser, FALSE);
943 if (status !=
CR_OK) {
948 if (status ==
CR_OK) {
1003 (a_buf, a_encoding);
1010 (a_buf, a_encoding);
1018 (a_buf, a_encoding);
1025 (a_buf, a_encoding);
1056 g_return_val_if_fail (a_buf, NULL);
1061 g_return_val_if_fail (parser, NULL);
1064 g_return_val_if_fail (parser, NULL);
1066 sac_handler->start_selector = parse_ruleset_start_selector_cb;
1067 sac_handler->end_selector = parse_ruleset_end_selector_cb;
1068 sac_handler->property = parse_ruleset_property_cb;
1069 sac_handler->unrecoverable_error =
1070 parse_ruleset_unrecoverable_error_cb;
1075 if (status !=
CR_OK) {
1079 resultptr = &result;
1081 (gpointer *) resultptr);
1082 if (!((status ==
CR_OK) && result)) {
1093 sac_handler = NULL ;
1126 g_return_val_if_fail (a_sel_list, NULL);
1128 if (a_parent_media_rule) {
1129 g_return_val_if_fail
1160 if (a_parent_media_rule) {
1205 (
"Instantiation of the sac handler failed");
1209 sac_handler->start_media = parse_at_media_start_media_cb;
1210 sac_handler->start_selector = parse_at_media_start_selector_cb;
1211 sac_handler->property = parse_at_media_property_cb;
1212 sac_handler->end_selector = parse_at_media_end_selector_cb;
1213 sac_handler->end_media = parse_at_media_end_media_cb;
1214 sac_handler->unrecoverable_error =
1215 parse_at_media_unrecoverable_error_cb;
1218 if (status !=
CR_OK)
1222 if (status !=
CR_OK)
1226 if (status !=
CR_OK)
1229 resultptr = &result;
1231 (gpointer *) resultptr);
1232 if (status !=
CR_OK)
1240 sac_handler = NULL ;
1289 for (cur = a_rulesets; cur; cur = cur->
next) {
1292 "It should be a list of " 1293 "correct ruleset statement only !");
1296 cur->kind.ruleset->parent_media_rule = result;
1325 GList * a_media_list,
1352 if (a_container_sheet)
1377 GList *media_list = NULL;
1389 if (status !=
CR_OK)
1396 if (status !=
CR_OK || !import_string)
1404 import_string = NULL;
1415 media_list = g_list_next (media_list)) {
1416 if (media_list->data) {
1418 media_list->data = NULL;
1421 g_list_free (media_list);
1424 if (import_string) {
1426 import_string = NULL;
1506 g_return_val_if_fail (a_buf, NULL);
1518 (
"Instantiation of the sac handler failed.");
1522 sac_handler->start_page = parse_page_start_page_cb;
1523 sac_handler->property = parse_page_property_cb;
1524 sac_handler->end_page = parse_page_end_page_cb;
1525 sac_handler->unrecoverable_error = parse_page_unrecoverable_error_cb;
1528 if (status !=
CR_OK)
1533 if (status !=
CR_OK)
1536 if (status !=
CR_OK)
1539 resultptr = &result;
1541 (gpointer *) resultptr);
1548 sac_handler = NULL ;
1576 g_return_val_if_fail (a_charset, NULL);
1622 g_return_val_if_fail (a_buf, NULL);
1633 if (status !=
CR_OK)
1636 if (status !=
CR_OK || !charset)
1733 sac_handler->start_font_face = parse_font_face_start_font_face_cb;
1734 sac_handler->property = parse_font_face_property_cb;
1735 sac_handler->end_font_face = parse_font_face_end_font_face_cb;
1736 sac_handler->unrecoverable_error =
1737 parse_font_face_unrecoverable_error_cb;
1740 if (status !=
CR_OK)
1748 if (status !=
CR_OK)
1752 if (status !=
CR_OK)
1755 resultptr = &result;
1757 (gpointer *) resultptr);
1758 if (status !=
CR_OK || !result)
1765 sac_handler = NULL ;
1825 g_return_val_if_fail (a_new, NULL);
1832 for (cur = a_this; cur && cur->
next; cur = cur->
next) ;
1857 g_return_val_if_fail (a_new, NULL);
1862 a_new->
next = a_this;
1863 a_this->
prev = a_new;
1866 for (cur = a_new; cur && cur->
prev; cur = cur->
prev) ;
1887 g_return_val_if_fail (result, NULL);
1893 g_return_val_if_fail (a_stmt->
next->
prev == a_stmt, NULL);
1896 g_return_val_if_fail (a_stmt->
prev->
next == a_stmt, NULL);
1915 a_stmt->
next = NULL;
1916 a_stmt->
prev = NULL;
1937 g_return_val_if_fail (a_this, -1);
1939 for (cur = a_this; cur; cur = cur->
next)
1961 g_return_val_if_fail (a_this, NULL);
1963 for (cur = a_this; cur; cur = cur->
next)
2017 g_return_val_if_fail (a_this
2105 g_return_val_if_fail (new_decls,
CR_ERROR);
2133 g_return_val_if_fail (new_decls,
CR_ERROR);
2155 g_return_val_if_fail (a_this
2179 g_return_val_if_fail (a_this
2202 g_return_val_if_fail (a_this
2230 g_return_val_if_fail (a_this
2250 g_return_val_if_fail (a_this
2271 g_return_val_if_fail (a_this
2294 g_return_val_if_fail (a_this
2326 g_return_val_if_fail (a_this
2350 g_return_val_if_fail (a_this
2377 g_return_val_if_fail (a_this
2401 g_return_val_if_fail (a_this
2432 g_return_val_if_fail (a_this
2460 g_return_val_if_fail (a_this
2469 g_return_val_if_fail (decls,
CR_ERROR);
2499 switch (a_this->
type) {
2501 str = cr_statement_ruleset_to_string
2506 str = cr_statement_font_face_rule_to_string
2507 (a_this, a_indent) ;
2511 str = cr_statement_charset_to_string
2516 str = cr_statement_at_page_rule_to_string
2521 str = cr_statement_media_rule_to_string
2526 str = cr_statement_import_rule_to_string
2541 GString *stringue = NULL ;
2544 g_return_val_if_fail (a_this, NULL) ;
2546 stringue = g_string_new (NULL) ;
2551 for (cur_stmt = a_this ; cur_stmt;
2552 cur_stmt = cur_stmt->
next) {
2555 if (!cur_stmt->
prev) {
2556 g_string_append (stringue, str) ;
2558 g_string_append_printf
2559 (stringue,
"\n%s", str) ;
2565 str = stringue->str ;
2566 g_string_free (stringue, FALSE) ;
2589 fprintf (a_fp,
"%s",str) ;
2609 g_return_if_fail (a_fp && a_this);
2610 str = cr_statement_ruleset_to_string (a_this, a_indent);
2612 fprintf (a_fp,
"%s", str);
2632 g_return_if_fail (a_this
2635 str = cr_statement_font_face_rule_to_string (a_this,
2638 fprintf (a_fp,
"%s", str) ;
2660 str = cr_statement_charset_to_string (a_this,
2663 fprintf (a_fp,
"%s", str) ;
2684 g_return_if_fail (a_this
2688 str = cr_statement_at_page_rule_to_string (a_this, a_indent) ;
2690 fprintf (a_fp,
"%s", str);
2714 str = cr_statement_media_rule_to_string (a_this, a_indent) ;
2716 fprintf (a_fp,
"%s", str) ;
2735 g_return_if_fail (a_this
2740 str = cr_statement_import_rule_to_string (a_this, a_indent) ;
2742 fprintf (a_fp,
"%s", str) ;
2760 g_return_if_fail (a_this);
2763 for (cur = a_this; cur && cur->
next; cur = cur->
next) {
2764 cr_statement_clear (cur);
2768 cr_statement_clear (cur);
2770 if (cur->
prev == NULL) {
2776 for (cur = cur->
prev; cur && cur->
prev; cur = cur->
prev) {
CRSelector * sel_list
A list of instances of #CRSimpeSel.
CRStatement * cr_statement_at_media_rule_parse_from_buf(const guchar *a_buf, enum CREncoding a_enc)
cr_statement_at_media_rule_parse_from_buf:
CRStatement * cr_statement_unlink(CRStatement *a_stmt)
cr_statement_unlink:
CRStatement * cr_statement_new_at_import_rule(CRStyleSheet *a_container_sheet, CRString *a_url, GList *a_media_list, CRStyleSheet *a_imported_sheet)
cr_statement_new_at_import_rule:
CRStatement * parent_media_rule
The parent media rule, or NULL if no parent media rule exists.
CRDeclaration * decl_list
A list of instances of CRDeclaration.
CRAtMediaRule * media_rule
union _CRStatement::@1 kind
enum CRStatus cr_parser_parse_ruleset(CRParser *a_this)
cr_parser_parse_ruleset: @a_this: the "this pointer" of the current instance of CRParser.
CRAtFontFaceRule * font_face_rule
The implementation of the SAC parser.
CRStatement * cr_statement_at_media_get_from_list(CRStatement *a_this, int itemnr)
cr_statement_at_media_get_from_list:
Declaration of the CRStatement class.
void cr_statement_dump_page(CRStatement const *a_this, FILE *a_fp, gulong a_indent)
cr_statement_dump_page:
enum CRStatus cr_doc_handler_set_ctxt(CRDocHandler *a_this, gpointer a_ctxt)
cr_doc_handler_set_ctxt: @a_this: the current instance of CRDocHandler @a_ctxt: a pointer to the pars...
#define DECLARATION_INDENT_NB
void cr_statement_destroy(CRStatement *a_this)
cr_statement_destroy:
CRStatement * statements
The css statements list.
void cr_statement_dump_media_rule(CRStatement const *a_this, FILE *a_fp, gulong a_indent)
cr_statement_dump_media_rule:
CRStatement * cr_statement_prepend(CRStatement *a_this, CRStatement *a_new)
cr_statement_prepend:
void cr_declaration_destroy(CRDeclaration *a_this)
cr_declaration_destroy: @a_this: the current instance of CRDeclaration.
An abstraction of a css stylesheet as defined by the css2 spec in chapter 4.
enum CRStatus cr_statement_ruleset_set_decl_list(CRStatement *a_this, CRDeclaration *a_list)
cr_statement_ruleset_set_decl_list:
CRStatement * cr_statement_get_from_list(CRStatement *a_this, int itemnr)
cr_statement_get_from_list:
enum CRStatus cr_statement_at_font_face_rule_set_decls(CRStatement *a_this, CRDeclaration *a_decls)
cr_statement_at_font_face_rule_set_decls:
enum CRStatus cr_parser_set_sac_handler(CRParser *a_this, CRDocHandler *a_handler)
cr_parser_set_sac_handler: @a_this: the "this pointer" of the current instance of CRParser.
enum CRStatus cr_statement_set_parent_sheet(CRStatement *a_this, CRStyleSheet *a_sheet)
cr_statement_set_parent_sheet:
CRStatement * cr_statement_font_face_rule_parse_from_buf(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_font_face_rule_parse_from_buf:
void cr_string_destroy(CRString *a_this)
CRStatement * cr_statement_parse_from_buf(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_parse_from_buf:
enum CRStatus cr_statement_at_import_rule_set_imported_sheet(CRStatement *a_this, CRStyleSheet *a_sheet)
cr_statement_at_import_rule_set_imported_sheet:
CREncoding
Encoding values.
gboolean cr_selector_unref(CRSelector *a_this)
cr_selector_unref:
enum CRStatus cr_parser_try_to_skip_spaces_and_comments(CRParser *a_this)
cr_parser_try_to_skip_spaces_and_comments: @a_this: the current instance of CRParser.
CRDeclaration * decl_list
typedefG_BEGIN_DECLS struct _CRSelector CRSelector
enum CRStatus cr_doc_handler_get_ctxt(CRDocHandler const *a_this, gpointer *a_ctxt)
cr_doc_handler_get_ctxt: @a_this: the current instance of CRDocHandler.
enum CRStatus cr_doc_handler_set_result(CRDocHandler *a_this, gpointer a_result)
cr_doc_handler_set_result: @a_this: the current instance of CRDocHandler @a_result: the new result.
CRStatus
The status type returned by the methods of the croco library.
enum CRStatementType type
The type of the statement.
CRStatement * cr_statement_new_at_media_rule(CRStyleSheet *a_sheet, CRStatement *a_rulesets, GList *a_media)
cr_statement_new_at_media_rule:
typedefG_BEGIN_DECLS struct _CRDocHandler CRDocHandler
CRStatement * cr_statement_at_import_rule_parse_from_buf(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_at_import_rule_parse_from_buf:
CRDeclaration * cr_declaration_append(CRDeclaration *a_this, CRDeclaration *a_new)
cr_declaration_append: @a_this: the current declaration list.
gint cr_statement_nr_rules(CRStatement const *a_this)
cr_statement_nr_rules:
GList * cr_utils_dup_glist_of_cr_string(GList const *a_list_of_strings)
Duplicate a GList where the GList::data is a CRString.
CRStatement * cr_statement_at_page_rule_parse_from_buf(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_at_page_rule_parse_from_buf:
void cr_statement_dump_ruleset(CRStatement const *a_this, FILE *a_fp, glong a_indent)
cr_statement_dump_ruleset:
CRAtCharsetRule * charset_rule
enum CRStatus cr_statement_at_font_face_rule_add_decl(CRStatement *a_this, CRString *a_prop, CRTerm *a_value)
cr_statement_at_font_face_rule_add_decl:
The abstraction of css statement as defined in the chapter 4 and appendix D.1 of the css2 spec.
enum CRStatus cr_parser_parse_page(CRParser *a_this)
cr_parser_parse_page: @a_this: the "this pointer" of the current instance of CRParser.
gchar * cr_statement_list_to_string(CRStatement const *a_this, gulong a_indent)
enum CRStatus cr_doc_handler_get_result(CRDocHandler const *a_this, gpointer *a_result)
cr_doc_handler_get_result: @a_this: the current instance of CRDocHandler @a_result: out parameter.
guchar * cr_declaration_list_to_string2(CRDeclaration const *a_this, gulong a_indent, gboolean a_one_decl_per_line)
cr_declaration_list_to_string2: @a_this: the current instance of CRDeclaration.
gboolean cr_declaration_unref(CRDeclaration *a_this)
cr_declaration_unref: @a_this: the current instance of CRDeclaration.
enum CRStatus cr_statement_at_charset_rule_get_charset(CRStatement const *a_this, CRString **a_charset)
cr_statement_at_charset_rule_get_charset: @a_this: the current @charset rule statement.
gboolean cr_statement_does_buf_parses_against_core(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_does_buf_parses_against_core:
gchar * cr_string_dup2(CRString const *a_this)
CRString * cr_string_dup(CRString const *a_this)
CRStatement * cr_statement_append(CRStatement *a_this, CRStatement *a_new)
cr_statement_append:
enum CRStatus cr_parser_parse_charset(CRParser *a_this, CRString **a_value, CRParsingLocation *a_charset_sym_location)
cr_parser_parse_charset: @a_this: the "this pointer" of the current instance of CRParser.
CRStatement * cr_statement_at_charset_rule_parse_from_buf(const guchar *a_buf, enum CREncoding a_encoding)
cr_statement_at_charset_rule_parse_from_buf:
int cr_statement_at_media_nr_rules(CRStatement const *a_this)
cr_statement_at_media_nr_rules:
A generic css at-rule each unknown at-rule will be of this type.
gboolean cr_doc_handler_unref(CRDocHandler *a_this)
cr_doc_handler_unref: @a_this: the currrent instance of CRDocHandler.
CRParser * cr_parser_new_from_buf(guchar *a_buf, gulong a_len, enum CREncoding a_enc, gboolean a_free_buf)
cr_parser_new_from_buf: @a_buf: the buffer to parse.
void cr_statement_dump_font_face_rule(CRStatement const *a_this, FILE *a_fp, glong a_indent)
cr_statement_dump_font_face_rule:
typedefG_BEGIN_DECLS struct _CRString CRString
CRDeclaration * cr_declaration_append2(CRDeclaration *a_this, CRString *a_prop, CRTerm *a_value)
cr_declaration_append2: @a_this: the current declaration list.
enum CRStatus cr_parser_parse_statement_core(CRParser *a_this)
cr_parser_parse_statement_core: @a_this: the current instance of CRParser.
void cr_statement_dump(CRStatement const *a_this, FILE *a_fp, gulong a_indent)
cr_statement_dump:
guchar * cr_selector_to_string(CRSelector const *a_this)
enum CRStatus cr_statement_at_charset_rule_set_charset(CRStatement *a_this, CRString *a_charset)
cr_statement_at_charset_rule_set_charset:
CRStatement * cr_statement_new_at_font_face_rule(CRStyleSheet *a_sheet, CRDeclaration *a_font_decls)
cr_statement_new_at_font_face_rule:
CRStyleSheet * sheet
the stylesheet fetched from the url, if any.
enum CRStatus cr_statement_ruleset_get_sel_list(CRStatement const *a_this, CRSelector **a_list)
cr_statement_ruleset_get_sel_list:
enum CRStatus cr_statement_at_import_rule_get_imported_sheet(CRStatement *a_this, CRStyleSheet **a_sheet)
cr_statement_at_import_rule_get_imported_sheet:
enum CRStatus cr_statement_ruleset_get_declarations(CRStatement *a_this, CRDeclaration **a_decl_list)
cr_statement_ruleset_get_declarations:
The abstraction of a css ruleset.
CRDeclaration * cr_declaration_new(CRStatement *a_statement, CRString *a_property, CRTerm *a_value)
cr_declaration_new: @a_statement: the statement this declaration belongs to.
gchar * cr_statement_to_string(CRStatement const *a_this, gulong a_indent)
cr_statement_to_string:
enum CRStatus cr_statement_at_import_rule_get_url(CRStatement const *a_this, CRString **a_url)
cr_statement_at_import_rule_get_url:
An abstraction of a css2 term as defined in the CSS2 spec in appendix D.1: term ::= [ NUMBER S* | PER...
enum CRStatus cr_statement_get_parent_sheet(CRStatement *a_this, CRStyleSheet **a_sheet)
cr_statement_get_parent_sheet:
void cr_selector_ref(CRSelector *a_this)
cr_selector_ref:
CRAtImportRule * import_rule
void cr_utils_dump_n_chars2(guchar a_char, GString *a_string, glong a_nb)
enum CRStatus cr_parser_parse_font_face(CRParser *a_this)
cr_parser_parse_font_face: @a_this: the current instance of CRParser.
CRParsingLocation location
CRString * url
the url of the import rule
enum CRStatus cr_parser_set_use_core_grammar(CRParser *a_this, gboolean a_use_core_grammar)
cr_parser_set_use_core_grammar: @a_this: the current instance of CRParser.
void cr_statement_dump_charset(CRStatement const *a_this, FILE *a_fp, gulong a_indent)
cr_statement_dump_charset:
CRStyleSheet * parent_sheet
enum CRStatus cr_statement_at_page_rule_get_declarations(CRStatement *a_this, CRDeclaration **a_decl_list)
cr_statement_at_page_rule_get_declarations:
The declaration file of the CRParser class.
void cr_parser_destroy(CRParser *a_this)
cr_parser_destroy: @a_this: the current instance of CRParser to destroy.
void cr_statement_dump_import_rule(CRStatement const *a_this, FILE *a_fp, gulong a_indent)
cr_statement_dump_import_rule:
enum CRStatus cr_statement_ruleset_append_decl2(CRStatement *a_this, CRString *a_prop, CRTerm *a_value)
cr_statement_ruleset_append_decl2:
CRStatement * cr_statement_new_at_charset_rule(CRStyleSheet *a_sheet, CRString *a_charset)
cr_statement_new_at_charset_rule:
enum CRStatus cr_statement_ruleset_append_decl(CRStatement *a_this, CRDeclaration *a_decl)
cr_statement_ruleset_append_decl:
CRStatement * cr_statement_new_ruleset(CRStyleSheet *a_sheet, CRSelector *a_sel_list, CRDeclaration *a_decl_list, CRStatement *a_parent_media_rule)
cr_statement_new_ruleset:
enum CRStatus cr_parsing_location_copy(CRParsingLocation *a_to, CRParsingLocation const *a_from)
cr_parsing_location_copy: @a_to: the destination of the copy.
void cr_declaration_ref(CRDeclaration *a_this)
cr_declaration_ref: @a_this: the current instance of CRDeclaration.
enum CRStatus cr_parser_parse_media(CRParser *a_this)
cr_parser_parse_media: @a_this: the "this pointer" of the current instance of CRParser.
enum CRStatus cr_parser_parse_import(CRParser *a_this, GList **a_media_list, CRString **a_import_string, CRParsingLocation *a_location)
cr_parser_parse_import: @a_this: the "this pointer" of the current instance of CRParser.
enum CRStatus cr_statement_ruleset_set_sel_list(CRStatement *a_this, CRSelector *a_sel_list)
cr_statement_ruleset_set_sel_list:
enum CRStatus cr_statement_at_font_face_rule_get_decls(CRStatement *a_this, CRDeclaration **a_decls)
cr_statement_at_font_face_rule_get_decls:
enum CRStatus cr_statement_at_page_rule_set_declarations(CRStatement *a_this, CRDeclaration *a_decl_list)
cr_statement_at_page_rule_set_declarations:
CRStatement * cr_statement_ruleset_parse_from_buf(const guchar *a_buf, enum CREncoding a_enc)
cr_statement_ruleset_parse_from_buf:
CRDocHandler * cr_doc_handler_new(void)
cr_doc_handler_new: Constructor of CRDocHandler.
#define cr_utils_trace_info(a_msg)
Traces an info message.
CRStatement * cr_statement_new_at_page_rule(CRStyleSheet *a_sheet, CRDeclaration *a_decl_list, CRString *a_name, CRString *a_pseudo)
cr_statement_new_at_page_rule:
enum CRStatus cr_statement_at_import_rule_set_url(CRStatement *a_this, CRString *a_url)
cr_statement_at_import_rule_set_url: