GObject.enum_get_value_by_name
Description: Reference for GObject.enum_get_value_by_name

### Function

# GObjectenum_get_value_by_name

since: 2.0

#### Declaration

    GEnumValue*
    g_enum_get_value_by_name (
      GEnumClass* enum_class,
      const gchar* name
    )

#### Description

Looks up a `GEnumValue` by name.

Available since: 2.0

#### Parameters

`enum_class`

  Type: `GEnumClass`

  A `GEnumClass`.

  The data is owned by the caller of the function.

`name`

  Type: `const gchar*`

  The name to look up.

  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

#### Return value

Type: `GEnumValue`

The `GEnumValue` with name `name`, or `NULL` if the enumeration doesn’t have a member with that name.

The data is owned by the called function.
The return value can be `NULL`.