will result in the active-widget CSS class on the widget instance being
applied when active is TRUE, and active-widget being removed when
active is FALSE.
The binding will automatically be removed when either the source or target
instances are finalized. To remove the binding without affecting the source
or target, call GObject.Object.unref on the returned binding. It is
recommended to only call GObject.Object.unref when it is clear that
both source and target will outlive the binding.
This function is not thread safe. A source can have multiple bindings.
Creates a binding between a property on
sourceand a CSS class ontarget.Whenever
source_propertyis changed thetarget_css_classis toggled either on or off ontargetusing the boolean value ofsource_property.For instance:
will result in the
active-widgetCSS class on the widget instance being applied whenactiveisTRUE, andactive-widgetbeing removed whenactiveisFALSE.The binding will automatically be removed when either the
sourceortargetinstances are finalized. To remove the binding without affecting thesourceortarget, call GObject.Object.unref on the returned binding. It is recommended to only call GObject.Object.unref when it is clear that bothsourceandtargetwill outlive the binding.This function is not thread safe. A source can have multiple bindings.
See also: Adw.bind_property_to_css_class_full.