Package: gtk

Function gtk-label-line-wrap

Lambda List

gtk-label-line-wrap (label)

Syntax

(gtk-label-line-wrap label) => wrap
(setf (gtk-label-line-wrap label) wrap)

Arguments

label -- a gtk-label widget
wrap -- a boolean whether the lines of the label are automatically wrapped

Details

Accessor of the line wrap setting of the label.

The gtk-label-line-wrap function returns whether lines in the label are automatically wrapped. The (setf gtk-label-line-wrap) function toggles line wrapping of the label.

True makes it break lines if text exceeds the size of the widget. False lets the text get cut off by the edge of the widget if it exceeds the widget size.

Note that setting line wrapping to true does not make the label wrap at the width of the parent container, because GTK widgets conceptually cannot make their requisition depend on the size of the parent container. For a label that wraps at a specific position, set the width of the label using the gtk-widget-size-request function.
 

See also

2021-10-31