Table of Contents

Text Features

Styling Text

In jControls NF4, text is just like any other shape, so it can also be styled using the same fill, border, and drop shadow features.

Please note that the above example was created with 3 different jLabel controls, one for each line, so the color gradient is repeated for each line.

ForeColor Property

Controls with a more rich TextAppearance property will override the ForColor property inherited from the Control class. If, however, the TextAppearnace properties result in nothing being drawn (i.e. the Thickness is 0, and Fill and Border colors are Color.Transparent) then the control will use the ForeColor property instead. In other words, by configuring the TextAppearance properties, developers choose whether to utilize the ForeColor property or not.

Users will most likely prefer to use the rich features of the TextAppearance property, so ForeColor usually defaults to Color.Transparent.

Multi-line Text

All jControls with a relevant Text property can be edited in the designer or at runtime to have multi-line text.

Alignment

Text can be aligned to any edge within the controls bounds, minus its padding.

Padding

A control's text padding, which is applied in addition to the control's padding, can be used to further constrain the bounding box within which the text is drawn. This can be used to offset the text, or reserve space within the control for other visuals.

Padding is often added to the text appearance of a pressed button in order create the illusion of movement when the button is pressed.

Font Fallback

jControls NF4 does not currently implement font fallback. If you need to create a multi-language UI, please use a font that has the glyphs for all languages, or separate each language into separate controls each with a different font configuration for the language it will display.

Text Wrapping

jControls NF4 does not currently implement automatic text wrapping. To wrap text, please add newlines to the Text property as illustrated in the Multiline Text description.