## gva-preferences gva-preferences — Preferences Window |

## Synopsis

    void                gva_preferences_init                (void);
    gboolean            gva_preferences_get_auto_play       (void);
    void                gva_preferences_set_auto_play       (gboolean auto_play);
    gboolean            gva_preferences_get_auto_save       (void);
    void                gva_preferences_set_auto_save       (gboolean auto_save);
    gboolean            gva_preferences_get_full_screen     (void);
    void                gva_preferences_set_full_screen     (gboolean full_screen);
    gboolean            gva_preferences_get_show_clones     (void);
    void                gva_preferences_set_show_clones     (gboolean show_clones);
    void                gva_preferences_close_clicked_cb    (GtkWindow *window,
                                                             GtkButton *button);

## Description

These functions manipulate the Preferences window.

## Details

### gva_preferences_init ()

    void                gva_preferences_init                (void);

Initializes the Preferences window.

This function should be called once when the application starts.

### gva_preferences_get_auto_play ()

    gboolean            gva_preferences_get_auto_play       (void);

Returns the user's preference for whether to automatically play a music clip of the selected game when the user opens the Properties window or when the user selects a different game while the Properties window is visible.

Returns : | `TRUE` to automatically play music clips

### gva_preferences_set_auto_play ()

    void                gva_preferences_set_auto_play       (gboolean auto_play);

Accepts the user's preference for whether to automatically play a music clip of the selected game when the user opens the Properties window or when the user selects a different game while the Properties window is visible.

The preference is stored in GSettings key `auto-play`.

`auto_play` : | the user's preference

### gva_preferences_get_auto_save ()

    gboolean            gva_preferences_get_auto_save       (void);

Returns the user's preference for whether to restore the emulated machine's previous state when starting a game.

Returns : | `TRUE` to restore state, `FALSE` to cold boot

### gva_preferences_set_auto_save ()

    void                gva_preferences_set_auto_save       (gboolean auto_save);

Accepts the user's preference for whether to restore the emulated machine's previous state when starting a game.

The preference is stored in GSettings key `auto-save`.

`auto_save` : | the user's preference

### gva_preferences_get_full_screen ()

    gboolean            gva_preferences_get_full_screen     (void);

Returns the user's preference for whether to start games in full screen mode.

Returns : | `TRUE` to start in full screen mode, `FALSE` to start in a window

### gva_preferences_set_full_screen ()

    void                gva_preferences_set_full_screen     (gboolean full_screen);

Accepts the user's preference for whether to start games in full screen mode.

The preference is stored in GSettings key `full-screen`.

`full_screen` : | the user's preference

### gva_preferences_get_show_clones ()

    gboolean            gva_preferences_get_show_clones     (void);

Returns the user's preference for whether to show cloned games in the main window.

Returns : | `TRUE` to show cloned games, `FALSE` to only show original games

### gva_preferences_set_show_clones ()

    void                gva_preferences_set_show_clones     (gboolean show_clones);

Accepts the user's preference for whether to show cloned games in the main window.

The preference is stored in GSettings key `show-clones`.

`show_clones` : | the user's preference

### gva_preferences_close_clicked_cb ()

    void                gva_preferences_close_clicked_cb    (GtkWindow *window,
                                                             GtkButton *button);

Handler for "clicked" signals to the "Close" button.

Hides `window`.

`window` : | the "Preferences" window
`button` : | the "Close" button