gtk.text_tag

Module for [TextTag] class

Types 3

You may wish to begin by reading the

text widget conceptual overview

which gives an overview of all the objects and data types related to the text widget and how they work together.

Tags should be in the #GtkTextTagTable for a given #GtkTextBuffer before using them with that buffer.

[gtk.text_buffer.TextBuffer.createTag] is the best way to create tags. See “gtk3-demo” for numerous examples.

For each property of #GtkTextTag, there is a “set” property, e.g. “font-set” corresponds to “font”. These “set” properties reflect whether a property has been set or not. They are maintained by GTK+ and you should not set them independently.

Methods
GType _gType() @property
TextTag self()Returns `this`, for use in `with` statements.
TextTagGidBuilder builder()Get builder for [gtk.text_tag.TextTag] Returns: New builder object
bool accumulativeMargin() @propertyGet `accumulativeMargin` property. Returns: Whether the margins accumulate or override each other.
void accumulativeMargin(bool propval) @propertySet `accumulativeMargin` property. Params: propval = Whether the margins accumulate or override each other.
void background(string propval) @property
bool backgroundFullHeight() @property
void backgroundFullHeight(bool propval) @property
bool backgroundFullHeightSet() @property
void backgroundFullHeightSet(bool propval) @property
gdk.color.Color backgroundGdk() @propertyGet `backgroundGdk` property. Returns: Background color as a #GdkColor.
void backgroundGdk(gdk.color.Color propval) @propertySet `backgroundGdk` property. Params: propval = Background color as a #GdkColor.
gdk.rgba.RGBA backgroundRgba() @propertyGet `backgroundRgba` property. Returns: Background color as a #GdkRGBA.
void backgroundRgba(gdk.rgba.RGBA propval) @propertySet `backgroundRgba` property. Params: propval = Background color as a #GdkRGBA.
bool backgroundSet() @property
void backgroundSet(bool propval) @property
void direction(gtk.types.TextDirection propval) @property
bool editable() @property
void editable(bool propval) @property
bool editableSet() @property
void editableSet(bool propval) @property
bool fallback() @propertyGet `fallback` property. Returns: Whether font fallback is enabled.
void fallback(bool propval) @propertySet `fallback` property. Params: propval = Whether font fallback is enabled.
bool fallbackSet() @property
void fallbackSet(bool propval) @property
string family() @property
void family(string propval) @property
bool familySet() @property
void familySet(bool propval) @property
string font() @propertyGet `font` property. Returns: Font description as string, e.g. \"Sans Italic 12\".
void font(string propval) @propertySet `font` property. Params: propval = Font description as string, e.g. \"Sans Italic 12\".
string fontFeatures() @propertyGet `fontFeatures` property. Returns: OpenType font features, as a string.
void fontFeatures(string propval) @propertySet `fontFeatures` property. Params: propval = OpenType font features, as a string.
bool fontFeaturesSet() @property
void fontFeaturesSet(bool propval) @property
void foreground(string propval) @property
gdk.color.Color foregroundGdk() @propertyGet `foregroundGdk` property. Returns: Foreground color as a #GdkColor.
void foregroundGdk(gdk.color.Color propval) @propertySet `foregroundGdk` property. Params: propval = Foreground color as a #GdkColor.
gdk.rgba.RGBA foregroundRgba() @propertyGet `foregroundRgba` property. Returns: Foreground color as a #GdkRGBA.
void foregroundRgba(gdk.rgba.RGBA propval) @propertySet `foregroundRgba` property. Params: propval = Foreground color as a #GdkRGBA.
bool foregroundSet() @property
void foregroundSet(bool propval) @property
int indent() @property
void indent(int propval) @property
bool indentSet() @property
void indentSet(bool propval) @property
bool invisible() @propertyGet `invisible` property. Returns: Whether this text is hidden.
void invisible(bool propval) @propertySet `invisible` property. Params: propval = Whether this text is hidden.
bool invisibleSet() @property
void invisibleSet(bool propval) @property
void justification(gtk.types.Justification propval) @property
bool justificationSet() @property
void justificationSet(bool propval) @property
string language() @propertyGet `language` property. Returns: The language this text is in, as an ISO code. Pango can use this as a hint when rendering the text. If not set, an appropriate default will be used.
void language(string propval) @propertySet `language` property. Params: propval = The language this text is in, as an ISO code. Pango can use this as a hint when rendering the text. If not set, an appropriate default will be used.
bool languageSet() @property
void languageSet(bool propval) @property
int leftMargin() @property
void leftMargin(int propval) @property
bool leftMarginSet() @property
void leftMarginSet(bool propval) @property
int letterSpacing() @propertyGet `letterSpacing` property. Returns: Extra spacing between graphemes, in Pango units.
void letterSpacing(int propval) @propertySet `letterSpacing` property. Params: propval = Extra spacing between graphemes, in Pango units.
bool letterSpacingSet() @property
void letterSpacingSet(bool propval) @property
string name() @property
void paragraphBackground(string propval) @propertySet `paragraphBackground` property. Params: propval = The paragraph background color as a string.
gdk.color.Color paragraphBackgroundGdk() @propertyGet `paragraphBackgroundGdk` property. Returns: The paragraph background color as a #GdkColor.
void paragraphBackgroundGdk(gdk.color.Color propval) @propertySet `paragraphBackgroundGdk` property. Params: propval = The paragraph background color as a #GdkColor.
gdk.rgba.RGBA paragraphBackgroundRgba() @propertyGet `paragraphBackgroundRgba` property. Returns: The paragraph background color as a #GdkRGBA.
void paragraphBackgroundRgba(gdk.rgba.RGBA propval) @propertySet `paragraphBackgroundRgba` property. Params: propval = The paragraph background color as a #GdkRGBA.
bool paragraphBackgroundSet() @property
void paragraphBackgroundSet(bool propval) @property
int pixelsAboveLines() @property
void pixelsAboveLines(int propval) @property
bool pixelsAboveLinesSet() @property
void pixelsAboveLinesSet(bool propval) @property
int pixelsBelowLines() @property
void pixelsBelowLines(int propval) @property
bool pixelsBelowLinesSet() @property
void pixelsBelowLinesSet(bool propval) @property
int pixelsInsideWrap() @property
void pixelsInsideWrap(int propval) @property
bool pixelsInsideWrapSet() @property
void pixelsInsideWrapSet(bool propval) @property
int rightMargin() @property
void rightMargin(int propval) @property
bool rightMarginSet() @property
void rightMarginSet(bool propval) @property
int rise() @property
void rise(int propval) @property
bool riseSet() @property
void riseSet(bool propval) @property
double scale() @property
void scale(double propval) @property
bool scaleSet() @property
void scaleSet(bool propval) @property
int size() @property
void size(int propval) @property
double sizePoints() @property
void sizePoints(double propval) @property
bool sizeSet() @property
void sizeSet(bool propval) @property
void stretch(pango.types.Stretch propval) @property
bool stretchSet() @property
void stretchSet(bool propval) @property
bool strikethrough() @property
void strikethrough(bool propval) @property
gdk.rgba.RGBA strikethroughRgba() @propertyGet `strikethroughRgba` property. Returns: This property modifies the color of strikeouts. If not set, strikeouts will use the forground color.
void strikethroughRgba(gdk.rgba.RGBA propval) @propertySet `strikethroughRgba` property. Params: propval = This property modifies the color of strikeouts. If not set, strikeouts will use the forground color.
bool strikethroughRgbaSet() @propertyGet `strikethroughRgbaSet` property. Returns: If the #GtkTextTag:strikethrough-rgba property has been set.
void strikethroughRgbaSet(bool propval) @propertySet `strikethroughRgbaSet` property. Params: propval = If the #GtkTextTag:strikethrough-rgba property has been set.
bool strikethroughSet() @property
void strikethroughSet(bool propval) @property
void style(pango.types.Style propval) @property
bool styleSet() @property
void styleSet(bool propval) @property
void tabs(pango.tab_array.TabArray propval) @property
bool tabsSet() @property
void tabsSet(bool propval) @property
void underline(pango.types.Underline propval) @property
gdk.rgba.RGBA underlineRgba() @propertyGet `underlineRgba` property. Returns: This property modifies the color of underlines. If not set, underlines will use the forground color.
void underlineRgba(gdk.rgba.RGBA propval) @propertySet `underlineRgba` property. Params: propval = This property modifies the color of underlines. If not set, underlines will use the forground color.
bool underlineRgbaSet() @propertyGet `underlineRgbaSet` property. Returns: If the #GtkTextTag:underline-rgba property has been set.
void underlineRgbaSet(bool propval) @propertySet `underlineRgbaSet` property. Params: propval = If the #GtkTextTag:underline-rgba property has been set.
bool underlineSet() @property
void underlineSet(bool propval) @property
void variant(pango.types.Variant propval) @property
bool variantSet() @property
void variantSet(bool propval) @property
int weight() @property
void weight(int propval) @property
bool weightSet() @property
void weightSet(bool propval) @property
void wrapMode(gtk.types.WrapMode propval) @property
bool wrapModeSet() @property
void wrapModeSet(bool propval) @property
void changed(bool sizeChanged)Emits the #GtkTextTagTable::tag-changed signal on the #GtkTextTagTable where the tag is included.
bool event(gobject.object.ObjectWrap eventObject, gdk.event.Event event, gtk.text_iter.TextIter iter)Emits the “event” signal on the #GtkTextTag.
int getPriority()Get the tag priority. Returns: The tag’s priority.
void setPriority(int priority)Sets the priority of a #GtkTextTag. Valid priorities start at 0 and go to one less than [gtk.texttagtable.TextTagTable.getSize]. Each tag in a table has a unique priority; setting the priority of o...
gulong connectEvent(T)(T callback, Flag!"After" after = No.After) if (isCallable!T && is(ReturnType!T == bool) && (Parameters!T.length < 1 || (ParameterStorageClassTuple!T[0] == ParameterStorageClass.none && is(Parameters!T[0] : gobject.object.ObjectWrap))) && (Parameters!T.length < 2 || (ParameterStorageClassTuple!T[1] == ParameterStorageClass.none && is(Parameters!T[1] == gdk.event.Event))) && (Parameters!T.length < 3 || (ParameterStorageClassTuple!T[2] == ParameterStorageClass.none && is(Parameters!T[2] == gtk.text_iter.TextIter))) && (Parameters!T.length < 4 || (ParameterStorageClassTuple!T[3] == ParameterStorageClass.none && is(Parameters!T[3] : gtk.text_tag.TextTag))) && Parameters!T.length < 5)Connect to `Event` signal.
Constructors
this(void * ptr, Flag!"Take" take)
this(string name = null)Creates a #GtkTextTag. Configure the tag using object arguments, i.e. using [gobject.object.ObjectWrap.set].
Methods
T accumulativeMargin(bool propval)Set `accumulativeMargin` property. Params: propval = Whether the margins accumulate or override each other.
T background(string propval)
T backgroundFullHeight(bool propval)
T backgroundFullHeightSet(bool propval)
T backgroundGdk(gdk.color.Color propval)Set `backgroundGdk` property. Params: propval = Background color as a #GdkColor. Returns: Builder instance for fluent chaining
T backgroundRgba(gdk.rgba.RGBA propval)Set `backgroundRgba` property. Params: propval = Background color as a #GdkRGBA. Returns: Builder instance for fluent chaining
T backgroundSet(bool propval)
T editable(bool propval)
T editableSet(bool propval)
T fallback(bool propval)Set `fallback` property. Params: propval = Whether font fallback is enabled.
T fallbackSet(bool propval)
T family(string propval)
T familySet(bool propval)
T font(string propval)Set `font` property. Params: propval = Font description as string, e.g. \"Sans Italic 12\".
T fontFeatures(string propval)Set `fontFeatures` property. Params: propval = OpenType font features, as a string. Returns: Builder instance for fluent chaining
T fontFeaturesSet(bool propval)
T foreground(string propval)
T foregroundGdk(gdk.color.Color propval)Set `foregroundGdk` property. Params: propval = Foreground color as a #GdkColor. Returns: Builder instance for fluent chaining
T foregroundRgba(gdk.rgba.RGBA propval)Set `foregroundRgba` property. Params: propval = Foreground color as a #GdkRGBA. Returns: Builder instance for fluent chaining
T foregroundSet(bool propval)
T indent(int propval)
T indentSet(bool propval)
T invisible(bool propval)Set `invisible` property. Params: propval = Whether this text is hidden.
T invisibleSet(bool propval)
T justificationSet(bool propval)
T language(string propval)Set `language` property. Params: propval = The language this text is in, as an ISO code. Pango can use this as a hint when rendering the text. If not set, an appropriate default will be used.
T languageSet(bool propval)
T leftMargin(int propval)
T leftMarginSet(bool propval)
T letterSpacing(int propval)Set `letterSpacing` property. Params: propval = Extra spacing between graphemes, in Pango units. Returns: Builder instance for fluent chaining
T letterSpacingSet(bool propval)
T name(string propval)
T paragraphBackground(string propval)Set `paragraphBackground` property. Params: propval = The paragraph background color as a string. Returns: Builder instance for fluent chaining
T paragraphBackgroundGdk(gdk.color.Color propval)Set `paragraphBackgroundGdk` property. Params: propval = The paragraph background color as a #GdkColor. Returns: Builder instance for fluent chaining
T paragraphBackgroundRgba(gdk.rgba.RGBA propval)Set `paragraphBackgroundRgba` property. Params: propval = The paragraph background color as a #GdkRGBA. Returns: Builder instance for fluent chaining
T paragraphBackgroundSet(bool propval)
T pixelsAboveLines(int propval)
T pixelsAboveLinesSet(bool propval)
T pixelsBelowLines(int propval)
T pixelsBelowLinesSet(bool propval)
T pixelsInsideWrap(int propval)
T pixelsInsideWrapSet(bool propval)
T rightMargin(int propval)
T rightMarginSet(bool propval)
T rise(int propval)
T riseSet(bool propval)
T scale(double propval)
T scaleSet(bool propval)
T size(int propval)
T sizePoints(double propval)
T sizeSet(bool propval)
T stretchSet(bool propval)
T strikethrough(bool propval)
T strikethroughRgba(gdk.rgba.RGBA propval)Set `strikethroughRgba` property. Params: propval = This property modifies the color of strikeouts. If not set, strikeouts will use the forground color. Returns: Builder instance for fluent chaining
T strikethroughRgbaSet(bool propval)Set `strikethroughRgbaSet` property. Params: propval = If the #GtkTextTag:strikethrough-rgba property has been set. Returns: Builder instance for fluent chaining
T strikethroughSet(bool propval)
T styleSet(bool propval)
T tabsSet(bool propval)
T underlineRgba(gdk.rgba.RGBA propval)Set `underlineRgba` property. Params: propval = This property modifies the color of underlines. If not set, underlines will use the forground color.
T underlineRgbaSet(bool propval)Set `underlineRgbaSet` property. Params: propval = If the #GtkTextTag:underline-rgba property has been set. Returns: Builder instance for fluent chaining
T underlineSet(bool propval)
T variantSet(bool propval)
T weight(int propval)
T weightSet(bool propval)
T wrapModeSet(bool propval)

Fluent builder for [gtk.text_tag.TextTag]

Methods