### Method

# Gtk Widget set_state_flags

#### Declaration [src]

    void
    gtk_widget_set_state_flags (
      GtkWidget* widget,
      GtkStateFlags flags,
      gboolean clear
    )

#### Description [src]

Turns on flag values in the current widget state.

Typical widget states are insensitive, prelighted, etc.

This function accepts the values `GTK_STATE_FLAG_DIR_LTR` and `GTK_STATE_FLAG_DIR_RTL` but ignores them. If you want to set the widget’s direction, use `gtk_widget_set_direction()`.

This function is for use in widget implementations.

#### Parameters

`flags`

  Type: `GtkStateFlags`

  State flags to turn on.

`clear`

  Type: `gboolean`

  Whether to clear state before turning on `flags`.