Label Elements
A label element displays text, either a configured string or a property of
the context's desk or task. Labels have the following options:
(prefix)AlignHoriz [left|center|right]
Default: center
Whether this text is left, center, or right-aligned. This alignment also
determines the meaning of (prefix)X; the left side, center, or right side,
respectively.
(prefix)AlignVert [top|center|bottom]
Default: center
Whether this text is top, center, or bottom-aligned. This alignment also
determines the meaning of (prefix)Y; the top, center, or bottom,
respectively.
(prefix)X [coord]
(prefix)Y [coord]
Where the edges of the text are. The default depends on alignment.
(prefix)MinLength [int]
Default: 0
The minimum length for this text. If the text is smaller than this, it will
be expanded and the extra space left blank.
(prefix)MaxLength [int]
Default: 250
The maximum length for this text. If the text is larger than this, it will
be shortened and ellipses ('...') used at the end.
(prefix)AllowAbbrev [bool]
Default: false
Whether this label's text may be truncated to a length shorter than
MaxLength to make room on the panel.
(prefix)UseXStats [bool]
Default: false
If set, the XStatsClass module is loaded and the label's text is handled as
an XStatsClass expression.
(prefix)Text [string]
Default: .auto
The label text can either be an arbitrary string, which is shown as-is, or a
special value starting with a dot.
-
.auto
If in the context of a task, the same as .taskname. Otherwise, the same as
.desknum.
-
.desknum
The number of the context's virtual desktop.
-
.taskname
The window title of the context's task.
-
.cpu
The percentage of the CPU that the context task is using. Requires the
sbTrackProcesses option to be true.
-
.mem
The amount of memory (in kb) that the context task is using. Requires the
sbTrackProcesses option to be true.
Additionally, label elements respect all
XPaintClass
PaintText options. Some of the more useful of these options are
(prefix)Font, (prefix)FontHeight
and (prefix)FontColor.