Flags

Details

class GObject.BindingFlags(value)

Bases: GObject.GFlags

Flags to be passed to GObject.Object.bind_property() or GObject.Object.bind_property_full().

This enumeration can be extended at later date.

New in version 2.26.

DEFAULT = 0

The default binding; if the source property changes, the target property is updated with its value.

BIDIRECTIONAL = 1

Bidirectional binding; if either the property of the source or the property of the target changes, the other is updated.

SYNC_CREATE = 2

Synchronize the values of the source and target properties when creating the binding; the direction of the synchronization is always from the source to the target.

INVERT_BOOLEAN = 4

If the two properties being bound are booleans, setting one to True will result in the other being set to False and vice versa. This flag will only work for boolean properties, and cannot be used when passing custom transformation functions to GObject.Object.bind_property_full().

class GObject.ConnectFlags(value)

Bases: GLib.Flags

The connection flags are used to specify the behaviour of a signal’s connection.

DEFAULT = 0

Default behaviour (no special flags).

New in version 2.74.

AFTER = 1

If set, the handler should be called after the default handler of the signal. Normally, the handler is called before the default handler.

SWAPPED = 2

If set, the instance and data should be swapped when calling the handler; see g_signal_connect_swapped() for an example.

class GObject.GFlags(value)

Bases: GLib.Flags

Base type for all flags types with a GType

Parameters:

value (int) –

class GObject.ParamFlags(value)

Bases: GLib.Flags

Through the GObject.ParamFlags flag values, certain aspects of parameters can be configured.

See also: GObject.PARAM_STATIC_STRINGS

DEPRECATED = -2147483648

the parameter is deprecated and will be removed in a future version. A warning will be generated if it is used while running with G_ENABLE_DIAGNOSTIC=1.

New in version 2.26.

READABLE = 1

the parameter is readable

EXPLICIT_NOTIFY = 1073741824

calls to GObject.Object.set_property() for this property will not automatically result in a “notify” signal being emitted: the implementation must call GObject.Object.notify() themselves in case the property actually changes.

New in version 2.42.

STATIC_BLURB = 128

the string used as blurb when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter.

New in version 2.8.

LAX_VALIDATION = 16

upon parameter conversion (see GObject.param_value_convert()) strict validation is not required

WRITABLE = 2

the parameter is writable

READWRITE = 3

alias for GObject.ParamFlags.READABLE | GObject.ParamFlags.WRITABLE

PRIVATE = 32

internal

STATIC_NAME = 32

the string used as name when constructing the parameter is guaranteed to remain valid and unmodified for the lifetime of the parameter.

New in version 2.8.

CONSTRUCT = 4

the parameter will be set upon object construction

STATIC_NICK = 64

the string used as nick when constructing the parameter is guaranteed to remain valid and unmmodified for the lifetime of the parameter.

New in version 2.8.

CONSTRUCT_ONLY = 8

the parameter can only be set upon object construction

class GObject.SignalFlags(value)

Bases: GLib.Flags

The signal flags are used to specify a signal’s behaviour.

RUN_FIRST = 1

Invoke the object method handler in the first emission stage.

MUST_COLLECT = 128

Varargs signal emission will always collect the arguments, even if there are no signal handlers connected.

New in version 2.30.

ACCUMULATOR_FIRST_RUN = 131072

Only used in GObject.SignalAccumulator accumulator functions for the #GSignalInvocationHint::run_type field to mark the first call to the accumulator function for a signal emission.

New in version 2.68.

DETAILED = 16

This signal supports “::detail” appendices to the signal name upon handler connections and emissions.

RUN_LAST = 2

Invoke the object method handler in the third emission stage.

DEPRECATED = 256

The signal is deprecated and will be removed in a future version. A warning will be generated if it is connected while running with G_ENABLE_DIAGNOSTIC=1.

New in version 2.32.

ACTION = 32

Action signals are signals that may freely be emitted on alive objects from user code via g_signal_emit() and friends, without the need of being embedded into extra code that performs pre or post emission adjustments on the object. They can also be thought of as object methods which can be called generically by third-party code.

RUN_CLEANUP = 4

Invoke the object method handler in the last emission stage.

NO_HOOKS = 64

No emissions hooks are supported for this signal.

NO_RECURSE = 8

Signals being emitted for an object while currently being in emission for this very object will not be emitted recursively, but instead cause the first emission to be restarted.

class GObject.SignalMatchType(value)

Bases: GLib.Flags

The match types specify what GObject.signal_handlers_block_matched(), GObject.signal_handlers_unblock_matched() and GObject.signal_handlers_disconnect_matched() match signals by.

ID = 1

The signal id must be equal.

DATA = 16

The closure data must be the same.

DETAIL = 2

The signal detail must be equal.

UNBLOCKED = 32

Only unblocked signals may be matched.

CLOSURE = 4

The closure must be the same.

FUNC = 8

The C closure callback must be the same.

class GObject.TypeDebugFlags(value)

Bases: GLib.Flags

These flags used to be passed to GObject.type_init_with_debug_flags() which is now deprecated.

If you need to enable debugging features, use the GOBJECT_DEBUG environment variable.

Deprecated since version 2.36: GObject.type_init() is now done automatically

NONE = 0

Print no messages

OBJECTS = 1

Print messages about object bookkeeping

SIGNALS = 2

Print messages about signal emissions

INSTANCE_COUNT = 4

Keep a count of instances of each type

MASK = 7

Mask covering all debug flags

class GObject.TypeFlags(value)

Bases: GLib.Flags

Bit masks used to check or determine characteristics of a type.

NONE = 0

No special flags.

New in version 2.74.

DEPRECATED = 128

The type is deprecated and may be removed in a future version. A warning will be emitted if it is instantiated while running with G_ENABLE_DIAGNOSTIC=1.

New in version 2.76.

ABSTRACT = 16

Indicates an abstract type. No instances can be created for an abstract type

VALUE_ABSTRACT = 32

Indicates an abstract value type, i.e. a type that introduces a value table, but can’t be used for GObject.Value.init()

FINAL = 64

Indicates a final type. A final type is a non-derivable leaf node in a deep derivable type hierarchy tree.

New in version 2.70.

class GObject.TypeFundamentalFlags(value)

Bases: GLib.Flags

Bit masks used to check or determine specific characteristics of a fundamental type.

CLASSED = 1

Indicates a classed type

INSTANTIATABLE = 2

Indicates an instantiatable type (implies classed)

DERIVABLE = 4

Indicates a flat derivable type

DEEP_DERIVABLE = 8

Indicates a deep derivable type (implies derivable)