Enums

Members

Static functions

completeTypeInfo
void completeTypeInfo(GType gEnumType, GTypeInfo info, GEnumValue* constValues)

This function is meant to be called from the complete_type_info function of a #GTypePlugin implementation, as in the following

enumToString
string enumToString(GType gEnumType, int value)

Pretty-prints @value in the form of the enum’s name.

flagsToString
string flagsToString(GType flagsType, uint value)

Pretty-prints @value in the form of the flag names separated by | and sorted. Any extra bits will be shown at the end as a hexadecimal number.

getValue
GEnumValue* getValue(GEnumClass* enumClass, int value)

Returns the #GEnumValue for a value.

getValueByName
GEnumValue* getValueByName(GEnumClass* enumClass, string name)

Looks up a #GEnumValue by name.

getValueByNick
GEnumValue* getValueByNick(GEnumClass* enumClass, string nick)

Looks up a #GEnumValue by nickname.

registerStatic
GType registerStatic(string name, GEnumValue* constStaticValues)

Registers a new static enumeration type with the name @name.

Meta