gtk.text_tag
Module for [TextTag] class
Types 3
classTextTag : gobject.object.ObjectWrap
You may wish to begin by reading the
text widget conceptual overviewwhich 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
TextTagGidBuilder builder()Get builder for [gtk.text_tag.TextTag] Returns: New builder objectbool 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) @propertybool backgroundFullHeight() @propertyvoid backgroundFullHeight(bool propval) @propertybool backgroundFullHeightSet() @propertyvoid backgroundFullHeightSet(bool propval) @propertygdk.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() @propertyvoid backgroundSet(bool propval) @propertygtk.types.TextDirection direction() @propertyvoid direction(gtk.types.TextDirection propval) @propertybool editable() @propertyvoid editable(bool propval) @propertybool editableSet() @propertyvoid editableSet(bool propval) @propertyvoid fallback(bool propval) @propertySet `fallback` property. Params: propval = Whether font fallback is enabled.bool fallbackSet() @propertyvoid fallbackSet(bool propval) @propertystring family() @propertyvoid family(string propval) @propertybool familySet() @propertyvoid familySet(bool propval) @propertystring 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\".pango.font_description.FontDescription fontDesc() @propertyvoid fontDesc(pango.font_description.FontDescription propval) @propertystring 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() @propertyvoid fontFeaturesSet(bool propval) @propertyvoid foreground(string propval) @propertygdk.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() @propertyvoid foregroundSet(bool propval) @propertyint indent() @propertyvoid indent(int propval) @propertybool indentSet() @propertyvoid indentSet(bool propval) @propertyvoid invisible(bool propval) @propertySet `invisible` property. Params: propval = Whether this text is hidden.bool invisibleSet() @propertyvoid invisibleSet(bool propval) @propertygtk.types.Justification justification() @propertyvoid justification(gtk.types.Justification propval) @propertybool justificationSet() @propertyvoid justificationSet(bool propval) @propertystring 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() @propertyvoid languageSet(bool propval) @propertyint leftMargin() @propertyvoid leftMargin(int propval) @propertybool leftMarginSet() @propertyvoid leftMarginSet(bool propval) @propertyint 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() @propertyvoid letterSpacingSet(bool propval) @propertystring name() @propertyvoid 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() @propertyvoid paragraphBackgroundSet(bool propval) @propertyint pixelsAboveLines() @propertyvoid pixelsAboveLines(int propval) @propertybool pixelsAboveLinesSet() @propertyvoid pixelsAboveLinesSet(bool propval) @propertyint pixelsBelowLines() @propertyvoid pixelsBelowLines(int propval) @propertybool pixelsBelowLinesSet() @propertyvoid pixelsBelowLinesSet(bool propval) @propertyint pixelsInsideWrap() @propertyvoid pixelsInsideWrap(int propval) @propertybool pixelsInsideWrapSet() @propertyvoid pixelsInsideWrapSet(bool propval) @propertyint rightMargin() @propertyvoid rightMargin(int propval) @propertybool rightMarginSet() @propertyvoid rightMarginSet(bool propval) @propertyint rise() @propertyvoid rise(int propval) @propertybool riseSet() @propertyvoid riseSet(bool propval) @propertydouble scale() @propertyvoid scale(double propval) @propertybool scaleSet() @propertyvoid scaleSet(bool propval) @propertyint size() @propertyvoid size(int propval) @propertydouble sizePoints() @propertyvoid sizePoints(double propval) @propertybool sizeSet() @propertyvoid sizeSet(bool propval) @propertypango.types.Stretch stretch() @propertyvoid stretch(pango.types.Stretch propval) @propertybool stretchSet() @propertyvoid stretchSet(bool propval) @propertybool strikethrough() @propertyvoid strikethrough(bool propval) @propertygdk.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() @propertyvoid strikethroughSet(bool propval) @propertypango.types.Style style() @propertyvoid style(pango.types.Style propval) @propertybool styleSet() @propertyvoid styleSet(bool propval) @propertypango.tab_array.TabArray tabs() @propertyvoid tabs(pango.tab_array.TabArray propval) @propertybool tabsSet() @propertyvoid tabsSet(bool propval) @propertypango.types.Underline underline() @propertyvoid underline(pango.types.Underline propval) @propertygdk.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() @propertyvoid underlineSet(bool propval) @propertypango.types.Variant variant() @propertyvoid variant(pango.types.Variant propval) @propertybool variantSet() @propertyvoid variantSet(bool propval) @propertyint weight() @propertyvoid weight(int propval) @propertybool weightSet() @propertyvoid weightSet(bool propval) @propertygtk.types.WrapMode wrapMode() @propertyvoid wrapMode(gtk.types.WrapMode propval) @propertybool wrapModeSet() @propertyvoid wrapModeSet(bool propval) @propertyvoid 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.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 chainingT backgroundRgba(gdk.rgba.RGBA propval)Set `backgroundRgba` property. Params: propval = Background color as a #GdkRGBA. Returns: Builder instance for fluent chainingT backgroundSet(bool propval)T direction(gtk.types.TextDirection 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 fontDesc(pango.font_description.FontDescription propval)T fontFeatures(string propval)Set `fontFeatures` property. Params: propval = OpenType font features, as a string. Returns: Builder instance for fluent chainingT 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 chainingT foregroundRgba(gdk.rgba.RGBA propval)Set `foregroundRgba` property. Params: propval = Foreground color as a #GdkRGBA. Returns: Builder instance for fluent chainingT 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 justification(gtk.types.Justification 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 chainingT 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 chainingT paragraphBackgroundGdk(gdk.color.Color propval)Set `paragraphBackgroundGdk` property. Params: propval = The paragraph background color as a #GdkColor. Returns: Builder instance for fluent chainingT paragraphBackgroundRgba(gdk.rgba.RGBA propval)Set `paragraphBackgroundRgba` property. Params: propval = The paragraph background color as a #GdkRGBA. Returns: Builder instance for fluent chainingT 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 stretch(pango.types.Stretch 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 chainingT strikethroughRgbaSet(bool propval)Set `strikethroughRgbaSet` property. Params: propval = If the #GtkTextTag:strikethrough-rgba property has been set. Returns: Builder instance for fluent chainingT strikethroughSet(bool propval)T style(pango.types.Style propval)T styleSet(bool propval)T tabs(pango.tab_array.TabArray propval)T tabsSet(bool propval)T underline(pango.types.Underline 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 chainingT underlineSet(bool propval)T variant(pango.types.Variant propval)T variantSet(bool propval)T weight(int propval)T weightSet(bool propval)T wrapMode(gtk.types.WrapMode propval)T wrapModeSet(bool propval)