Monthly Archives: January 2009

Displaying icons in a Flex PopUpButton control (Redux)

In a previous example, “Displaying icons in a Flex PopUpButton control”, we saw how you could add icons to a PopUpButton control’s nested menu using an Array data provider.

The following example shows you how you can add icons to a pop up menu in a PopUpButton control in Flex by specifying the iconField property in the PopUpButton control’s nested Menu control using an XML data provider.

Full code after the jump.

Continue reading Displaying icons in a Flex PopUpButton control (Redux)

Setting the block progression on a TextView control in Flex Gumbo

The following example shows how you can set the block progression on a Flex Gumbo TextView by setting the blockProgression style to one of the static constants in the BlockProgression class (flashx.textLayout.formats.BlockProgression).

Valid values for the blockProgression style are:

  • “tb” (BlockProgression.TB): Top to bottom. Lines are laid out horizontally starting at the top of the container and progressing down to the bottom. Used for horizontal text. (Default)
  • “rl” (BlockProgression.RL): Right to left. Lines are laid out vertically starting at the right edge of the container and progressing leftward. Used for vertical text, for instance, vertical Chinese or Japanese text.

Full code after the jump.

Continue reading Setting the block progression on a TextView control in Flex Gumbo