GLib.OptionContext.get_main_group

### Method

# GLib OptionContextget_main_group

since: 2.6

#### Declaration

    GOptionGroup*
    g_option_context_get_main_group (
      GOptionContext* context
    )

#### Description

Returns a pointer to the main group of `context`.

Available since: 2.6

#### Return value

Type: `GOptionGroup`

The main group of `context`, or `NULL` if `context` doesn’t have a main group. Note that group belongs to `context` and should not be modified or freed.

The data is owned by the instance.