set_flags


Description:

public bool set_flags (string key, uint value)

Looks up the flags type nicks for the bits specified by value, puts them in an array of strings and writes the array to key, within this.

It is a programmer error to give a key that isn’t contained in the schema for this or is not marked as a flags type, or for value to contain any bits that are not value for the named type.

After performing the write, accessing key directly with [method@Gio.Settings.get_strv] will return an array of ‘nicks’; one for each bit in value.

Parameters:

this

the settings object

key

the key to set the value for

value

a flags value

Returns:

true if the set succeeds, false otherwise