### Function

# GObject param_spec_variant

since: 2.26

#### Declaration [src]

    GParamSpec*
    g_param_spec_variant (
      const gchar* name,
      const gchar* nick,
      const gchar* blurb,
      const GVariantType* type,
      GVariant* default_value,
      GParamFlags flags
    )

#### Description [src]

Creates a new `GParamSpecVariant` instance specifying a `GVariant` property.

If `default_value` is floating, it is consumed.

See `g_param_spec_internal()` for details on property names.

Available since: 2.26

#### Parameters

`name`

  Type: `const gchar*`

  Canonical name of the property specified.

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

`nick`

  Type: `const gchar*`

  Nick name for the property specified.

  The argument can be `NULL`.
  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`blurb`

  Type: `const gchar*`

  Description of the property specified.

  The argument can be `NULL`.
  The data is owned by the caller of the function.
  The value is a NUL terminated UTF-8 string.

`type`

  Type: `GVariantType`

  A `GVariantType`.

  The data is owned by the caller of the function.

`default_value`

  Type: `GVariant`

  A `GVariant` of type `type` to use as the default value, or `NULL`.

  The argument can be `NULL`.
  The called function takes ownership of the data, and is responsible for freeing it.

`flags`

  Type: `GParamFlags`

  Flags for the property specified.

#### Return value

Type: `GParamSpec`

The newly created `GParamSpec`.

The caller of the function takes ownership of the data, and is responsible for freeing it.