Function

GLibStringnew

Declaration

GString*
g_string_new (
  const gchar* init
)

Description

Creates a new GString, initialized with the given string.

Parameters

init const gchar*
 

The initial text to copy into the string, or NULL to start with an empty string.

 The argument can be NULL.
 The data is owned by the caller of the function.
 The string is a NUL terminated UTF-8 string.

Return value

Returns: GString
 

The new GString.

 The caller of the function takes ownership of the data, and is responsible for freeing it.