GLXCurses.TextTag module¶
-
class
GLXCurses.TextTag.
TextTag
[source]¶ Bases:
GLXCurses.Object.Object
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 TextTagTable for a given TextBuffer before using them with that buffer.
For each property of 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 GLXCurses and you should not set them independently.
-
accumulative_margin
¶ Whether the margins accumulate or override each other.
When set to
True
the margins of this tag are added to the margins of any other non-accumulative margins present.When set to
False
the margins override one another (the default).Default value is
False
and be restore whenaccumulative_margin
is set toNone
Returns: If True
the margins of this tag are added to the margins of any other non-accumulativeReturn type: bool
-
background
¶ Background color as a string.
Returns: color as a string Return type: str
-
background_full_height
¶ Whether the background color fills the entire line height or only the height of the tagged characters.
When set to
True
the background color fills the entire line heightDefault value is
False
and be restore whenbackground_full_height
is set toNone
Returns: If True
the background color fills the entire line heightReturn type: bool
-
background_full_height_set
¶ Whether this tag affects background height.
When set to
True
this tag affects background heightDefault value is
False
and be restore whenbackground_full_height_set
is set toNone
Returns: True
If this tag affects background heightReturn type: bool
-
background_rgb
¶ Background color as a RGB.
Default value is
{'r': 0, 'g': 0, 'b': 255}
and be restore whenbackground_rgb
is set toNone
Returns: The RGB color as dict with r, g, b key_name Return type: dict
-
background_set
¶ Whether this tag affects the background color.
Default value is
False
and be restore whenbackground_set
is set toNone
Returns: If True
, this tag affects the background colorReturn type: bool
-
direction
¶ Text direction, e.g. right-to-left -> ‘RTL’ or left-to-right -> ‘LTR’.
Returns: GLXC.TextDirection direction type Return type: str
-
editable
¶ Whether the text can be modified by the user.
Default value is
True
and be restore wheneditable
is set toNone
Returns: If True
, the text can be modified by the user.Return type: bool
-
editable_set
¶ Whether this tag affects text editability.
Default value is
False
and be restore wheneditable_set
is set toNone
Returns: If False
, text editability is disableReturn type: bool
-
family
¶ Name of the font family, e.g. Sans, Helvetica, Times, Monospace.
Default value is
None
and be restore whenfamily
is set toNone
Returns: The font family name Return type: str or None
-
family_set
¶ Whether this tag affects the font family.
Default value is
False
and be restore wheneditable_set
is set toNone
Returns: If False
, text editability is disableReturn type: bool
-