cr_doc_handler_set_default_sac_handler ()

Sets the sac handlers contained in the current
instance of DocHandler to the default handlers.
For the time being the default handlers are
test handlers. This is expected to change in a
near future, when the libcroco gets a bit debugged.

cr_doc_handler_destroy ()

Parameters

Types and Values

struct CRDocHandler

struct CRDocHandler {
CRDocHandlerPriv *priv ;
/**
*This pointer is to be used by the application for
*it custom needs. It is there to extend the doc handler.
*/
gpointer app_data ;
/**
*Is called at the beginning of the parsing of the document.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*/
void (*start_document) (CRDocHandler *a_this) ;
/**
*Is called to notify the end of the parsing of the document.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*/
void (*end_document) (CRDocHandler *a_this) ;
/**
*Is called to notify an at charset rule.
*@param a_this the document handler.
*@param a_charset the declared charset.
*/
void (*charset) (CRDocHandler *a_this,
CRString *a_charset,
CRParsingLocation *a_charset_sym_location) ;
/**
*Is called to notify an import statement in
*the stylesheet.
*@param a_this the current instance of #CRDocHandler.
*@param a_media_list a doubly linked list of GString objects.
*Each GString object contains a string which is the
*destination media for style information.
*@param a_uri the uri of the imported style sheet.
*@param a_uri_default_ns the default namespace of URI
*@param a_location the parsing location of the '\@import'
*keyword.
*of the imported style sheet.
*/
void (*import_style) (CRDocHandler *a_this,
GList *a_media_list,
CRString *a_uri,
CRString *a_uri_default_ns,
CRParsingLocation *a_location) ;
void (*import_style_result) (CRDocHandler *a_this,
GList *a_media_list,
CRString *a_uri,
CRString *a_uri_default_ns,
CRStyleSheet *a_sheet) ;
/**
*Is called to notify a namespace declaration.
*Not used yet.
*@param a_this the current instance of #CRDocHandler.
*@param a_prefix the prefix of the namespace.
*@param a_uri the uri of the namespace.
*@param a_location the location of the "@namespace" keyword.
*/
void (*namespace_declaration) (CRDocHandler *a_this,
CRString *a_prefix,
CRString *a_uri,
CRParsingLocation *a_location) ;
/**
*Is called to notify a comment.
*@param a_this a pointer to the current instance
*of #CRDocHandler.
*@param a_comment the comment.
*/
void (*comment) (CRDocHandler *a_this,
CRString *a_comment) ;
/**
*Is called to notify the beginning of a rule
*statement.
*@param a_this the current instance of #CRDocHandler.
*@param a_selector_list the list of selectors that precedes
*the rule declarations.
*/
void (*start_selector) (CRDocHandler * a_this,
CRSelector *a_selector_list) ;
/**
*Is called to notify the end of a rule statement.
*@param a_this the current instance of #CRDocHandler.
*@param a_selector_list the list of selectors that precedes
*the rule declarations. This pointer is the same as
*the one passed to start_selector() ;
*/
void (*end_selector) (CRDocHandler *a_this,
CRSelector *a_selector_list) ;
/**
*Is called to notify a declaration.
*@param a_this a pointer to the current instance
*of #CRDocHandler.
*@param a_name the name of the parsed property.
*@param a_expression a css expression that represents
*the value of the property. A css expression is
*actually a linked list of 'terms'. Each term can
*be linked to other using operators.
*
*/
void (*property) (CRDocHandler *a_this,
CRString *a_name,
CRTerm *a_expression,
gboolean a_is_important) ;
/**
*Is called to notify the start of a font face statement.
*The parser invokes this method at the beginning of every
*font face statement in the style sheet. There will
*be a corresponding end_font_face () event for every
*start_font_face () event.
*
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*@param a_location the parsing location of the "\@font-face"
*keyword.
*/
void (*start_font_face) (CRDocHandler *a_this,
CRParsingLocation *a_location) ;
/**
*Is called to notify the end of a font face statement.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*/
void (*end_font_face) (CRDocHandler *a_this) ;
/**
*Is called to notify the beginning of a media statement.
*The parser will invoke this method at the beginning of
*every media statement in the style sheet. There will be
*a corresponding end_media() event for every start_media()
*event.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*@param a_media_list a double linked list of
#CRString * objects.
*Each CRString objects is actually a destination media for
*the style information.
*/
void (*start_media) (CRDocHandler *a_this,
GList *a_media_list,
CRParsingLocation *a_location) ;
/**
*Is called to notify the end of a media statement.
*@param a_this a pointer to the current instance
*of #CRDocHandler.
*@param a_media_list a double linked list of GString * objects.
*Each GString objects is actually a destination media for
*the style information.
*/
void (*end_media) (CRDocHandler *a_this,
GList *a_media_list) ;
/**
*Is called to notify the beginning of a page statement.
*The parser invokes this function at the beginning of
*every page statement in the style sheet. There will be
*a corresponding end_page() event for every single
*start_page() event.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*@param a_name the name of the page (if any, null otherwise).
*@param a_pseudo_page the pseudo page (if any, null otherwise).
*@param a_location the parsing location of the "\@page" keyword.
*/
void (*start_page) (CRDocHandler *a_this,
CRString *a_name,
CRString *a_pseudo_page,
CRParsingLocation *a_location) ;
/**
*Is called to notify the end of a page statement.
*@param a_this a pointer to the current instance of
*#CRDocHandler.
*@param a_name the name of the page (if any, null otherwise).
*@param a_pseudo_page the pseudo page (if any, null otherwise).
*/
void (*end_page) (CRDocHandler *a_this,
CRString *a_name,
CRString *pseudo_page) ;
/**
*Is Called to notify an unknown at-rule not supported
*by this parser.
*/
void (*ignorable_at_rule) (CRDocHandler *a_this,
CRString *a_name) ;
/**
*Is called to notify a parsing error. After this error
*the application must ignore the rule being parsed, if
*any. After completion of this callback,
*the parser will then try to resume the parsing,
*ignoring the current error.
*/
void (*error) (CRDocHandler *a_this) ;
/**
*Is called to notify an unrecoverable parsing error.
*This is the place to put emergency routines that free allocated
*resources.
*/
void (*unrecoverable_error) (CRDocHandler *a_this) ;
gboolean resolve_import ;
gulong ref_count ;
};