![]() |
![]() |
![]() |
Libcroco Reference Manual | ![]() |
---|---|---|---|---|
Top | Description |
CROMParser; CROMParserPriv; CROMParser * cr_om_parser_new (CRInput *a_input
); enum CRStatus cr_om_parser_simply_parse_file (const guchar *a_file_path
,enum CREncoding a_enc
,CRStyleSheet **a_result
); enum CRStatus cr_om_parser_parse_file (CROMParser *a_this
,const guchar *a_file_uri
,enum CREncoding a_enc
,CRStyleSheet **a_result
); enum CRStatus cr_om_parser_simply_parse_buf (const guchar *a_buf
,gulong a_len
,enum CREncoding a_enc
,CRStyleSheet **a_result
); enum CRStatus cr_om_parser_parse_buf (CROMParser *a_this
,const guchar *a_buf
,gulong a_len
,enum CREncoding a_enc
,CRStyleSheet **a_result
); enum CRStatus cr_om_parser_parse_paths_to_cascade (CROMParser *a_this
,const guchar *a_author_path
,const guchar *a_user_path
,const guchar *a_ua_path
,enum CREncoding a_encoding
,CRCascade **a_result
); enum CRStatus cr_om_parser_simply_parse_paths_to_cascade (const guchar *a_author_path
,const guchar *a_user_path
,const guchar *a_ua_path
,enum CREncoding a_encoding
,CRCascade **a_result
); void cr_om_parser_destroy (CROMParser *a_this
);
CROMParser * cr_om_parser_new (CRInput *a_input
);
Constructor of the CROMParser.
|
the input stream. |
Returns : |
the newly built instance of CROMParser. |
enum CRStatus cr_om_parser_simply_parse_file (const guchar *a_file_path
,enum CREncoding a_enc
,CRStyleSheet **a_result
);
The simpler method to parse a css2 file.
|
the css2 local file path. |
|
the file encoding. |
|
out parameter. The returned css stylesheet. Must be freed by the caller using cr_stylesheet_destroy. |
Returns : |
CR_OK upon successfull completion, an error code otherwise.
Note that this method uses cr_om_parser_parse_file() so both methods
have the same return values.
|
enum CRStatus cr_om_parser_parse_file (CROMParser *a_this
,const guchar *a_file_uri
,enum CREncoding a_enc
,CRStyleSheet **a_result
);
Parses a css2 stylesheet contained in a file.
|
the current instance of the cssom parser. |
|
the uri of the file. (only local file paths are suppported so far) |
|
the encoding of the file. |
|
out parameter. A pointer the build css object model. |
Returns : |
CR_OK upon succesful completion, an error code otherwise. |
enum CRStatus cr_om_parser_simply_parse_buf (const guchar *a_buf
,gulong a_len
,enum CREncoding a_enc
,CRStyleSheet **a_result
);
The simpler way to parse an in memory css2 buffer.
|
the css2 in memory buffer. |
|
the length of the in memory buffer. |
|
the encoding of the in memory buffer. |
|
out parameter. The resulting css2 style sheet. |
Returns : |
CR_OK upon successfull completion, an error code otherwise. |
enum CRStatus cr_om_parser_parse_buf (CROMParser *a_this
,const guchar *a_buf
,gulong a_len
,enum CREncoding a_enc
,CRStyleSheet **a_result
);
Parses the content of an in memory buffer.
|
the current instance of CROMParser. |
|
the in memory buffer to parse. |
|
the length of the in memory buffer in number of bytes. |
|
the encoding of the in memory buffer. |
|
out parameter the resulting style sheet |
Returns : |
CR_OK upon successfull completion, an error code otherwise. |
enum CRStatus cr_om_parser_parse_paths_to_cascade (CROMParser *a_this
,const guchar *a_author_path
,const guchar *a_user_path
,const guchar *a_ua_path
,enum CREncoding a_encoding
,CRCascade **a_result
);
Parses three sheets located by their paths and build a cascade
|
the current instance of CROMParser |
|
the path to the author stylesheet |
|
the path to the user stylesheet |
|
the path to the User Agent stylesheet |
|
the encoding of the sheets. |
|
out parameter. The resulting cascade if the parsing was okay |
Returns : |
CR_OK upon successful completion, an error code otherwise |
enum CRStatus cr_om_parser_simply_parse_paths_to_cascade (const guchar *a_author_path
,const guchar *a_user_path
,const guchar *a_ua_path
,enum CREncoding a_encoding
,CRCascade **a_result
);
Parses three sheets located by their paths and build a cascade
|
the path to the author stylesheet |
|
the path to the user stylesheet |
|
the path to the User Agent stylesheet |
|
the encoding of the sheets. |
|
out parameter. The resulting cascade if the parsing was okay |
Returns : |
CR_OK upon successful completion, an error code otherwise |
void cr_om_parser_destroy (CROMParser *a_this
);
Destructor of the CROMParser.
|
the current instance of CROMParser. |