newTake

fun newTake(init: String? = null): String

Creates a new #GString, initialized with the given string.

After this call, @init belongs to the #GString and may no longer be modified by the caller. The memory of @data has to be dynamically allocated and will eventually be freed with g_free().

Return

the new #GString

Since

2.78

Parameters

init

initial text used as the string. Ownership of the string is transferred to the #GString. Passing null creates an empty string.