GObject#
- class ignis.gobject.IgnisGObject(*args: Any, **kwargs: Any)#
Bases: GObject.Object.
A base class for all services and widgets (and some utils). Mainly, it is the same GObject.Object, but with some improvements.
It provides support for
Binding
.It offers easier control over properties (without the need for the
.props
attribute).
- notify_all(without: list[str] | str | None = None) None #
Notify all properties.
- Parameters:
without (list[str] | str | None, optional) -- Property or list of properties that will not be notified.
- notify_list(*args) None #
Notify list of properties. You can pass unlimited number of property names as arguments.
- bind_property2(source_property: str, target: gi.repository.GObject.Object, target_property: str, transform: Callable | None = None) None #
Bind
source_property
onself
withtarget_property
ontarget
.- Parameters:
source_property (
str
) -- The property onself
to bind.target (
GObject.Object
) -- the targetGObject.Object
.target_property (
str
) -- the property ontarget
to bind.transform (
Callable
, optional) -- The function that accepts a new property value and returns the processed value.
- class ignis.gobject.Binding(*args: Any, **kwargs: Any)#
An object that describe binding.
- Properties:
target (
GObject.Object
, required, read-only): Target GObject.target_property (
str
, required, read-only): Property on target GObject.transform (
Callable
, optional, read-only): The function that accepts a new property value and returns the processed value.