### Method

# Gtk StyleContext to_string

deprecated: 4.10

#### Declaration [src]

    char*
    gtk_style_context_to_string (
      GtkStyleContext* context,
      GtkStyleContextPrintFlags flags
    )

#### Description [src]

Converts the style context into a string representation.

The string representation always includes information about the name, state, id, visibility and style classes of the CSS node that is backing `context`. Depending on the flags, more information may be included.

This function is intended for testing and debugging of the CSS implementation in GTK. There are no guarantees about the format of the returned string, it may change.

Deprecated since: 4.10

This api will be removed in GTK 5

#### Parameters

`flags`

  Type: `GtkStyleContextPrintFlags`

  Flags that determine what to print.

#### Return value

Type: `char*`

A newly allocated string representing `context`.

The caller of the method takes ownership of the data, and is responsible for freeing it.
The value is a NUL terminated UTF-8 string.