Github User Fetcher 1.0.0
C Application with Server and GUI
Loading...
Searching...
No Matches
gsettings.h File Reference
#include <gio/gsettingsschema.h>
#include <gio/giotypes.h>

Go to the source code of this file.

Data Structures

struct  _GSettingsClass
 
struct  _GSettings
 

Macros

#define G_TYPE_SETTINGS   (g_settings_get_type ())
 
#define G_SETTINGS(inst)
 
#define G_SETTINGS_CLASS(class)
 
#define G_IS_SETTINGS(inst)   (G_TYPE_CHECK_INSTANCE_TYPE ((inst), G_TYPE_SETTINGS))
 
#define G_IS_SETTINGS_CLASS(class)   (G_TYPE_CHECK_CLASS_TYPE ((class), G_TYPE_SETTINGS))
 
#define G_SETTINGS_GET_CLASS(inst)
 

Typedefs

typedef struct _GSettingsPrivate GSettingsPrivate
 
typedef struct _GSettingsClass GSettingsClass
 
typedef GVariant *(* GSettingsBindSetMapping) (const GValue *value, const GVariantType *expected_type, gpointer user_data)
 
typedef gboolean(* GSettingsBindGetMapping) (GValue *value, GVariant *variant, gpointer user_data)
 
typedef gboolean(* GSettingsGetMapping) (GVariant *value, gpointer *result, gpointer user_data)
 

Enumerations

enum  GSettingsBindFlags {
  G_SETTINGS_BIND_DEFAULT , G_SETTINGS_BIND_GET = (1<<0) , G_SETTINGS_BIND_SET = (1<<1) , G_SETTINGS_BIND_NO_SENSITIVITY = (1<<2) ,
  G_SETTINGS_BIND_GET_NO_CHANGES = (1<<3) , G_SETTINGS_BIND_INVERT_BOOLEAN = (1<<4)
}
 

Functions

GIO_AVAILABLE_IN_ALL GType g_settings_get_type (void)
 
const gchar *const * g_settings_list_schemas (void)
 
const gchar *const * g_settings_list_relocatable_schemas (void)
 
GIO_AVAILABLE_IN_ALL GSettingsg_settings_new (const gchar *schema_id)
 
GIO_AVAILABLE_IN_ALL GSettingsg_settings_new_with_path (const gchar *schema_id, const gchar *path)
 
GIO_AVAILABLE_IN_ALL GSettingsg_settings_new_with_backend (const gchar *schema_id, GSettingsBackend *backend)
 
GIO_AVAILABLE_IN_ALL GSettingsg_settings_new_with_backend_and_path (const gchar *schema_id, GSettingsBackend *backend, const gchar *path)
 
GIO_AVAILABLE_IN_2_32 GSettingsg_settings_new_full (GSettingsSchema *schema, GSettingsBackend *backend, const gchar *path)
 
GIO_AVAILABLE_IN_ALL gchar ** g_settings_list_children (GSettings *settings)
 
gchar ** g_settings_list_keys (GSettings *settings)
 
GVariantg_settings_get_range (GSettings *settings, const gchar *key)
 
gboolean g_settings_range_check (GSettings *settings, const gchar *key, GVariant *value)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_value (GSettings *settings, const gchar *key, GVariant *value)
 
