Functions¶
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- Xfconf.array_free(arr)¶
- Parameters:
arr ([
GObject.Value]) – AGLib.PtrArrayofGObject.Values.
Properly frees a
GLib.PtrArraystructure containing a list ofGObject.Values. This will also cause the contents of the values to be freed as well.
- Xfconf.init()¶
- Raises:
- Returns:
Trueif the library was initialized succesfully,Falseon error. If there is an error error will be set.- Return type:
Initializes the Xfconf library. Can be called multiple times with no adverse effects.
- Xfconf.list_channels()¶
- Returns:
A newly-allocated array of strings. Free with
GLib.strfreev() when no longer needed.- Return type:
[
str]
Lists all channels known in the Xfconf configuration store.
- Xfconf.named_struct_register(struct_name, n_members, member_types)¶
- Parameters:
struct_name (
str) – The unique name of the struct to register.n_members (
int) – The number of data members in the struct.member_types (
GObject.GType) – An array of theGObject.GTypes of the struct members.
Registers a named struct for use with
Xfconf.Channel.get_named_struct() andXfconf.Channel.set_named_struct().
- Xfconf.property_bind(channel, xfconf_property, xfconf_property_type, object, object_property)¶
- Parameters:
channel (
Xfconf.Channel) – AnXfconf.Channel.xfconf_property (
str) – A property on channel.xfconf_property_type (
GObject.GType) – The type of xfconf_property.object (
object) – AGObject.Object.object_property (
str) – A valid property on object.
- Returns:
an ID number that can be used to later remove the binding.
- Return type:
Binds an Xfconf property to a
GObject.Objectproperty. If the property is changed via either theGObject.Objector Xfconf, the corresponding property will also be updated. The binding is initialized from the Xfconf property, i.e. the initial value of theGObject.Objectproperty is overwritten.Note that xfconf_property_type is required since xfconf_property may or may not already exist in the Xfconf store. The type of object_property will be determined automatically. If the two types do not match, a conversion will be attempted.
If you are binding a #GdkColor or #GdkRGBA property, pass #G_TYPE_PTR_ARRAY for xfconf_property_type.
- Xfconf.property_bind_gdkcolor(channel, xfconf_property, object, object_property)¶
- Parameters:
channel (
Xfconf.Channel) – AnXfconf.Channel.xfconf_property (
str) – A property on channel.object (
object) – AGObject.Object.object_property (
str) – A valid property on object.
- Returns:
an ID number that can be used to later remove the binding.
- Return type:
Binds an Xfconf property to a
GObject.Objectproperty of type GDK_TYPE_COLOR (aka a #GdkColor struct). If the property is changed via either theGObject.Objector Xfconf, the corresponding property will also be updated. The binding is initialized from the Xfconf property, i.e. the initial value of theGObject.Objectproperty is overwritten.This is a special-case binding; the GdkColor struct is not ideal as-is for binding to a property, so it is stored in the Xfconf store as four 16-bit unsigned ints (red, green, blue, alpha). Since GdkColor (currently) only supports RGB and not RGBA, the last value will always be set to 0xFFFF.
Deprecated since version 4.19.3: Use
Xfconf.property_bind() with #G_TYPE_PTR_ARRAY instead.
- Xfconf.property_bind_gdkrgba(channel, xfconf_property, object, object_property)¶
- Parameters:
channel (
Xfconf.Channel) – AnXfconf.Channel.xfconf_property (
str) – A property on channel.object (
object) – AGObject.Object.object_property (
str) – A valid property on object.
- Returns:
an ID number that can be used to later remove the binding.
- Return type:
Binds an Xfconf property to a
GObject.Objectproperty of type GDK_TYPE_RGBA (aka a #GdkRGBA struct). If the property is changed via either theGObject.Objector Xfconf, the corresponding property will also be updated. The binding is initialized from the Xfconf property, i.e. the initial value of theGObject.Objectproperty is overwritten.This is a special-case binding; the GdkRGBA struct is not ideal as-is for binding to a property, so it is stored in the Xfconf store as four 16-bit unsigned ints (red, green, blue, alpha).
New in version 4.12.1.
Deprecated since version 4.19.3: Use
Xfconf.property_bind() with #G_TYPE_PTR_ARRAY instead.
- Xfconf.property_unbind(id)¶
- Parameters:
id (
int) – A binding ID number.
Removes an Xfconf/
GObject.Objectproperty binding based on the binding ID number. SeeXfconf.property_bind().
- Xfconf.property_unbind_all(channel_or_object)¶
- Parameters:
channel_or_object (
object) – AGObject.ObjectorXfconf.Channel.
Unbinds all Xfconf channel bindings (see
Xfconf.property_bind()) to object. If object is anXfconf.Channel, it will unbind all xfconf properties on that channel. If object is a regularGObject.Objectwith properties bound to a channel, all those bindings will be removed.
- Xfconf.property_unbind_by_property(channel, xfconf_property, object, object_property)¶
- Parameters:
channel (
Xfconf.Channel) – AnXfconf.Channel.xfconf_property (
str) – A bound property on channel.object (
object) – AGObject.Object.object_property (
str) – A bound property on object.
Causes an Xfconf channel previously bound to a
GObject.Objectproperty (seeXfconf.property_bind()) to no longer be bound.
- Xfconf.shutdown()¶
Shuts down and frees any resources consumed by the Xfconf library. If
Xfconf.init() is called multiple times,Xfconf.shutdown() must be called an equal number of times to shut down the library.
- Xfconf.value_get_int16(value)¶
- Parameters:
value (
GObject.Value) – AGObject.Value.- Returns:
A gint16.
- Return type:
Retrieves a 16-bit signed value from value.
- Xfconf.value_get_uint16(value)¶
- Parameters:
value (
GObject.Value) – AGObject.Value.- Returns:
A guint16.
- Return type:
Retrieves a 16-bit unsigned value from value.
- Xfconf.value_set_int16(value, v_int16)¶
- Parameters:
value (
GObject.Value) – AGObject.Value.v_int16 (
int) – A gint16.
Sets value using a signed 16-bit integer.
- Xfconf.value_set_uint16(value, v_uint16)¶
- Parameters:
value (
GObject.Value) – AGObject.Value.v_uint16 (
int) – A guint16.
Sets value using an unsigned 16-bit integer.