![]() ![]() ![]() | |
![]() | |
![]() | |
![]() |
A label component is a single line of text. You can specify that a label be formatted with HTML. You can also control alignment and sizing of a label. Label components don't have borders, cannot be focused, and don't broadcast any events.
A live preview of each Label instance reflects changes made to parameters in the Property inspector or Component Inspector panel while authoring. The Label doesn't have a border, so the only way to see its live preview is to set its text parameter. If the text is too long, and you choose to set the autoSize parameter, the autoSize parameter is not supported by the live preview and the label's bounding box is not resized. You must click within the boundary box to select the label on the Stage.
When you add the Label component to an application, you can use the Accessibility panel to make it accessible to screen readers. First, you must add the following line of code to enable accessibility:
mx.accessibility.LabelAccImpl.enableAccessibility();
You only enable accessibility for a component once no matter how many instances you have of the component. For more information, see Creating Accessible Content.
![]() | |
![]() | |
![]() | |
![]() ![]() ![]() |