Top | ![]() |
![]() |
![]() |
![]() |
The GtkSourceStyle structure is used to describe text attributes which are set when the given style is used.
GtkSourceStyleData *
gtk_source_style_get_data (GtkSourceStyle *style
);
[skip]
Since: 300.0
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.
Since: 2.0
void gtk_source_style_apply (GtkSourceStyle *style
,GtkTextTag *tag
);
This function modifies the GtkTextTag properties that are related to the GtkSourceStyle attributes. 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
.
style |
a GtkSourceStyle to apply, or |
[nullable] |
tag |
a GtkTextTag to apply styles to. |
Since: 3.22
struct GtkSourceStyleData { GdkRGBA foreground_color; GdkRGBA background_color; GdkRGBA underline_color; GdkRGBA paragraph_background_color; gdouble scale; PangoUnderline underline; guint italic : 1; guint bold : 1; guint strikethrough : 1; guint use_foreground_color : 1; guint use_background_color : 1; guint use_underline_color : 1; guint use_paragraph_background_color : 1; guint use_scale : 1; guint use_underline : 1; guint use_italic : 1; guint use_bold : 1; guint use_strikethrough : 1; };
The data of a GtkSourceStyle object.
Before using the value of a certain field, check the boolean value of the corresponding "use_" field.
Equivalent to “foreground-rgba”. |
||
Equivalent to “background-rgba”. |
||
Equivalent to “underline-rgba”. |
||
Equivalent to “paragraph-background-rgba”. |
||
Equivalent to “scale”. |
||
Equivalent to “underline”. |
||
For “style”. |
||
For “weight”. |
||
Equivalent to “strikethrough”. |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
||
Whether |
Since: 300.0