|
NextApp Echo2 v2.1.0.rc2 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnextapp.echo2.app.Component
nextapp.echo2.app.Label
public class Label
A component which displays a text string, an icon, or both.
| Field Summary | |
|---|---|
static String |
PROPERTY_ICON
|
static String |
PROPERTY_ICON_TEXT_MARGIN
|
static String |
PROPERTY_LINE_WRAP
|
static String |
PROPERTY_TEXT
|
static String |
PROPERTY_TEXT_ALIGNMENT
|
static String |
PROPERTY_TEXT_POSITION
|
static String |
PROPERTY_TOOL_TIP_TEXT
|
| Constructor Summary | |
|---|---|
Label()
Creates a label with no text or icon. |
|
Label(ImageReference icon)
Creates a label with an icon. |
|
Label(String text)
Creates a label with text. |
|
Label(String text,
ImageReference icon)
Creates a label with text and an icon. |
|
| Method Summary | |
|---|---|
ImageReference |
getIcon()
Returns the icon of the label. |
Extent |
getIconTextMargin()
Returns the margin size between the icon and the text. |
String |
getText()
Returns the text of the label. |
Alignment |
getTextAlignment()
Returns the alignment of the text relative to the icon. |
Alignment |
getTextPosition()
Returns the position of the text relative to the icon. |
String |
getToolTipText()
Returns the tool tip text (displayed when the mouse cursor is hovered over the component). |
boolean |
isLineWrap()
Determines if the text of the label should wrap in the event that horizontal space is limited. |
boolean |
isValidChild(Component component)
This component does not support children. |
void |
setIcon(ImageReference newValue)
Sets the icon to be displayed. |
void |
setIconTextMargin(Extent newValue)
Sets the margin size between the icon and the text. |
void |
setLineWrap(boolean newValue)
Sets whether the text of the label should wrap in the event that horizontal space is limited. |
void |
setText(String newValue)
Sets the text to be displayed. |
void |
setTextAlignment(Alignment newValue)
Sets the alignment of the text relative to the icon. |
void |
setTextPosition(Alignment newValue)
Sets the position of the text relative to the icon. |
void |
setToolTipText(String newValue)
Sets the tool tip text (displayed when the mouse cursor is hovered over the component). |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String PROPERTY_ICON
public static final String PROPERTY_ICON_TEXT_MARGIN
public static final String PROPERTY_LINE_WRAP
public static final String PROPERTY_TEXT
public static final String PROPERTY_TEXT_ALIGNMENT
public static final String PROPERTY_TEXT_POSITION
public static final String PROPERTY_TOOL_TIP_TEXT
| Constructor Detail |
|---|
public Label()
public Label(String text)
text - the text to be displayedpublic Label(ImageReference icon)
icon - the icon to be displayed
public Label(String text,
ImageReference icon)
text - the text to be displayedicon - the icon to be displayed| Method Detail |
|---|
public ImageReference getIcon()
public Extent getIconTextMargin()
public String getText()
public Alignment getTextAlignment()
public Alignment getTextPosition()
public String getToolTipText()
public boolean isLineWrap()
public boolean isValidChild(Component component)
isValidChild in class Componentcomponent - the Component to evaluate as a child
Component is a valid childComponent.isValidChild(nextapp.echo2.app.Component)public void setIcon(ImageReference newValue)
newValue - the icon to be displayedpublic void setIconTextMargin(Extent newValue)
newValue - the margin sizepublic void setLineWrap(boolean newValue)
newValue - the new line wrap statepublic void setText(String newValue)
newValue - the text to be displayedpublic void setTextAlignment(Alignment newValue)
Alignment's
settings should be non-default.
newValue - the new text positionpublic void setTextPosition(Alignment newValue)
Alignment's
settings should be non-default.
newValue - the new text positionpublic void setToolTipText(String newValue)
newValue - the new tool tip text
|
NextApp Echo2 v2.1.0.rc2 |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||