Passing in the filename of your rc file. This will cause GTK to parse this file, and use the style settings for the widget types defined there.
If you wish to have a special set of widgets
that can take on a different style from others, or any other logical division
of widgets, use a call to:
Your newly created widget will be assigned the name you give. This will allow you to change the attributes of this widget by name through the rc file.
If we use a call something like this:
button = GtkButton("Special Button") button.set_name("special button")
Then this button is given the name "special button" and may be addressed by name in the rc file as "special button.GtkButton". [<--- Verify ME!]
The example rc file below, sets the properties
of the main window, and lets all children of that main window inherit the
style described by the "main button" style. The code used in the application
window = GtkWindow(WINDOW_TOPLEVEL) window.set_name("main window")
And then the style is defined in the rc
widget "main window.*GtkButton*" style "main_button"
Which sets all the Button widgets in the "main window" to the "main_buttons" style as defined in the rc file.
As you can see, this is a fairly powerful and flexible system. Use your imagination as to how best to take advantage of this.