Category Archives: ButtonBar (Spark)

Removing the selected highlight from the Spark ButtonBar control in Flex 4 (redux)

In a previous example, “Removing the selected highlight from the Spark ButtonBar control in Flex 4”, we saw how you can remove the selected highlight from the Spark ButtonBar control in Flex 4 by creating a custom ButtonBar and ButtonBarButton skin class.

The following example shows how you can remove the selected highlight from the Spark ButtonBar control in Flex 4 by extending the Spark ButtonBarButton class and creating a custom Spark ButtonBar skin.

Continue reading Removing the selected highlight from the Spark ButtonBar control in Flex 4 (redux)

Creating a custom label function on a Spark ButtonBar control in Flex 4

In a previous example, “Creating a custom label function on a Flex ButtonBar control”, we saw how you could use a custom label function to create button labels on an MX ButtonBar control in Flex by setting the labelFunction property.

The following example shows how you can set a custom label function to create button labels on a Spark ButtonBar control in Flex 4 by setting the labelFunction property.

Full code after the jump.

Continue reading Creating a custom label function on a Spark ButtonBar control in Flex 4

Styling the selected tab on a Spark TabBar control in Flex 4

In a previous example, “Styling the selected button on a Spark ButtonBar control in Flex 4”, we saw how you could style the currently selected button on a Flex 4 Spark ButtonBar control by styling the various states on the Spark ButtonBarButton selector.

The following example shows how you can style the currently selected tab on a Flex 4 Spark TabBar control by styling the various states on the Spark ButtonBarButton selector.

Continue reading Styling the selected tab on a Spark TabBar control in Flex 4

Accessing specific buttons in a Spark ButtonBar control in Flex 4

In a suspiciously similar previous example, “Disabling specific buttons in a Spark ButtonBar control in Flex 4”, we saw how you could disable specific buttons in a Spark ButtonBar control in Flex 4 by using a custom skin and setting the skinClass style.

The following example shows you how you can modify specific buttons at runtime using the Flex 4 Spark ButtonBar control’s dataGroup property and getElementAt() method.

Full code after the jump.

Continue reading Accessing specific buttons in a Spark ButtonBar control in Flex 4