|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Canvas | +--lcarsbeans.LcarsMLButton
A multiline button.
Inner classes inherited from class java.awt.Component |
java.awt.Component.AWTTreeLock |
Field Summary | |
static int |
taCenter
The label is drawn centered. |
static int |
taLeft
The label is drawn left aligned. |
static int |
taRight
The label is drawn right aligned. |
Fields inherited from class java.awt.Component |
actionListenerK,
adjustmentListenerK,
appContext,
background,
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
componentListener,
componentListenerK,
componentOrientation,
containerListenerK,
cursor,
dropTarget,
enabled,
eventMask,
focusListener,
focusListenerK,
font,
foreground,
hasFocus,
height,
incRate,
inputMethodListener,
inputMethodListenerK,
isInc,
isPacked,
itemListenerK,
keyListener,
keyListenerK,
LEFT_ALIGNMENT,
locale,
LOCK,
minSize,
mouseListener,
mouseListenerK,
mouseMotionListener,
mouseMotionListenerK,
newEventsOnly,
ownedWindowK,
parent,
peer,
peerFont,
popups,
prefSize,
RIGHT_ALIGNMENT,
textListenerK,
TOP_ALIGNMENT,
valid,
visible,
width,
windowListenerK,
x,
y |
Constructor Summary | |
LcarsMLButton()
Constructs a new instance. |
Method Summary | |
void |
addActionListener(java.awt.event.ActionListener l)
Adds an Action Listener. |
protected void |
fireAction()
Sends the Action-Event to all listeners. |
java.awt.Color |
getDisabledColor()
Returns the color which is used when the control is not enabled. |
java.awt.Color |
getEnabledColor()
Returns the color which is used when the control is enabled. |
java.awt.Color |
getFontColor()
Returns the color used for drawing the label. |
java.lang.String |
getHyphens()
Returns the possible hyphens. |
java.lang.String |
getLabel()
Returns the label. |
int |
getLabelMarginX()
Returns the horizontal margin between the label and the bound of the control. |
java.awt.Dimension |
getPreferredSize()
Returns the preferred size of the component. |
java.awt.Color |
getPressedColor()
Returns the color which is used when the button is pressed. |
int |
getTextAlignment()
Returns the horizontal alignment of the label. |
boolean |
isRoundLeft()
Returns whether the left side of the control is drawn rounded. |
boolean |
isRoundRight()
Returns whether the right side of the control is drawn rounded. |
void |
mouseClicked(java.awt.event.MouseEvent evt)
Event handler (not implemented) |
void |
mouseEntered(java.awt.event.MouseEvent evt)
Event handler (not implemented) |
void |
mouseExited(java.awt.event.MouseEvent evt)
Event handler (not implemented) |
void |
mousePressed(java.awt.event.MouseEvent evt)
Event handler |
void |
mouseReleased(java.awt.event.MouseEvent evt)
Event handler |
void |
paint(java.awt.Graphics g)
Paints the control. |
void |
removeActionListener(java.awt.event.ActionListener l)
Removes an Action Listener. |
void |
setDisabledColor(java.awt.Color newDisabledColor)
Sets the color which is used when the control is not enabled. |
void |
setEnabledColor(java.awt.Color newEnabledColor)
Sets the color which is used when the control is enabled. |
void |
setFontColor(java.awt.Color newFontColor)
Sets the color used for drawing the label. |
void |
setHyphens(java.lang.String newHyphens)
Sets the possible hyphens. If the label contains a character which is part of the hyphens string a line break will be made if necessary after that character. |
void |
setLabel(java.lang.String newLabel)
Sets the label. |
void |
setLabelMarginX(int newLabelMarginX)
Sets the horizontal margin between the label and the bound of the control if roundLeft or roundRight is set to false. |
void |
setPressedColor(java.awt.Color newPressedColor)
Sets the color which is used when the button is pressed. |
void |
setRoundLeft(boolean newRoundLeft)
Sets whether the left side of the control is drawn rounded. |
void |
setRoundRight(boolean newRoundRight)
Sets whether the right side of the control is drawn rounded. |
void |
setTextAlignment(int newTextAlignment)
Gets the horizontal alignment of the label. Possible values: taLeft, taCenter, taRight If the new value is not in the range between 0 and 2 the property is set to taLeft. |
void |
update(java.awt.Graphics g)
An overwritten and because of this almost flicker-free version of update(). |
Methods inherited from class java.awt.Canvas |
|
Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
areInputMethodsEnabled,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
deliverEvent,
disable,
disableEvents,
dispatchEvent,
dispatchEventImpl,
doLayout,
enable,
enable,
enableEvents,
enableInputMethods,
eventEnabled,
firePropertyChange,
getAlignmentX,
getAlignmentY,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentAt,
getComponentAt,
getComponentOrientation,
getCursor,
getDropTarget,
getFont_NoClientCode,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputContext,
getInputMethodRequests,
getLocale,
getLocation,
getLocation,
getLocationOnScreen,
getMaximumSize,
getMinimumSize,
getName,
getNativeContainer,
getParent_NoClientCode,
getParent,
getPeer,
getSize,
getSize,
getToolkit,
getToolkitImpl,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
invalidate,
isDisplayable,
isDoubleBuffered,
isEnabled,
isEnabledImpl,
isFocusTraversable,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
layout,
lightweightPrint,
list,
list,
list,
list,
list,
locate,
location,
lostFocus,
minimumSize,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
paramString,
postEvent,
preferredSize,
prepareImage,
prepareImage,
print,
printAll,
processComponentEvent,
processEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removeNotify,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setCursor,
setDropTarget,
setEnabled,
setFont,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus,
validate |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public static final int taLeft
public static final int taCenter
public static final int taRight
Constructor Detail |
public LcarsMLButton()
Method Detail |
public void paint(java.awt.Graphics g)
public void update(java.awt.Graphics g)
public java.awt.Dimension getPreferredSize()
public java.awt.Color getFontColor()
public void setFontColor(java.awt.Color newFontColor)
public java.lang.String getLabel()
public void setLabel(java.lang.String newLabel)
public java.lang.String getHyphens()
public void setHyphens(java.lang.String newHyphens)
public java.awt.Color getEnabledColor()
public void setEnabledColor(java.awt.Color newEnabledColor)
public java.awt.Color getPressedColor()
public void setPressedColor(java.awt.Color newPressedColor)
public java.awt.Color getDisabledColor()
public void setDisabledColor(java.awt.Color newDisabledColor)
public boolean isRoundLeft()
public void setRoundLeft(boolean newRoundLeft)
public boolean isRoundRight()
public void setRoundRight(boolean newRoundRight)
public int getTextAlignment()
public void setTextAlignment(int newTextAlignment)
public int getLabelMarginX()
public void setLabelMarginX(int newLabelMarginX)
public void mouseClicked(java.awt.event.MouseEvent evt)
public void mousePressed(java.awt.event.MouseEvent evt)
public void mouseReleased(java.awt.event.MouseEvent evt)
public void mouseEntered(java.awt.event.MouseEvent evt)
public void mouseExited(java.awt.event.MouseEvent evt)
protected void fireAction()
public void addActionListener(java.awt.event.ActionListener l)
public void removeActionListener(java.awt.event.ActionListener l)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |