GtkSourceStyle

GtkSourceStyle — Represents a style

Functions

Properties

char * background Read / Write / Construct Only
gboolean background-set Read / Write / Construct Only
gboolean bold Read / Write / Construct Only
gboolean bold-set Read / Write / Construct Only
char * foreground Read / Write / Construct Only
gboolean foreground-set Read / Write / Construct Only
gboolean italic Read / Write / Construct Only
gboolean italic-set Read / Write / Construct Only
char * line-background Read / Write / Construct Only
gboolean line-background-set Read / Write / Construct Only
PangoUnderline pango-underline Read / Write / Construct Only
char * scale Read / Write / Construct Only
gboolean scale-set Read / Write / Construct Only
gboolean strikethrough Read / Write / Construct Only
gboolean strikethrough-set Read / Write / Construct Only
char * underline-color Read / Write / Construct Only
gboolean underline-color-set Read / Write / Construct Only
gboolean underline-set Read / Write / Construct Only

Types and Values

Object Hierarchy

    GObject
    ╰── GtkSourceStyle

Includes

#include <gtksourceview/gtksource.h>

Description

The GtkSourceStyle structure is used to describe text attributes which are set when given style is used.

Functions

gtk_source_style_copy ()

GtkSourceStyle *
gtk_source_style_copy (const GtkSourceStyle *style);

Creates a copy of style , that is a new GtkSourceStyle instance which has the same attributes set.

Parameters

style

a GtkSourceStyle structure to copy.

 

Returns

copy of style , call g_object_unref() when you are done with it.

[transfer full]

Since: 2.0


gtk_source_style_apply ()

void
gtk_source_style_apply (const GtkSourceStyle *style,
                        GtkTextTag *tag);

This function modifies the GtkTextTag properties that are related to the GtkSourceStyle properties. Other GtkTextTag properties are left untouched.

If style is non-NULL, applies style to tag .

If style is NULL, the related *-set properties of GtkTextTag are set to FALSE.

Parameters

style

a GtkSourceStyle to apply, or NULL.

[nullable]

tag

a GtkTextTag to apply styles to.

 

Since: 3.22

Types and Values

GtkSourceStyle

typedef struct _GtkSourceStyle GtkSourceStyle;

Property Details

The “background” property

  “background”               char *

Background color.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: NULL


The “background-set” property

  “background-set”           gboolean

Whether background color is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “bold” property

  “bold”                     gboolean

Bold.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “bold-set” property

  “bold-set”                 gboolean

Whether bold attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “foreground” property

  “foreground”               char *

Foreground color.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: NULL


The “foreground-set” property

  “foreground-set”           gboolean

Whether foreground color is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “italic” property

  “italic”                   gboolean

Italic.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “italic-set” property

  “italic-set”               gboolean

Whether italic attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “line-background” property

  “line-background”          char *

Line background color.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: NULL


The “line-background-set” property

  “line-background-set”      gboolean

Whether line background color is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “pango-underline” property

  “pango-underline”          PangoUnderline

Pango Underline.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: PANGO_UNDERLINE_NONE


The “scale” property

  “scale”                    char *

Text scale factor.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: NULL


The “scale-set” property

  “scale-set”                gboolean

Whether scale attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “strikethrough” property

  “strikethrough”            gboolean

Strikethrough.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “strikethrough-set” property

  “strikethrough-set”        gboolean

Whether strikethrough attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “underline-color” property

  “underline-color”          char *

Underline color.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: NULL


The “underline-color-set” property

  “underline-color-set”      gboolean

Whether underline color attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE


The “underline-set” property

  “underline-set”            gboolean

Whether underline attribute is set.

Owner: GtkSourceStyle

Flags: Read / Write / Construct Only

Default value: FALSE

See Also

GtkSourceStyleScheme, GtkSourceStyleSchemeManager