rc_get_style_by_paths
function rc_get_style_by_paths(settings:Gtk.Settings, widget_path:String, class_path:String, type:GType):Gtk.Style { // Gjs wrapper for gtk_rc_get_style_by_paths() }
Creates up a Gtk.Style from styles defined in a RC file by providing the raw components used in matching. This function may be useful when creating pseudo-widgets that should be themed like widgets but don't actually have corresponding GTK+ widgets. An example of this would be items inside a GNOME canvas widget.
The action of rc_get_style is similar to: |[ gtk_widget_path (widget, NULL, &path, NULL); gtk_widget_class_path (widget, NULL, &class_path, NULL); gtk_rc_get_style_by_paths (gtk_widget_get_settings (widget), path, class_path, G_OBJECT_TYPE (widget)); ]|
- settings
a Gtk.Settings object
- widget_path
the widget path to use when looking up the style, or null if no matching against the widget path should be done
- class_path
the class path to use when looking up the style, or null if no matching against the class path should be done.
- type
a type that will be used along with parent types of this type when matching against class styles, or #G_TYPE_NONE
- Returns
A style created by matching with the supplied paths, or null if nothing matching was specified and the default style should be used. The returned value is owned by GTK+ as part of an internal cache, so you must call GObject.ref on the returned value if you want to keep a reference to it.