## MateIconSelection MateIconSelection |

## Synopsis

    #include <libmateui/libmateui.h>

    struct              MateIconSelection;
    GtkWidget *         mate_icon_selection_new            (void);
    void                mate_icon_selection_add_defaults   (MateIconSelection *gis);
    void                mate_icon_selection_add_directory  (MateIconSelection *gis,
                                                             const gchar *dir);
    void                mate_icon_selection_show_icons     (MateIconSelection *gis);
    void                mate_icon_selection_clear          (MateIconSelection *gis,
                                                             gboolean not_shown);
    gchar *             mate_icon_selection_get_icon       (MateIconSelection *gis,
                                                             gboolean full_path);
    void                mate_icon_selection_select_icon    (MateIconSelection *gis,
                                                             const gchar *filename);
    void                mate_icon_selection_stop_loading   (MateIconSelection *gis);
    GtkWidget *         mate_icon_selection_get_gil        (MateIconSelection *gis);
    GtkWidget *         mate_icon_selection_get_box        (MateIconSelection *gis);

## Object Hierarchy

      GObject
       +----GInitiallyUnowned
             +----GtkObject
                   +----GtkWidget
                         +----GtkContainer
                               +----GtkBox
                                     +----GtkVBox
                                           +----MateIconSelection

## Implemented Interfaces

MateIconSelection implements AtkImplementorIface, GtkBuildable and GtkOrientable.

## Description

## Details

### struct MateIconSelection

    struct MateIconSelection;

### mate_icon_selection_new ()

    GtkWidget *         mate_icon_selection_new            (void);

Creates a new icon selection widget, it uses MateIconList for the listing of icons

Returns : | Returns the new object

### mate_icon_selection_add_defaults ()

    void                mate_icon_selection_add_defaults   (MateIconSelection *gis);

Adds the default pixmap directory into the selection widget. It doesn't show the icons in the selection until you do mate_icon_selection_show_icons.

`gis` : | MateIconSelection to work with

### mate_icon_selection_add_directory ()

    void                mate_icon_selection_add_directory  (MateIconSelection *gis,
                                                             const gchar *dir);

Adds the icons from the directory `dir` to the selection widget. It doesn't show the icons in the selection until you do mate_icon_selection_show_icons.

`gis` : | MateIconSelection to work with
`dir` : | directory with pixmaps

### mate_icon_selection_show_icons ()

    void                mate_icon_selection_show_icons     (MateIconSelection *gis);

Shows the icons inside the widget that were added with mate_icon_selection_add_defaults and mate_icon_selection_add_directory. Before this function is called the icons aren't actually added to the listing and can't be picked by the user.

`gis` : | MateIconSelection to work with

### mate_icon_selection_clear ()

    void                mate_icon_selection_clear          (MateIconSelection *gis,
                                                             gboolean not_shown);

Clear the currently shown icons, the ones that weren't shown yet are not cleared unless the not_shown parameter is given, in which case even those are cleared.

`gis` : | MateIconSelection to work with
`not_shown` : | boolean

### mate_icon_selection_get_icon ()

    gchar *             mate_icon_selection_get_icon       (MateIconSelection *gis,
                                                             gboolean full_path);

Gets the currently selected icon name, if full_path is true, it returns the full path to the icon, if none is selected it returns NULL

`gis` : | MateIconSelection to work with
`full_path` : | boolean
Returns : | internal string, it must not be changed or freed or NULL

### mate_icon_selection_select_icon ()

    void                mate_icon_selection_select_icon    (MateIconSelection *gis,
                                                             const gchar *filename);

Selects the icon `filename`. This icon must have already been added and shown * (see `mate_icon_selection_show_icons`)

`gis` : | MateIconSelection to work with
`filename` : | icon filename

### mate_icon_selection_stop_loading ()

    void                mate_icon_selection_stop_loading   (MateIconSelection *gis);

Stop the loading of images when we are in the loop in show_icons, otherwise it does nothing and is harmless, it should be used say if the dialog was hidden or when we want to quickly stop loading the images to do something else without destroying the icon selection object. The remaining icons can be shown by mate_icon_selection_show_icons.

`gis` : | MateIconSelection to work with

### mate_icon_selection_get_gil ()

    GtkWidget *         mate_icon_selection_get_gil        (MateIconSelection *gis);

Gets the MateIconList widget that is used for the display of icons

`gis` : | MateIconSelection to work with
Returns : | a GtkWidget pointer to the interal widget

### mate_icon_selection_get_box ()

    GtkWidget *         mate_icon_selection_get_box        (MateIconSelection *gis);

Gets the GtkVBox widget that is used to pack the different elements of the selection into.

`gis` : | MateIconSelection to work with
Returns : | a GtkWidget pointer to the interal widget