Gtk.StyleProvider¶
- Implementations:
Methods¶
|
|
|
|
|
Virtual Methods¶
|
|
|
|
|
Properties¶
None
Signals¶
None
Fields¶
None
Class Details¶
- class Gtk.StyleProvider¶
- Bases:
- Structure:
Gtk.StyleProvider
is an interface used to provide style information to aGtk.StyleContext
. SeeGtk.StyleContext.add_provider
() andGtk.StyleContext.add_provider_for_screen
().- get_icon_factory(path)[source]¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to query- Returns:
The icon factory to use for path, or
None
- Return type:
Returns the
Gtk.IconFactory
defined to be in use for path, orNone
if none is defined.New in version 3.0.
Deprecated since version 3.8: Will always return
None
for all GTK-provided style providers.
- get_style(path)[source]¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to query- Returns:
a
Gtk.StyleProperties
containing the style settings affecting path- Return type:
Returns the style settings affecting a widget defined by path, or
None
if self doesn’t contemplate styling path.New in version 3.0.
Deprecated since version 3.8: Will always return
None
for all GTK-provided style providers as the interface cannot correctly work the way CSS is specified.
- get_style_property(path, state, pspec)[source]¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to querystate (
Gtk.StateFlags
) – state to query the style property forpspec (
GObject.ParamSpec
) – TheGObject.ParamSpec
to query
- Returns:
True
if the property was found and has a value,False
otherwise- value:
return location for the property value
- Return type:
(
bool
, value:GObject.Value
)
Looks up a widget style property as defined by self for the widget represented by path.
New in version 3.0.
- do_get_icon_factory(path) virtual¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to query- Returns:
The icon factory to use for path, or
None
- Return type:
Returns the
Gtk.IconFactory
defined to be in use for path, orNone
if none is defined.New in version 3.0.
Deprecated since version 3.8: Will always return
None
for all GTK-provided style providers.
- do_get_style(path) virtual¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to query- Returns:
a
Gtk.StyleProperties
containing the style settings affecting path- Return type:
Returns the style settings affecting a widget defined by path, or
None
if provider doesn’t contemplate styling path.New in version 3.0.
Deprecated since version 3.8: Will always return
None
for all GTK-provided style providers as the interface cannot correctly work the way CSS is specified.
- do_get_style_property(path, state, pspec) virtual¶
- Parameters:
path (
Gtk.WidgetPath
) –Gtk.WidgetPath
to querystate (
Gtk.StateFlags
) – state to query the style property forpspec (
GObject.ParamSpec
) – TheGObject.ParamSpec
to query
- Returns:
True
if the property was found and has a value,False
otherwise- value:
return location for the property value
- Return type:
(
bool
, value:GObject.Value
)
Looks up a widget style property as defined by provider for the widget represented by path.
New in version 3.0.