gtk.inscription

Module for [Inscription] class

Types 3

gtk.inscription.Inscription is a widget to show text in a predefined area.

You likely want to use gtk.label.Label instead as this widget is intended only for a small subset of use cases. The main scenario envisaged is inside lists such as gtk.column_view.ColumnView.

While a gtk.label.Label sizes itself depending on the text that is displayed, gtk.inscription.Inscription is given a size and inscribes the given text into that space as well as it can.

Users of this widget should take care to plan behaviour for the common case where the text doesn't fit exactly in the allocated space.

Methods
GType _getGType() static nothrow
GType _gType() @property nothrow
Inscription self() nothrowReturns `this`, for use in `with` statements.
InscriptionGidBuilder builder() static nothrowGet builder for [gtk.inscription.Inscription] Returns: New builder object
pango.attr_list.AttrList attributes() @property nothrowGet `attributes` property. Returns: A list of style attributes to apply to the text of the inscription.
void attributes(pango.attr_list.AttrList propval) @property nothrowSet `attributes` property. Params: propval = A list of style attributes to apply to the text of the inscription.
void markup(string propval) @property nothrowSet `markup` property. Params: propval = Utility property that sets both the [gtk.inscription.Inscription.text] and [gtk.inscription.Inscription.attributes] properties, mainly intended for use in G...
uint minChars() @property nothrowGet `minChars` property. Returns: The number of characters that should fit into the inscription at minimum.
void minChars(uint propval) @property nothrowSet `minChars` property. Params: propval = The number of characters that should fit into the inscription at minimum.
uint minLines() @property nothrowGet `minLines` property. Returns: The number of lines that should fit into the inscription at minimum.
void minLines(uint propval) @property nothrowSet `minLines` property. Params: propval = The number of lines that should fit into the inscription at minimum.
uint natChars() @property nothrowGet `natChars` property. Returns: The number of characters that should ideally fit into the inscription.
void natChars(uint propval) @property nothrowSet `natChars` property. Params: propval = The number of characters that should ideally fit into the inscription.
uint natLines() @property nothrowGet `natLines` property. Returns: The number of lines that should ideally fit into the inscription.
void natLines(uint propval) @property nothrowSet `natLines` property. Params: propval = The number of lines that should ideally fit into the inscription.
string text() @property nothrowGet `text` property. Returns: The displayed text.
void text(string propval) @property nothrowSet `text` property. Params: propval = The displayed text.
gtk.types.InscriptionOverflow textOverflow() @property nothrowGet `textOverflow` property. Returns: The overflow method to use for the text.
void textOverflow(gtk.types.InscriptionOverflow propval) @property nothrowSet `textOverflow` property. Params: propval = The overflow method to use for the text.
pango.types.WrapMode wrapMode() @property nothrowGet `wrapMode` property. Returns: Controls how the line wrapping is done.
void wrapMode(pango.types.WrapMode propval) @property nothrowSet `wrapMode` property. Params: propval = Controls how the line wrapping is done.
float xalign() @property nothrowGet `xalign` property. Returns: The horizontal alignment of the text inside the allocated size.
void xalign(float propval) @property nothrowSet `xalign` property. Params: propval = The horizontal alignment of the text inside the allocated size.
float yalign() @property nothrowGet `yalign` property. Returns: The vertical alignment of the text inside the allocated size.
void yalign(float propval) @property nothrowSet `yalign` property. Params: propval = The vertical alignment of the text inside the allocated size.
pango.attr_list.AttrList getAttributes() nothrowGets the inscription's attribute list. Returns: the attribute list
uint getMinChars() nothrowGets the `min-chars` of the inscription.
uint getMinLines() nothrowGets the `min-lines` of the inscription.
uint getNatChars() nothrowGets the `nat-chars` of the inscription.
uint getNatLines() nothrowGets the `nat-lines` of the inscription.
string getText() nothrowGets the text that is displayed. Returns: The displayed text
gtk.types.InscriptionOverflow getTextOverflow() nothrowGets the inscription's overflow method. Returns: the overflow method
pango.types.WrapMode getWrapMode() nothrowReturns line wrap mode used by the inscription.
float getXalign() nothrowGets the `xalign` of the inscription.
float getYalign() nothrowGets the `yalign` of the inscription.
void setAttributes(pango.attr_list.AttrList attrs = null) nothrowApply attributes to the inscription text.
void setMarkup(string markup = null) nothrowUtility function to set the text and attributes to be displayed.
void setMinChars(uint minChars) nothrowSets the `min-chars` of the inscription.
void setMinLines(uint minLines) nothrowSets the `min-lines` of the inscription.
void setNatChars(uint natChars) nothrowSets the `nat-chars` of the inscription.
void setNatLines(uint natLines) nothrowSets the `nat-lines` of the inscription.
void setText(string text = null) nothrowSets the text to be displayed.
void setTextOverflow(gtk.types.InscriptionOverflow overflow) nothrowSets what to do when the text doesn't fit.
void setWrapMode(pango.types.WrapMode wrapMode) nothrowControls how line wrapping is done.
void setXalign(float xalign) nothrowSets the `xalign` of the inscription.
void setYalign(float yalign) nothrowSets the `yalign` of the inscription.
Constructors
this(void * ptr, Flag!"Take" take)
this(string text = null)Creates a new [gtk.inscription.Inscription] with the given text.

Fluent builder implementation template for gtk.inscription.Inscription

Methods
T attributes(pango.attr_list.AttrList propval) nothrowSet `attributes` property. Params: propval = A list of style attributes to apply to the text of the inscription. Returns: Builder instance for fluent chaining
T markup(string propval) nothrowSet `markup` property. Params: propval = Utility property that sets both the [gtk.inscription.Inscription.text] and [gtk.inscription.Inscription.attributes] properties, mainly intended for use in G...
T minChars(uint propval) nothrowSet `minChars` property. Params: propval = The number of characters that should fit into the inscription at minimum.
T minLines(uint propval) nothrowSet `minLines` property. Params: propval = The number of lines that should fit into the inscription at minimum.
T natChars(uint propval) nothrowSet `natChars` property. Params: propval = The number of characters that should ideally fit into the inscription.
T natLines(uint propval) nothrowSet `natLines` property. Params: propval = The number of lines that should ideally fit into the inscription.
T text(string propval) nothrowSet `text` property. Params: propval = The displayed text. Returns: Builder instance for fluent chaining
T textOverflow(gtk.types.InscriptionOverflow propval) nothrowSet `textOverflow` property. Params: propval = The overflow method to use for the text. Returns: Builder instance for fluent chaining
T wrapMode(pango.types.WrapMode propval) nothrowSet `wrapMode` property. Params: propval = Controls how the line wrapping is done.
T xalign(float propval) nothrowSet `xalign` property. Params: propval = The horizontal alignment of the text inside the allocated size.
T yalign(float propval) nothrowSet `yalign` property. Params: propval = The vertical alignment of the text inside the allocated size.

Fluent builder for gtk.inscription.Inscription

Methods
Inscription build() nothrowCreate object from builder. Returns: New object