Crossfire JXClient, Trunk
|
Public Member Functions | |
Dimension | getMaximumSize () |
Dimension | getMinimumSize () |
Dimension | getPreferredSize () |
TooltipText | getTooltip () |
GUIDupGauge (@NotNull final TooltipManager tooltipManager, @NotNull final GUIElementListener elementListener, @NotNull final String name, @NotNull final Image fullImageDiv, @NotNull final Image fullImageMod, @Nullable final Image emptyImage, @NotNull final Orientation orientationDiv, @NotNull final Orientation orientationMod, @Nullable final String tooltipPrefix, @NotNull final Color color, @NotNull final Font font, @Nullable final CommandList commandList, @NotNull final GuiFactory guiFactory) | |
void | mouseClicked (@NotNull final MouseEvent e) |
void | notifyOpen () |
void | paintComponent (@NotNull final Graphics g) |
void | setBounds (final int x, final int y, final int width, final int height) |
void | setHidden (final boolean hidden) |
void | setValues (final int curValue, final int minValue, final int maxValue, @NotNull final String labelText, @NotNull final String tooltipText) |
Public Member Functions inherited from com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement | |
void | dispose () |
int | getDialogBorderBottom () |
int | getDialogBorderLeft () |
int | getDialogBorderRight () |
int | getDialogBorderTop () |
String | getName () |
void | inhibitListeners () |
boolean | isDefault () |
boolean | isIgnore () |
void | mouseDragged (@NotNull final MouseEvent e) |
void | mouseEntered (@NotNull final MouseEvent e) |
void | mouseExited (@NotNull final MouseEvent e) |
void | mouseMoved (@NotNull final MouseEvent e) |
void | mousePressed (@NotNull final MouseEvent e) |
void | mouseReleased (@NotNull final MouseEvent e) |
void | mouseWheelMoved (final int wheelRotation) |
void | setChanged () |
void | setChangedListener (@Nullable final GUIElementChangedListener changedListener) |
void | setDefault (final boolean isDefault) |
void | setIgnore () |
String | toString () |
Private Member Functions | |
Dimension | getGaugeStateSize () |
Private Attributes | |
final Color | color |
final CommandList | commandList |
final Image | emptyImage |
final Font | font |
final GaugeState | gaugeStateDiv |
final GaugeState | gaugeStateMod |
String | labelText = "" |
final Orientation | orientationDiv |
final Orientation | orientationMod |
final String | tooltipPrefix |
String | tooltipText = "" |
Static Private Attributes | |
static final long | serialVersionUID = 1 |
Additional Inherited Members | |
Protected Member Functions inherited from com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement | |
AbstractGUIElement (@NotNull final TooltipManager tooltipManager, @NotNull final GUIElementListener elementListener, @NotNull final String name, final boolean opaque, @NotNull final GuiFactory guiFactory) | |
TooltipText | newTooltipText (@Nullable final String tooltipText) |
void | tooltipChanged () |
Displays a value as a graphical gauge that's filling state depends on the value.
Definition at line 47 of file GUIDupGauge.java.
com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge | ( | @NotNull final TooltipManager | tooltipManager, |
@NotNull final GUIElementListener | elementListener, | ||
@NotNull final String | name, | ||
@NotNull final Image | fullImageDiv, | ||
@NotNull final Image | fullImageMod, | ||
@Nullable final Image | emptyImage, | ||
@NotNull final Orientation | orientationDiv, | ||
@NotNull final Orientation | orientationMod, | ||
@Nullable final String | tooltipPrefix, | ||
@NotNull final Color | color, | ||
@NotNull final Font | font, | ||
@Nullable final CommandList | commandList, | ||
@NotNull final GuiFactory | guiFactory | ||
) |
Creates a new instance.
tooltipManager | the tooltip manager to update |
elementListener | the element listener to notify |
name | the name of this element |
fullImageDiv | the top image |
fullImageMod | the bottom image |
emptyImage | the image representing an empty gauge; if set to null
|
orientationDiv | the gauge's orientation |
orientationMod | the gauge's orientation |
tooltipPrefix | the prefix for displaying tooltips; if set to null
|
color | the text color |
font | the text font |
commandList | the command list that is executed on button 2 |
guiFactory | the global GUI factory instance |
Definition at line 140 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.color, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.commandList, com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.elementListener, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.emptyImage, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.font, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateMod, com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.guiFactory, com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.name, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationMod, com.realtime.crossfire.jxclient.gui.gauge.Orientation.setExtends(), com.realtime.crossfire.jxclient.gui.gauge.Orientation.setValues(), com.realtime.crossfire.jxclient.gui.gauge.GaugeState.setValues(), com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.tooltipManager, and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.tooltipPrefix.
|
private |
Returns the maximum size of gaugeStateDiv and gaugeStateMod.
Definition at line 208 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateMod, and com.realtime.crossfire.jxclient.gui.gauge.GaugeState.getPreferredSize().
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getMaximumSize(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getMinimumSize(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getPreferredSize().
Dimension com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getMaximumSize | ( | ) |
Definition at line 198 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getGaugeStateSize().
Dimension com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getMinimumSize | ( | ) |
Definition at line 191 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getGaugeStateSize().
Dimension com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getPreferredSize | ( | ) |
Definition at line 184 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getGaugeStateSize().
TooltipText com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getTooltip | ( | ) |
Returns the current tooltip text.
Reimplemented from com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.
Definition at line 280 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.newTooltipText(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.tooltipPrefix, and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.tooltipText.
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.mouseClicked | ( | @NotNull final MouseEvent | e | ) |
Will be called when the user has clicked (pressed+released) this element. This event will be delivered after mouseReleased(MouseEvent).
e | the mouse event relative to this element |
Reimplemented from com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.
Definition at line 256 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.commandList, and com.realtime.crossfire.jxclient.gui.commandlist.CommandList.execute().
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.notifyOpen | ( | ) |
Called each time the enclosing dialog is opened (or raised).
Implements com.realtime.crossfire.jxclient.gui.gui.GUIElement.
Definition at line 293 of file GUIDupGauge.java.
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent | ( | @NotNull final Graphics | g | ) |
Definition at line 162 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.color, com.realtime.crossfire.jxclient.gui.gauge.GaugeState.draw(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.emptyImage, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.font, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateMod, and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.labelText.
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setBounds | ( | final int | x, |
final int | y, | ||
final int | width, | ||
final int | height | ||
) |
Definition at line 243 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateMod, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationMod, com.realtime.crossfire.jxclient.gui.gauge.GaugeState.setDy(), and com.realtime.crossfire.jxclient.gui.gauge.Orientation.setExtends().
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setHidden | ( | final boolean | hidden | ) |
Specify whether this item should hide itself, independent of the "visibility" state.
hidden | whether the gauge is hidden |
Implements com.realtime.crossfire.jxclient.gui.gauge.GUIGaugeListener.
Definition at line 251 of file GUIDupGauge.java.
void com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues | ( | final int | curValue, |
final int | minValue, | ||
final int | maxValue, | ||
@NotNull final String | labelText, | ||
@NotNull final String | tooltipText | ||
) |
Sets the values to display.
curValue | the values to display |
minValue | the minimum possible value |
maxValue | the maximum possible value |
labelText | the label text |
tooltipText | the tooltip suffix |
Implements com.realtime.crossfire.jxclient.gui.gauge.GUIGaugeListener.
Definition at line 215 of file GUIDupGauge.java.
References com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.gaugeStateMod, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.labelText, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationDiv, com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.orientationMod, com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.setChanged(), com.realtime.crossfire.jxclient.gui.gauge.Orientation.setValues(), com.realtime.crossfire.jxclient.gui.gauge.GaugeState.setValues(), com.realtime.crossfire.jxclient.gui.gui.AbstractGUIElement.tooltipChanged(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.tooltipText.
|
private |
The text color.
Definition at line 114 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent().
|
private |
The CommandList that is executed on button 2.
Definition at line 71 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.mouseClicked().
|
private |
The image representing an empty gauge.
Definition at line 84 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent().
|
private |
The text font.
Definition at line 120 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent().
|
private |
The gauge state.
Definition at line 102 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getGaugeStateSize(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().
|
private |
The gauge state.
Definition at line 108 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getGaugeStateSize(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setBounds(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().
|
private |
The label text.
Definition at line 58 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.paintComponent(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().
|
private |
The gauge's orientation.
Definition at line 90 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setBounds(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().
|
private |
The gauge's orientation.
Definition at line 96 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge(), com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setBounds(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().
|
staticprivate |
The serial version UID.
Definition at line 52 of file GUIDupGauge.java.
|
private |
The tooltip prefix. It is prepended to tooltipText to form the tooltip.
Definition at line 65 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getTooltip(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.GUIDupGauge().
|
private |
The tooltip suffix. It is appended to tooltipPrefix to form the tooltip.
Definition at line 78 of file GUIDupGauge.java.
Referenced by com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.getTooltip(), and com.realtime.crossfire.jxclient.gui.gauge.GUIDupGauge.setValues().