The full syntax of the resources files is described online at:
Definining styles is not very difficult:
style 'name ' [ = 'parent'] {
fg[state] = <color>
bg[state] = <color>
base[state] = <color>
text[state] = <color>
bg_texts[state] = <color>
font = <font>
fontset = <font>
}
Where 'name' is the name you give this particular style, 'parent' is
the name of the parent style the attributes of which this one will
inherit. <color> can be specified as a string "#rrrrggggbbbb",
"#rrrgggbbb", "#rrggbb", or "#rgb", where r g, and b are hex digits,
or as a triplet of floats { r, g, b }.
As an example:
1: style 'button' {
2: bg[NORMAL] = { #ccc }
3: }
4:
5: style 'button_list' = 'button'
6: {
7: font = "-adobe-helvetica-medium-r-normal--*-100-*-*-*-*-*-*"
8: bg[PRELIGHT] = { 0, 0.75, 0 }
9: }
10:
11: widget "main window.*GtkScrolledWindow.*GtkButton*" style "button_list"
12:
Note that the wildcards are important: "*GtkScrolledWindow*" makes
sure that it applies to the scroll window inside "main window" even
if it's bundled in a box or something like that, and "*GtkButton*"
says that the button can be packed up in a box and that the style
will also apply to the child of the button, that is, label. Without
the final asterisk the button label font would not be affected.