Method

GtkStringListsplice

Declaration [src]

void
gtk_string_list_splice (
  GtkStringList* self,
  guint position,
  guint n_removals,
  const char* const* additions
)

Description [src]

Changes self by removing n_removals strings and adding additions to it.

This function is more efficient than gtk_string_list_append() and gtk_string_list_remove(), because it only emits the ::items-changed signal once for the change.

This function copies the strings in additions.

The parameters position and n_removals must be correct (ie: position + n_removals must be less than or equal to the length of the list at the time this function is called).

Parameters

position

Type: guint

The position at which to make the change.

n_removals

Type: guint

The number of strings to remove.

additions

Type: An array of char*

The strings to add.

The argument can be NULL.
The array must be NULL-terminated.
The data is owned by the caller of the method.
Each element is a NUL terminated UTF-8 string.