65 g_return_val_if_fail (a_sel, NULL);
70 for (cur = a_this; cur->
next; cur = cur->
next) ;
91 g_return_val_if_fail (a_sel, NULL);
105 GString *str_buf = NULL;
106 guchar *result = NULL;
110 g_return_val_if_fail (a_this, NULL);
112 str_buf = g_string_new (NULL);
113 for (cur = a_this; cur; cur = cur->
next) {
115 guchar *str = (guchar *) g_strndup (cur->
name->stryng->str,
116 cur->
name->stryng->len);
121 g_string_append (str_buf,
" ");
125 g_string_append (str_buf,
"+");
129 g_string_append (str_buf,
">");
136 g_string_append (str_buf, (
const gchar *) str);
143 guchar *tmp_str = NULL;
147 g_string_append (str_buf, (
const gchar *) tmp_str);
155 result = (guchar *) str_buf->str;
156 g_string_free (str_buf, FALSE);
167 GString *str_buf = NULL;
168 guchar *result = NULL;
170 g_return_val_if_fail (a_this, NULL);
172 str_buf = g_string_new (NULL);
174 guchar *str = (guchar *) g_strndup (a_this->
name->stryng->str,
175 a_this->
name->stryng->len);
178 g_string_append_printf (str_buf,
"%s", str);
185 guchar *tmp_str = NULL;
189 g_string_append_printf
190 (str_buf,
"%s", tmp_str);
197 result = (guchar *) str_buf->str;
198 g_string_free (str_buf, FALSE);
219 guchar *tmp_str = NULL;
226 fprintf (a_fp,
"%s", tmp_str);
256 for (cur_sel = a_this; cur_sel; cur_sel = cur_sel->
next) {
259 }
else if (!cur_sel->
name 260 || !cur_sel->
name->stryng
261 || !cur_sel->
name->stryng->str) {
272 for (cur_add_sel = cur_sel->
add_sel;
273 cur_add_sel; cur_add_sel = cur_add_sel->
next) {
274 switch (cur_add_sel->
type) {
306 g_return_if_fail (a_this);
guchar * cr_additional_sel_to_string(CRAdditionalSel const *a_this)
void cr_additional_sel_destroy(CRAdditionalSel *a_this)
cr_additional_sel_destroy: @a_this: the "this pointer" of the current instance of CRAdditionalSel .
enum AddSelectorType type
enum Combinator combinator
The combinator that separates this simple selector from the previous one.
guchar * cr_simple_sel_to_string(CRSimpleSel const *a_this)
void cr_string_destroy(CRString *a_this)
CRSimpleSel * cr_simple_sel_prepend_simple_sel(CRSimpleSel *a_this, CRSimpleSel *a_sel)
cr_simple_sel_prepend_simple_sel:
CRStatus
The status type returned by the methods of the croco library.
CRAdditionalSel * add_sel
The additional selector list of the current simple selector.
The abstraction of a css2 simple selection list as defined by the right part of the "selector" produc...
void cr_simple_sel_destroy(CRSimpleSel *a_this)
cr_simple_sel_destroy:
guchar * cr_simple_sel_one_to_string(CRSimpleSel const *a_this)
the declaration of the CRSimpleSel class.
enum CRStatus cr_simple_sel_dump(CRSimpleSel const *a_this, FILE *a_fp)
cr_simple_sel_dump: @a_this: the current instance of CRSimpleSel.
enum SimpleSelectorType type_mask
CRSimpleSel * cr_simple_sel_new(void)
cr_simple_sel_new:
CRSimpleSel * cr_simple_sel_append_simple_sel(CRSimpleSel *a_this, CRSimpleSel *a_sel)
cr_simple_sel_append_simple_sel:
enum CRStatus cr_simple_sel_compute_specificity(CRSimpleSel *a_this)
cr_simple_sel_compute_specificity:
#define cr_utils_trace_info(a_msg)
Traces an info message.