GIO_AVAILABLE_IN_ALL GVariantg_settings_get_value (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_2_40 GVariantg_settings_get_user_value (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_2_40 GVariantg_settings_get_default_value (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set (GSettings *settings, const gchar *key, const gchar *format,...)
 
GIO_AVAILABLE_IN_ALL void g_settings_get (GSettings *settings, const gchar *key, const gchar *format,...)
 
GIO_AVAILABLE_IN_ALL void g_settings_reset (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gint g_settings_get_int (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_int (GSettings *settings, const gchar *key, gint value)
 
GIO_AVAILABLE_IN_2_50 gint64 g_settings_get_int64 (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_2_50 gboolean g_settings_set_int64 (GSettings *settings, const gchar *key, gint64 value)
 
GIO_AVAILABLE_IN_2_32 guint g_settings_get_uint (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_2_32 gboolean g_settings_set_uint (GSettings *settings, const gchar *key, guint value)
 
GIO_AVAILABLE_IN_2_50 guint64 g_settings_get_uint64 (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_2_50 gboolean g_settings_set_uint64 (GSettings *settings, const gchar *key, guint64 value)
 
GIO_AVAILABLE_IN_ALL gcharg_settings_get_string (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_string (GSettings *settings, const gchar *key, const gchar *value)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_get_boolean (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_boolean (GSettings *settings, const gchar *key, gboolean value)
 
GIO_AVAILABLE_IN_ALL gdouble g_settings_get_double (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_double (GSettings *settings, const gchar *key, gdouble value)
 
GIO_AVAILABLE_IN_ALL gchar ** g_settings_get_strv (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_strv (GSettings *settings, const gchar *key, const gchar *const *value)
 
GIO_AVAILABLE_IN_ALL gint g_settings_get_enum (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_enum (GSettings *settings, const gchar *key, gint value)
 
GIO_AVAILABLE_IN_ALL guint g_settings_get_flags (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_set_flags (GSettings *settings, const gchar *key, guint value)
 
GIO_AVAILABLE_IN_ALL GSettingsg_settings_get_child (GSettings *settings, const gchar *name)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_is_writable (GSettings *settings, const gchar *name)
 
GIO_AVAILABLE_IN_ALL void g_settings_delay (GSettings *settings)
 
GIO_AVAILABLE_IN_ALL void g_settings_apply (GSettings *settings)
 
GIO_AVAILABLE_IN_ALL void g_settings_revert (GSettings *settings)
 
GIO_AVAILABLE_IN_ALL gboolean g_settings_get_has_unapplied (GSettings *settings)
 
GIO_AVAILABLE_IN_ALL void g_settings_sync (void)
 
GIO_AVAILABLE_IN_ALL void g_settings_bind (GSettings *settings, const gchar *key, gpointer object, const gchar *property, GSettingsBindFlags flags)
 
GIO_AVAILABLE_IN_ALL void g_settings_bind_with_mapping (GSettings *settings, const gchar *key, gpointer object, const gchar *property, GSettingsBindFlags flags, GSettingsBindGetMapping get_mapping, GSettingsBindSetMapping set_mapping, gpointer user_data, GDestroyNotify destroy)
 
GIO_AVAILABLE_IN_2_82 void g_settings_bind_with_mapping_closures (GSettings *settings, const char *key, GObject *object, const char *property, GSettingsBindFlags flags, GClosure *get_mapping, GClosure *set_mapping)
 
GIO_AVAILABLE_IN_ALL void g_settings_bind_writable (GSettings *settings, const gchar *key, gpointer object, const gchar *property, gboolean inverted)
 
GIO_AVAILABLE_IN_ALL void g_settings_unbind (gpointer object, const gchar *property)
 
GIO_AVAILABLE_IN_2_32 GActiong_settings_create_action (GSettings *settings, const gchar *key)
 
GIO_AVAILABLE_IN_ALL gpointer g_settings_get_mapped (GSettings *settings, const gchar *key, GSettingsGetMapping mapping, gpointer user_data)
 

Macro Definition Documentation

◆ G_IS_SETTINGS

#define G_IS_SETTINGS ( inst)    (G_TYPE_CHECK_INSTANCE_TYPE ((inst), G_TYPE_SETTINGS))

Definition at line 39 of file gsettings.h.

◆ G_IS_SETTINGS_CLASS

#define G_IS_SETTINGS_CLASS ( class)    (G_TYPE_CHECK_CLASS_TYPE ((class), G_TYPE_SETTINGS))

Definition at line 40 of file gsettings.h.

◆ G_SETTINGS

#define G_SETTINGS ( inst)
Value:
#define G_TYPE_SETTINGS
Definition gsettings.h:34
#define G_TYPE_CHECK_INSTANCE_CAST(instance, g_type, c_type)
Definition gtype.h:528

Definition at line 35 of file gsettings.h.

35#define G_SETTINGS(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), \
36 G_TYPE_SETTINGS, GSettings))

◆ G_SETTINGS_CLASS

#define G_SETTINGS_CLASS ( class)
Value:
#define G_TYPE_CHECK_CLASS_CAST(g_class, g_type, c_type)
Definition gtype.h:597

Definition at line 37 of file gsettings.h.

37#define G_SETTINGS_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), \
38 G_TYPE_SETTINGS, GSettingsClass))

◆ G_SETTINGS_GET_CLASS

#define G_SETTINGS_GET_CLASS ( inst)
Value:
#define G_TYPE_INSTANCE_GET_CLASS(instance, g_type, c_type)
Definition gtype.h:571

Definition at line 41 of file gsettings.h.

41#define G_SETTINGS_GET_CLASS(inst) (G_TYPE_INSTANCE_GET_CLASS ((inst), \
42 G_TYPE_SETTINGS, GSettingsClass))

◆ G_TYPE_SETTINGS

#define G_TYPE_SETTINGS   (g_settings_get_type ())

Definition at line 34 of file gsettings.h.

Typedef Documentation

◆ GSettingsBindGetMapping

typedef gboolean(* GSettingsBindGetMapping) (GValue *value, GVariant *variant, gpointer user_data)

GSettingsBindGetMapping: @value: return location for the property value @variant: the GVariant @user_data: user data that was specified when the binding was created

The type for the function that is used to convert from GSettings to an object property. The @value is already initialized to hold values of the appropriate type.

Returns: TRUE if the conversion succeeded, FALSE in case of an error

Definition at line 253 of file gsettings.h.

◆ GSettingsBindSetMapping

typedef GVariant *(* GSettingsBindSetMapping) (const GValue *value, const GVariantType *expected_type, gpointer user_data)

GSettingsBindSetMapping: @value: a GValue containing the property value to map @expected_type: the GVariantType to create @user_data: user data that was specified when the binding was created

The type for the function that is used to convert an object property value to a GVariant for storing it in GSettings.

Returns: a new GVariant holding the data from @value, or NULL in case of an error

Definition at line 237 of file gsettings.h.

◆ GSettingsClass

Definition at line 45 of file gsettings.h.

◆ GSettingsGetMapping

typedef gboolean(* GSettingsGetMapping) (GVariant *value, gpointer *result, gpointer user_data)

GSettingsGetMapping: @value: the GVariant to map, or NULL

Returns
: (out): the result of the mapping @user_data: (closure): the user data that was passed to g_settings_get_mapped()

The type of the function that is used to convert from a value stored in a GSettings to a value that is useful to the application.

If the value is successfully mapped, the result should be stored at

Returns
and TRUE returned. If mapping fails (for example, if @value is not in the right format) then FALSE should be returned.

If @value is NULL then it means that the mapping function is being given a "last chance" to successfully return a valid value. TRUE must be returned in this case.

Returns: TRUE if the conversion succeeded, FALSE in case of an error

Definition at line 277 of file gsettings.h.

◆ GSettingsPrivate

typedef struct _GSettingsPrivate GSettingsPrivate

Definition at line 44 of file gsettings.h.

Enumeration Type Documentation

◆ GSettingsBindFlags

GSettingsBindFlags: @G_SETTINGS_BIND_DEFAULT: Equivalent to G_SETTINGS_BIND_GET|G_SETTINGS_BIND_SET @G_SETTINGS_BIND_GET: Update the GObject property when the setting changes. It is an error to use this flag if the property is not writable. @G_SETTINGS_BIND_SET: Update the setting when the GObject property changes. It is an error to use this flag if the property is not readable. @G_SETTINGS_BIND_NO_SENSITIVITY: Do not try to bind a "sensitivity" property to the writability of the setting @G_SETTINGS_BIND_GET_NO_CHANGES: When set in addition to G_SETTINGS_BIND_GET, set the GObject property value initially from the setting, but do not listen for changes of the setting @G_SETTINGS_BIND_INVERT_BOOLEAN: When passed to g_settings_bind(), uses a pair of mapping functions that invert the boolean value when mapping between the setting and the property. The setting and property must both be booleans. You cannot pass this flag to g_settings_bind_with_mapping().

Flags used when creating a binding. These flags determine in which direction the binding works. The default is to synchronize in both directions.

Enumerator
G_SETTINGS_BIND_DEFAULT 
G_SETTINGS_BIND_GET 
G_SETTINGS_BIND_SET 
G_SETTINGS_BIND_NO_SENSITIVITY 
G_SETTINGS_BIND_GET_NO_CHANGES 
G_SETTINGS_BIND_INVERT_BOOLEAN 

Definition at line 299 of file gsettings.h.

300{
302 G_SETTINGS_BIND_GET = (1<<0),
303 G_SETTINGS_BIND_SET = (1<<1),
GSettingsBindFlags
Definition gsettings.h:300
@ G_SETTINGS_BIND_INVERT_BOOLEAN
Definition gsettings.h:306
@ G_SETTINGS_BIND_SET
Definition gsettings.h:303
@ G_SETTINGS_BIND_GET_NO_CHANGES
Definition gsettings.h:305
@ G_SETTINGS_BIND_NO_SENSITIVITY
Definition gsettings.h:304
@ G_SETTINGS_BIND_DEFAULT
Definition gsettings.h:301
@ G_SETTINGS_BIND_GET
Definition gsettings.h:302

Function Documentation

◆ g_settings_apply()

GIO_AVAILABLE_IN_ALL void g_settings_apply ( GSettings * settings)

◆ g_settings_bind()

GIO_AVAILABLE_IN_ALL void g_settings_bind ( GSettings * settings,
const gchar * key,
gpointer object,
const gchar * property,
GSettingsBindFlags flags )

◆ g_settings_bind_with_mapping()

GIO_AVAILABLE_IN_ALL void g_settings_bind_with_mapping ( GSettings * settings,
const gchar * key,
gpointer object,
const gchar * property,
GSettingsBindFlags flags,
GSettingsBindGetMapping get_mapping,
GSettingsBindSetMapping set_mapping,
gpointer user_data,
GDestroyNotify destroy )

◆ g_settings_bind_with_mapping_closures()

GIO_AVAILABLE_IN_2_82 void g_settings_bind_with_mapping_closures ( GSettings * settings,
const char * key,
GObject * object,
const char * property,
GSettingsBindFlags flags,
GClosure * get_mapping,
GClosure * set_mapping )

◆ g_settings_bind_writable()

GIO_AVAILABLE_IN_ALL void g_settings_bind_writable ( GSettings * settings,
const gchar * key,
gpointer object,
const gchar * property,
gboolean inverted )

◆ g_settings_create_action()

GIO_AVAILABLE_IN_2_32 GAction * g_settings_create_action ( GSettings * settings,
const gchar * key )

◆ g_settings_delay()

GIO_AVAILABLE_IN_ALL void g_settings_delay ( GSettings * settings)

◆ g_settings_get()

GIO_AVAILABLE_IN_ALL void g_settings_get ( GSettings * settings,
const gchar * key,
const gchar * format,
... )

◆ g_settings_get_boolean()

GIO_AVAILABLE_IN_ALL gboolean g_settings_get_boolean ( GSettings * settings,
const gchar * key )

◆ g_settings_get_child()

GIO_AVAILABLE_IN_ALL GSettings * g_settings_get_child ( GSettings * settings,
const gchar * name )

◆ g_settings_get_default_value()

GIO_AVAILABLE_IN_2_40 GVariant * g_settings_get_default_value ( GSettings * settings,
const gchar * key )

◆ g_settings_get_double()

GIO_AVAILABLE_IN_ALL gdouble g_settings_get_double ( GSettings * settings,
const gchar * key )

◆ g_settings_get_enum()

GIO_AVAILABLE_IN_ALL gint g_settings_get_enum ( GSettings * settings,
const gchar * key )

◆ g_settings_get_flags()

GIO_AVAILABLE_IN_ALL guint g_settings_get_flags ( GSettings * settings,
const gchar * key )

◆ g_settings_get_has_unapplied()

GIO_AVAILABLE_IN_ALL gboolean g_settings_get_has_unapplied ( GSettings * settings)

◆ g_settings_get_int()

GIO_AVAILABLE_IN_ALL gint g_settings_get_int ( GSettings * settings,
const gchar * key )

◆ g_settings_get_int64()

GIO_AVAILABLE_IN_2_50 gint64 g_settings_get_int64 ( GSettings * settings,
const gchar * key )

◆ g_settings_get_mapped()

GIO_AVAILABLE_IN_ALL gpointer g_settings_get_mapped ( GSettings * settings,
const gchar * key,
GSettingsGetMapping mapping,
gpointer user_data )

◆ g_settings_get_range()

GVariant * g_settings_get_range ( GSettings * settings,
const gchar * key )

◆ g_settings_get_string()

GIO_AVAILABLE_IN_ALL gchar * g_settings_get_string ( GSettings * settings,
const gchar * key )

◆ g_settings_get_strv()

GIO_AVAILABLE_IN_ALL gchar ** g_settings_get_strv ( GSettings * settings,
const gchar * key )

◆ g_settings_get_type()

GIO_AVAILABLE_IN_ALL GType g_settings_get_type ( void )

◆ g_settings_get_uint()

GIO_AVAILABLE_IN_2_32 guint g_settings_get_uint ( GSettings * settings,
const gchar * key )

◆ g_settings_get_uint64()

GIO_AVAILABLE_IN_2_50 guint64 g_settings_get_uint64 ( GSettings * settings,
const gchar * key )

◆ g_settings_get_user_value()

GIO_AVAILABLE_IN_2_40 GVariant * g_settings_get_user_value ( GSettings * settings,
const gchar * key )

◆ g_settings_get_value()

GIO_AVAILABLE_IN_ALL GVariant * g_settings_get_value ( GSettings * settings,
const gchar * key )

◆ g_settings_is_writable()

GIO_AVAILABLE_IN_ALL gboolean g_settings_is_writable ( GSettings * settings,
const gchar * name )

◆ g_settings_list_children()

GIO_AVAILABLE_IN_ALL gchar ** g_settings_list_children ( GSettings * settings)

◆ g_settings_list_keys()

gchar ** g_settings_list_keys ( GSettings * settings)

◆ g_settings_list_relocatable_schemas()

const gchar *const * g_settings_list_relocatable_schemas ( void )

◆ g_settings_list_schemas()

const gchar *const * g_settings_list_schemas ( void )

◆ g_settings_new()

GIO_AVAILABLE_IN_ALL GSettings * g_settings_new ( const gchar * schema_id)

◆ g_settings_new_full()

GIO_AVAILABLE_IN_2_32 GSettings * g_settings_new_full ( GSettingsSchema * schema,
GSettingsBackend * backend,
const gchar * path )

◆ g_settings_new_with_backend()

GIO_AVAILABLE_IN_ALL GSettings * g_settings_new_with_backend ( const gchar * schema_id,
GSettingsBackend * backend )

◆ g_settings_new_with_backend_and_path()

GIO_AVAILABLE_IN_ALL GSettings * g_settings_new_with_backend_and_path ( const gchar * schema_id,
GSettingsBackend * backend,
const gchar * path )

◆ g_settings_new_with_path()

GIO_AVAILABLE_IN_ALL GSettings * g_settings_new_with_path ( const gchar * schema_id,
const gchar * path )

◆ g_settings_range_check()

gboolean g_settings_range_check ( GSettings * settings,
const gchar * key,
GVariant * value )

◆ g_settings_reset()

GIO_AVAILABLE_IN_ALL void g_settings_reset ( GSettings * settings,
const gchar * key )

◆ g_settings_revert()

GIO_AVAILABLE_IN_ALL void g_settings_revert ( GSettings * settings)

◆ g_settings_set()

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

◆ g_settings_set_boolean()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_boolean ( GSettings * settings,
const gchar * key,
gboolean value )

◆ g_settings_set_double()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_double ( GSettings * settings,
const gchar * key,
gdouble value )

◆ g_settings_set_enum()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_enum ( GSettings * settings,
const gchar * key,
gint value )

◆ g_settings_set_flags()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_flags ( GSettings * settings,
const gchar * key,
guint value )

◆ g_settings_set_int()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_int ( GSettings * settings,
const gchar * key,
gint value )

◆ g_settings_set_int64()

GIO_AVAILABLE_IN_2_50 gboolean g_settings_set_int64 ( GSettings * settings,
const gchar * key,
gint64 value )

◆ g_settings_set_string()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_string ( GSettings * settings,
const gchar * key,
const gchar * value )

◆ g_settings_set_strv()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_strv ( GSettings * settings,
const gchar * key,
const gchar *const * value )

◆ g_settings_set_uint()

GIO_AVAILABLE_IN_2_32 gboolean g_settings_set_uint ( GSettings * settings,
const gchar * key,
guint value )

◆ g_settings_set_uint64()

GIO_AVAILABLE_IN_2_50 gboolean g_settings_set_uint64 ( GSettings * settings,
const gchar * key,
guint64 value )

◆ g_settings_set_value()

GIO_AVAILABLE_IN_ALL gboolean g_settings_set_value ( GSettings * settings,
const gchar * key,
GVariant * value )

◆ g_settings_sync()

GIO_AVAILABLE_IN_ALL void g_settings_sync ( void )

◆ g_settings_unbind()

GIO_AVAILABLE_IN_ALL void g_settings_unbind ( gpointer object,
const gchar * property )