## GwyStringList

GwyStringList

## Synopsis

    #include <libgwyddion/gwyddion.h>

                        GwyStringList;
                        GwyStringListClass;
    #define             gwy_string_list_duplicate           (strlist)
    GwyStringList*      gwy_string_list_new                 (void);
    void                gwy_string_list_append              (GwyStringList *strlist,
                                                             const gchar *string);
    guint               gwy_string_list_get_length          (GwyStringList *strlist);
    const gchar*        gwy_string_list_get                 (GwyStringList *strlist,
                                                             guint i);

## Object Hierarchy

      GObject
       +----GwyStringList

## Implemented Interfaces

GwyStringList implements GwySerializable.

## Signals

      "value-changed"                                  : Run First

## Description

## Details

### GwyStringList

    typedef struct _GwyStringList GwyStringList;

The GwyStringList struct contains private data only and should be accessed using the functions below.

### GwyStringListClass

    typedef struct {
        GObjectClass parent_class;

        void (*value_changed)(GwyStringList *strlist);

        void (*reserved1)(void);
        void (*reserved2)(void);
        void (*reserved3)(void);
    } GwyStringListClass;

### gwy_string_list_duplicate()

    #define             gwy_string_list_duplicate(strlist)

Convenience macro doing `gwy_serializable_duplicate()` with all the necessary typecasting.

`strlist` : | A string list to duplicate.

### gwy_string_list_new ()

    GwyStringList*      gwy_string_list_new                 (void);

Creates a new string list.

Returns : | A new empty string list.

### gwy_string_list_append ()

    void                gwy_string_list_append              (GwyStringList *strlist,
                                                             const gchar *string);

Appends a string to the end of a string list.

`strlist` : | A string list.
`string` : | A string to add.

### gwy_string_list_get_length ()

    guint               gwy_string_list_get_length          (GwyStringList *strlist);

Gets the number of strings in a string list.

`strlist` : | A string list.
Returns : | The number of strings in `strlist`.

### gwy_string_list_get ()

    const gchar*        gwy_string_list_get                 (GwyStringList *strlist,
                                                             guint i);

Gets a string from a string list by position.

`strlist` : | A string list.
`i` : | The position of string to get.
Returns : | The string, owned by `strlist`. It is valid only until `strlist` changes.

## Signal Details

### The `"value-changed"` signal

    void                user_function                      (GwyStringList *gwystrlist,
                                                            gpointer       user_data)       : Run First

The ::value-changed signal is emitted whenever a string list changes.

`gwystrlist` : | The GwyStringList which received the signal.
`user_data` : | user data set when the signal handler was connected.