## gimpgimprc

gimpgimprc — Interactions with settings from .gimprc.

## Synopsis

    gchar*              gimp_gimprc_query                   (const gchar *token);
    gboolean            gimp_gimprc_set                     (const gchar *token,
                                                             const gchar *value);
    GimpColorConfig *   gimp_get_color_configuration        (void);
    gchar*              gimp_get_default_comment            (void);
    GimpUnit            gimp_get_default_unit               (void);
    gchar*              gimp_get_module_load_inhibit        (void);
    gboolean            gimp_get_monitor_resolution         (gdouble *xres,
                                                             gdouble *yres);
    gchar*              gimp_get_theme_dir                  (void);

## Description

Interactions with settings from .gimprc.

## Details

### gimp_gimprc_query ()

    gchar*              gimp_gimprc_query                   (const gchar *token);

Queries the gimprc file parser for information on a specified token.

This procedure is used to locate additional information contained in the gimprc file considered extraneous to the operation of GIMP. Plug-ins that need configuration information can expect it will be stored in the user gimprc file and can use this procedure to retrieve it. This query procedure will return the value associated with the specified token. This corresponds _only_ to entries with the format: (<token> <value>). The value must be a string. Entries not corresponding to this format will cause warnings to be issued on gimprc parsing and will not be queryable.

`token` : | The token to query for.
Returns : | The value associated with the queried token.

### gimp_gimprc_set ()

    gboolean            gimp_gimprc_set                     (const gchar *token,
                                                             const gchar *value);

Sets a gimprc token to a value and saves it in the gimprc.

This procedure is used to add or change additional information in the gimprc file that is considered extraneous to the operation of GIMP. Plug-ins that need configuration information can use this function to store it, and `gimp_gimprc_query()` to retrieve it. This will accept _only_ string values in UTF-8 encoding.

`token` : | The token to add or modify.
`value` : | The value to set the token to.
Returns : | TRUE on success.

### gimp_get_color_configuration ()

    GimpColorConfig *   gimp_get_color_configuration        (void);

Retrieve a copy of the current color management configuration.

Returns : | A copy of the core's GimpColorConfig. You should unref this copy if you don't need it any longer.

Since GIMP 2.4

### gimp_get_default_comment ()

    gchar*              gimp_get_default_comment            (void);

Get the default image comment as specified in the Preferences.

Returns a copy of the default image comment.

Returns : | Default image comment.

### gimp_get_default_unit ()

    GimpUnit            gimp_get_default_unit               (void);

Get the default unit (taken from the user's locale).

Returns the default unit's integer ID.

Returns : | Default unit.

Since GIMP 2.4

### gimp_get_module_load_inhibit ()

    gchar*              gimp_get_module_load_inhibit        (void);

Get the list of modules which should not be loaded.

Returns a copy of the list of modules which should not be loaded.

Returns : | The list of modules.

### gimp_get_monitor_resolution ()

    gboolean            gimp_get_monitor_resolution         (gdouble *xres,
                                                             gdouble *yres);

Get the monitor resolution as specified in the Preferences.

Returns the resolution of the monitor in pixels/inch. This value is taken from the Preferences (or the windowing system if this is set in the Preferences) and there's no guarantee for the value to be reasonable.

`xres` : | X resolution.
`yres` : | Y resolution.
Returns : | TRUE on success.

### gimp_get_theme_dir ()

    gchar*              gimp_get_theme_dir                  (void);

Get the directory of the current GUI theme.

Returns a copy of the current GUI theme dir.

Returns : | The GUI theme dir.