## GtkSourceStyleScheme

GtkSourceStyleScheme — Controls the appearance of GtkSourceView

## Functions

const gchar * | gtk_source_style_scheme_get_id ()
const gchar * | gtk_source_style_scheme_get_name ()
const gchar * | gtk_source_style_scheme_get_description ()
const gchar * const * | gtk_source_style_scheme_get_authors ()
const gchar * | gtk_source_style_scheme_get_filename ()
GtkSourceStyle * | gtk_source_style_scheme_get_style ()

## Properties

char * | description | Read
char * | filename | Read
char * | id | Read / Write / Construct Only
char * | name | Read

## Types and Values

| GtkSourceStyleScheme

## Object Hierarchy

        GObject
        ╰── GtkSourceStyleScheme

## Includes

    #include <gtksourceview/gtksource.h>

## Description

GtkSourceStyleScheme contains all the text styles to be used in GtkSourceView and GtkSourceBuffer. For instance, it contains text styles for syntax highlighting, it may contain foreground and background color for non-highlighted text, color for the line numbers, current line highlighting, bracket matching, etc.

Style schemes are stored in XML files. The format of a scheme file is documented in the style scheme reference.

The two style schemes with IDs "classic" and "tango" follow more closely the GTK+ theme (for example for the background color).

## Functions

### gtk_source_style_scheme_get_id ()

    const gchar *
    gtk_source_style_scheme_get_id (GtkSourceStyleScheme *scheme);

#### Parameters

scheme | a GtkSourceStyleScheme. |

#### Returns

`scheme` id.

Since: 2.0

### gtk_source_style_scheme_get_name ()

    const gchar *
    gtk_source_style_scheme_get_name (GtkSourceStyleScheme *scheme);

#### Parameters

scheme | a GtkSourceStyleScheme. |

#### Returns

`scheme` name.

Since: 2.0

### gtk_source_style_scheme_get_description ()

    const gchar *
    gtk_source_style_scheme_get_description
                                   (GtkSourceStyleScheme *scheme);

#### Parameters

scheme | a GtkSourceStyleScheme. |

#### Returns

`scheme` description (if defined), or `NULL`.

[nullable]

Since: 2.0

### gtk_source_style_scheme_get_authors ()

    const gchar * const *
    gtk_source_style_scheme_get_authors (GtkSourceStyleScheme *scheme);

#### Parameters

scheme | a GtkSourceStyleScheme. |

#### Returns

a `NULL`-terminated array containing the `scheme` authors or `NULL` if no author is specified by the style scheme.

[nullable][array zero-terminated=1][transfer none]

Since: 2.0

### gtk_source_style_scheme_get_filename ()

    const gchar *
    gtk_source_style_scheme_get_filename (GtkSourceStyleScheme *scheme);

#### Parameters

scheme | a GtkSourceStyleScheme. |

#### Returns

`scheme` file name if the scheme was created parsing a style scheme file or `NULL` in the other cases.

[nullable]

Since: 2.0

### gtk_source_style_scheme_get_style ()

    GtkSourceStyle *
    gtk_source_style_scheme_get_style (GtkSourceStyleScheme *scheme,
                                       const gchar *style_id);

#### Parameters

scheme | a GtkSourceStyleScheme. |
style_id | id of the style to retrieve. |

#### Returns

style which corresponds to `style_id` in the `scheme` , or `NULL` when no style with this name found. It is owned by `scheme` and may not be unref'ed.

[nullable][transfer none]

Since: 2.0

## Types and Values

### GtkSourceStyleScheme

    typedef struct _GtkSourceStyleScheme GtkSourceStyleScheme;

## Property Details

### The `“description”` property

      “description”              char *

Style scheme description, a translatable string to present to the user.

Owner: GtkSourceStyleScheme

Flags: Read

Default value: NULL

### The `“filename”` property

      “filename”                 char *

Style scheme filename or `NULL`.

Owner: GtkSourceStyleScheme

Flags: Read

Default value: NULL

### The `“id”` property

      “id”                       char *

Style scheme id, a unique string used to identify the style scheme in GtkSourceStyleSchemeManager.

Owner: GtkSourceStyleScheme

Flags: Read / Write / Construct Only

Default value: NULL

### The `“name”` property

      “name”                     char *

Style scheme name, a translatable string to present to the user.

Owner: GtkSourceStyleScheme

Flags: Read

Default value: NULL

## See Also

GtkSourceStyle, GtkSourceStyleSchemeManager