Function

Gimpenum_get_value

Declaration [src]

gboolean
gimp_enum_get_value (
  GType enum_type,
  gint value,
  const gchar** value_name,
  const gchar** value_nick,
  const gchar** value_desc,
  const gchar** value_help
)

Description [src]

Checks if value is valid for the enum registered as enum_type. If the value exists in that enum, its name, nick and its translated description and help are returned (if value_name, value_nick, value_desc and value_help are not NULL).

Available since:2.2

Parameters

enum_type GType
 

The GType of a registered enum.

value gint
 

An integer value.

value_name const gchar**
 

Return location for the value’s name, or NULL.

 The argument will be set by the function.
 The argument can be NULL.
 The called function takes ownership of the data, and is responsible for freeing it.
 The value is a NUL terminated UTF-8 string.
value_nick const gchar**
 

Return location for the value’s nick, or NULL.

 The argument will be set by the function.
 The argument can be NULL.
 The called function takes ownership of the data, and is responsible for freeing it.
 The value is a NUL terminated UTF-8 string.
value_desc const gchar**
 

Return location for the value’s translated description, or NULL.

 The argument will be set by the function.
 The argument can be NULL.
 The called function takes ownership of the data, and is responsible for freeing it.
 The value is a NUL terminated UTF-8 string.
value_help const gchar**
 

Return location for the value’s translated help, or NULL.

 The argument will be set by the function.
 The argument can be NULL.
 The called function takes ownership of the data, and is responsible for freeing it.
 The value is a NUL terminated UTF-8 string.

Return value

Returns: gboolean
 

TRUE if value is valid for the enum_type, FALSE otherwise.