Gtk.TextTag

const Gtk = imports.gi.Gtk;

let text_tag = new Gtk.TextTag({
    accumulative_margin: value,
    background: value,
    background_full_height: value,
    background_full_height_set: value,
    background_gdk: value,
    background_rgba: value,
    background_set: value,
    direction: value,
    editable: value,
    editable_set: value,
    family: value,
    family_set: value,
    font: value,
    font_desc: value,
    foreground: value,
    foreground_gdk: value,
    foreground_rgba: value,
    foreground_set: value,
    indent: value,
    indent_set: value,
    invisible: value,
    invisible_set: value,
    justification: value,
    justification_set: value,
    language: value,
    language_set: value,
    left_margin: value,
    left_margin_set: value,
    name: value,
    paragraph_background: value,
    paragraph_background_gdk: value,
    paragraph_background_rgba: value,
    paragraph_background_set: value,
    pixels_above_lines: value,
    pixels_above_lines_set: value,
    pixels_below_lines: value,
    pixels_below_lines_set: value,
    pixels_inside_wrap: value,
    pixels_inside_wrap_set: value,
    right_margin: value,
    right_margin_set: value,
    rise: value,
    rise_set: value,
    scale: value,
    scale_set: value,
    size: value,
    size_points: value,
    size_set: value,
    stretch: value,
    stretch_set: value,
    strikethrough: value,
    strikethrough_set: value,
    style: value,
    style_set: value,
    tabs: value,
    tabs_set: value,
    underline: value,
    underline_set: value,
    variant: value,
    variant_set: value,
    weight: value,
    weight_set: value,
    wrap_mode: value,
    wrap_mode_set: value,
});
  

You may wish to begin by reading the <link linkend="TextWidget">text widget conceptual overview</link> 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 Gtk.TextTagTable for a given Gtk.TextBuffer before using them with that buffer.

Gtk.create_tag is the best way to create tags. See <application>gtk3-demo</application> for numerous examples.

For each property of Gtk.TextTag, 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.

Hierarchy

  • GObject.Object
    • Gtk.TextTag