### Method

# Gio Settings set

since: 2.26

#### Declaration [src]

    gboolean
    g_settings_set (
      GSettings* settings,
      const gchar* key,
      const gchar* format,
      ...
    )

#### Description [src]

Sets `key` in `settings` to `value`.

A convenience function that combines `g_settings_set_value()` with `g_variant_new()`.

It is a programmer error to give a `key` that isn’t contained in the schema for `settings` or for the `GVariantType` of `format` to mismatch the type given in the schema.

Available since: 2.26

This method is not directly available to language bindings.

#### Parameters

`key`

  Type: `const gchar*`

  The key to set the value for.

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

`format`

  Type: `const gchar*`

  A `GVariant` format string.

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

`...`

  Type: ``

  Arguments as per `format`.

#### Return value

Type: `gboolean`

True if setting the key succeeded, false if the key was not writable.