A little closer to css

Declarations are ;-separated, but there is no ; required after
the last declaration. We harmlessly accept either.
This commit is contained in:
Matthias Clasen 2010-11-18 18:36:08 -05:00 committed by Carlos Garnacho
parent 295cf25d6b
commit 4135fbf4d6

View File

@ -50,24 +50,25 @@
* <programlisting> * <programlisting>
* /&ast; Theme labels that are descendants of a window &ast;/ * /&ast; Theme labels that are descendants of a window &ast;/
* GtkWindow GtkLabel { * GtkWindow GtkLabel {
* background-color: &num;898989; * background-color: &num;898989
* } * }
* *
* /&ast; Theme notebooks, and anything that's within these &ast;/ * /&ast; Theme notebooks, and anything that's within these &ast;/
* GtkNotebook { * GtkNotebook {
* background-color: &num;a939f0; * background-color: &num;a939f0
* } * }
* *
* /&ast; Theme combo boxes, and entries that * /&ast; Theme combo boxes, and entries that
* are direct children of a notebook &ast;/ * are direct children of a notebook &ast;/
* GtkComboBox, * GtkComboBox,
* GtkNotebook > GtkEntry { * GtkNotebook > GtkEntry {
* background-color: &num;1209a2; * color: @fg_color;
* background-color: &num;1209a2
* } * }
* *
* /&ast; Theme any widget within a GtkBin &ast;/ * /&ast; Theme any widget within a GtkBin &ast;/
* GtkBin * { * GtkBin * {
* font-name: Sans 20; * font-name: Sans 20
* } * }
* </programlisting> * </programlisting>
* </example> * </example>
@ -79,12 +80,12 @@
* <programlisting> * <programlisting>
* /&ast; Theme a label named title-label &ast;/ * /&ast; Theme a label named title-label &ast;/
* GtkLabel&num;title-label { * GtkLabel&num;title-label {
* font-name: Sans 15; * font-name: Sans 15
* } * }
* *
* /&ast; Theme any widget named main-entry &ast;/ * /&ast; Theme any widget named main-entry &ast;/
* &num;main-entry { * &num;main-entry {
* background-color: &num;f0a810; * background-color: &num;f0a810
* } * }
* </programlisting> * </programlisting>
* </example> * </example>
@ -102,7 +103,7 @@
* *
* /&ast; Theme spinbuttons' entry &ast;/ * /&ast; Theme spinbuttons' entry &ast;/
* GtkSpinButton.entry { * GtkSpinButton.entry {
* color: &num;900185; * color: &num;900185
* } * }
* </programlisting> * </programlisting>
* </example> * </example>
@ -197,7 +198,7 @@
* <example> * <example>
* <title>Using the &commat;import rule</title> * <title>Using the &commat;import rule</title>
* <programlisting> * <programlisting>
* &commat;import url ("path/to/common.css") * &commat;import url ("path/to/common.css");
* </programlisting> * </programlisting>
* </example> * </example>
* <para> * <para>
@ -254,7 +255,7 @@
* example in common CSS it is fine to define a font through * example in common CSS it is fine to define a font through
* the different @font-family, @font-style, @font-size * the different @font-family, @font-style, @font-size
* properties, meanwhile in GTK+'s CSS only the canonical * properties, meanwhile in GTK+'s CSS only the canonical
* @font property would be supported. * @font property is supported.
* </para> * </para>
* <para> * <para>
* The currently supported properties are: * The currently supported properties are:
@ -1578,8 +1579,7 @@ symbolic_color_parse_str (const gchar *string,
str++; str++;
end = str; end = str;
while (*end == '-' || *end == '_' || while (*end == '-' || *end == '_' || g_ascii_isalpha (*end))
g_ascii_isalpha (*end))
end++; end++;
name = g_strndup (str, end - str); name = g_strndup (str, end - str);
@ -2015,7 +2015,7 @@ gradient_parse_str (const gchar *str,
str++; str++;
SKIP_SPACES (str); SKIP_SPACES (str);
position = g_strtod (str, &end); position = g_ascii_strtod (str, &end);
str = end; str = end;
SKIP_SPACES (str); SKIP_SPACES (str);
@ -2875,7 +2875,7 @@ parse_rule (GtkCssProvider *css_provider,
g_scanner_get_next_token (scanner); g_scanner_get_next_token (scanner);
if (scanner->token != ';') if (scanner->token != ';')
return ';'; break;
g_scanner_get_next_token (scanner); g_scanner_get_next_token (scanner);
} }