GtkLabel
A widget that displays a small to medium amount of text.
Object Hierarchy
Direct Subclasses
Description
The GtkLabel widget displays a small amount of text.
As the name implies, most labels are used to label
another widget such as a GtkButton,
a GtkMenuItem, or a
GtkOptionMenu.
You can have control over the way a GtkLabel will be displayed with
some methods such as set_justify()
or set_width_chars() . As a subclass
of GtkMisc, you may specify alignment and padding
with set_alignment() and
set_padding() . However,
set_padding() only supports setting
padding for the right/left and top/bottom pairs. If you need to specify
different values for left and right padding, you can insert the label
into a GtkAlignment container.
Constructors
GtkLabel ([string
string = null [, boolean
parse_mnemonic = false]]);
--
Creates a new GtkLabel.
Properties
Use get_property and set_property methods to access these.
angle:
The display angle of the text.
attributes:
A list of Pango attributes applied to the label.
curosr-position:
The current position of the cursor.
ellipsize:
The ellipsization mode of the label.
justify:
The justification mode of the label.
label:
The text to be shown by the label.
max-width-chars:
The maximum width of the widget in characters.
mnemonic-keyval:
The mnemonic accelerator key for this label.
mnemonic-widget:
The widget to be activated when the label's mnemonic key is pressed.
pattern:
A string of '_' characters indicating which characters in the label to
underline.
selectable:
Whether or not the text of the label is selectable.
selection-bound:
The position of the selection bound.
single-line-mode:
Whether or not the label is in single line mode.
use_markup:
Whether or not the label should be processed for Pango markup.
use_underline:
Whether or not the label contains an underline for a mnemonic.
width-chars:
The width of the widget in characters.
wrap:
Whether or not a long string of text may wrap to the next line.
Signals
"copy-clipboard"
Emitted when all or part of the label's text is copied to the clipboard.
"move-cursor"
Emitted when the cursor is moved within the label.
"populate-popup"
Emitted when a context menu for the label is popped up.