Commit 38be9fe8 authored by Benjamin Otte's avatar Benjamin Otte

css: Add _gtk_css_parser_has_prefix()

parent 11ec7051
......@@ -92,6 +92,15 @@ _gtk_css_parser_begins_with (GtkCssParser *parser,
return *parser->data == c;
}
gboolean
_gtk_css_parser_has_prefix (GtkCssParser *parser,
const char *prefix)
{
g_return_val_if_fail (GTK_IS_CSS_PARSER (parser), FALSE);
return g_ascii_strncasecmp (parser->data, prefix, strlen (prefix)) == 0;
}
guint
_gtk_css_parser_get_line (GtkCssParser *parser)
{
......
......@@ -47,6 +47,8 @@ guint _gtk_css_parser_get_position (GtkCssParser *parser
gboolean _gtk_css_parser_is_eof (GtkCssParser *parser);
gboolean _gtk_css_parser_begins_with (GtkCssParser *parser,
char c);
gboolean _gtk_css_parser_has_prefix (GtkCssParser *parser,
const char *prefix);
gboolean _gtk_css_parser_is_string (GtkCssParser *parser);
/* IMPORTANT:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment