### Method

# GLib String printf

#### Declaration

    void
    g_string_printf (
      GString* string,
      const gchar* format,
      ...
    )

#### Description

Writes a formatted string into a `GString`. This is similar to the standard `sprintf()` function, except that the `GString` buffer automatically expands to contain the results. The previous contents of the `GString` are destroyed.

This method is not directly available to language bindings.

#### Parameters

`format`

  Type: `const gchar*`

  The string format. See the `printf()` documentation.

  The data is owned by the caller of the method.
  The value is a NUL terminated UTF-8 string.

`...`

  Type: ``

  The parameters to insert into the format string.