From the category archives:

Label

The following example shows how you can use a CFF embedded font with a Halo Label control and Spark Label control by setting the textFieldClass style on the Halo Label control to the mx.core.UIFTETextField class.

Full code after the jump.

[click to continue…]

{ 11 comments }

The following example shows how you can set the font sharpness on a Flex Label control by setting the fontSharpness and fontAntiAliasType styles.

Full code after the jump.

[click to continue…]

{ 0 comments }

The following example shows how you can set the font thickness on a Flex Label control by setting the fontThickness and fontAntiAliasType styles.

Full code after the jump.

[click to continue…]

{ 0 comments }

The following example shows how you can detect when a Flex Button control’s label changes using the labelChanged event.

Full code after the jump.

[click to continue…]

{ 0 comments }

The following example shows how you can access the Label subcomponent in a Flex FormItem container and do fancy stuff like have form labels with hyperlinks or selectable text by using the itemLabel property.

Full code after the jump.

[click to continue…]

{ 0 comments }

The following example shows you how you can truncate a DataGrid column’s text and display a tool tip by setting a custom header renderer.

Full code after the jump.

[click to continue…]

{ 10 comments }

The following example shows how you can truncate the label on a CheckBox control in Flex by setting the width property.

Full code after the jump.

[click to continue…]

{ 0 comments }

The following example shows you how you create a custom Label control in Flex that masks its text as a password by setting the Label control’s nested protected UITextField control’s displayAsPassword property.

Full code after the jump.

[click to continue…]

{ 0 comments }

Truncating text in the Flex Label control using the truncateToFit property

by Peter deHaan January 26, 2008

The following example shows how you can use the truncateToFit property in the Label control in Flex to truncate strings if they exceed a specified width. The label control will terminate the string with “…” and allow you to roll over the text and read the entire (non-truncated) text in a tool tip, as seen [...]

Read the full article →

Listening for the link event in a Flex Label control

by Peter deHaan January 26, 2008

The following example shows how you can use the link event with the Label control in Flex to handle hyperlinks embedded within a string of text. By using the “event:” prefix in the href property of an anchor (<a />) tag, you can handle links within your Flex application, use the ExternalInterface API to call [...]

Read the full article →

Determining which button was pressed in a Flex ButtonBar component

by Peter deHaan January 9, 2008

The following example shows how you can determine which button was pressed in a ButtonBar control in Flex by listening for the itemClick event. You can then use the item, index, or label attribute in the ItemClickEvent object to find out which button was clicked.
Full code after the jump.

Read the full article →

Truncating labels in a Flex ComboBox dropdown menu using an item renderer

by Peter deHaan September 22, 2007

The following example shows how you can use a Label control as an item renderer in a Flex ComboBox control so that items which exceed the combo box dropdown menu’s width are truncated with a nice “…”.
Full code after the jump

Read the full article →