new JLabel()static public CENTER:Numberstatic public TOP:Numberstatic public LEFT:Numberstatic public BOTTOM:Numberstatic public RIGHT:Numberstatic public HORIZONTAL:Numberstatic public VERTICAL:Numberpublic function updateUI():VoidDescription copied from Component
Resets the UI property to a value from the current look and feel.
Component subclasses must override this method
like this:
public void updateUI() {
setUI((SliderUI)UIManager.getUI(this);
}
public function setUI(newUI:LabelUI):VoidDescription copied from Component
Sets the look and feel delegate for this component.
Component subclasses generally override this method
to narrow the argument type. For example, in JSlider:
public void setUI(SliderUI newUI) {
super.setUI(newUI);
}
Additionally Component subclasses must provide a
getUI method that returns the correct type. For example:
public SliderUI getUI() {
return (SliderUI)ui;
}
public function getUIClassID():StringDescription copied from Component
Returns the UIDefaults key used to
look up the name of the org.aswing.plaf.ComponentUI
class that defines the look and feel
for this component. Most applications will never need to
call this method. Subclasses of Component that support
pluggable look and feel should override this method to
return a UIDefaults key that maps to the
ComponentUI subclass that defines their look and feel.
public function getDisabledIcon():IconReturns the icon used by the label when it's disabled. If no disabled icon has been set, the button constructs one from the default icon if defalut icon setted. otherwish return null;
The disabled icon really should be created (if necessary) by the L&F.-->
the disabledIcon property
public function setDisabledIcon(disabledIcon:Icon):VoidSets the disabled icon for the label.
disabledIcon | the icon used as the disabled image |
public function getVerticalAlignment():NumberReturns the vertical alignment of the text and icon.
the verticalAlignment property, one of the
following values:
public function setVerticalAlignment(alignment:Number):VoidSets the vertical alignment of the icon and text.
alignment | one of the following values:
|
public function getHorizontalAlignment():NumberReturns the horizontal alignment of the icon and text.
the horizontalAlignment property,
one of the following values:
public function setHorizontalAlignment(alignment:Number):VoidSets the horizontal alignment of the icon and text.
alignment | one of the following values:
|
public function getVerticalTextPosition():NumberReturns the vertical position of the text relative to the icon.
the verticalTextPosition property,
one of the following values:
public function setVerticalTextPosition(textPosition:Number):VoidSets the vertical position of the text relative to the icon.
public function getHorizontalTextPosition():NumberReturns the horizontal position of the text relative to the icon.
the horizontalTextPosition property,
one of the following values:
public function setHorizontalTextPosition(textPosition:Number):VoidSets the horizontal position of the text relative to the icon.
textPosition | one of the following values:
|
public function getIconTextGap():NumberReturns the amount of space between the text and the icon displayed in this button.
an int equal to the number of pixels between the text and the icon.