|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.xith3d.ui.hud.base.Widget
org.xith3d.ui.hud.base.BackgroundSettableWidget
org.xith3d.ui.hud.widgets.ProgressBar
public class ProgressBar
| Nested Class Summary | |
|---|---|
static class |
ProgressBar.Description
This class is used to describe a ProgressBar Widget. |
| Nested classes/interfaces inherited from class org.xith3d.ui.hud.base.BackgroundSettableWidget |
|---|
BackgroundSettableWidget.BackgroundSettableDescriptionBase |
| Nested classes/interfaces inherited from class org.xith3d.ui.hud.base.Widget |
|---|
Widget.DescriptionBase |
| Field Summary | |
|---|---|
protected static boolean |
DEFAULT_HEAVYWEIGHT
|
| Fields inherited from class org.xith3d.ui.hud.base.Widget |
|---|
transformHeight_Pixels2HUD, transformWidth_Pixels2HUD |
| Constructor Summary | |
|---|---|
ProgressBar(boolean isHeavyWeight,
float width,
float height)
Creates a new ProgressBar. |
|
ProgressBar(boolean isHeavyWeight,
float width,
float height,
int minValue,
int maxValue)
Creates a new ProgressBar. |
|
ProgressBar(boolean isHeavyWeight,
float width,
float height,
int minValue,
int maxValue,
ProgressBar.Description desc)
Creates a new ProgressBar. |
|
ProgressBar(float width,
float height)
Creates a new ProgressBar. |
|
ProgressBar(float width,
float height,
int minValue,
int maxValue)
Creates a new ProgressBar. |
|
ProgressBar(float width,
float height,
int minValue,
int maxValue,
ProgressBar.Description desc)
Creates a new ProgressBar. |
|
| Method Summary | |
|---|---|
protected void |
drawWidget(Texture2DCanvas texCanvas,
int offsetX,
int offsetY,
int width,
int height,
boolean drawsSelf)
|
HUDFont |
getFont()
|
org.openmali.vecmath2.Colorf |
getFontColor()
|
int |
getMaxValue()
|
int |
getMinValue()
|
int |
getValue()
|
protected void |
init()
This method is called when the WidgetContainer is set. |
protected java.lang.String |
makeText()
Creates the ProgressBar's percentage text from the current value. |
void |
setFont(HUDFont font)
Sets the Font to use for the percent value in the center of the ProgressBar. |
void |
setFont(HUDFont font,
org.openmali.vecmath2.Colorf color)
Sets the Font to use for the percent value in the center of the ProgressBar. |
void |
setFontColor(org.openmali.vecmath2.Colorf color)
Sets the Font color to use for the percent value in the center of the ProgressBar. |
void |
setMaxValue(int maxValue)
Sets the maximum value this ProgressBar can take. |
void |
setMinAndMaxValue(int minValue,
int maxValue)
|
void |
setMinMaxAndValue(int minValue,
int maxValue,
int value)
|
void |
setMinValue(int minValue)
Sets the minimum value this ProgressBar can take. |
void |
setValue(int value)
Sets the current value of this ProgressBar. |
protected void |
setValue(int value,
boolean forced)
Sets the current value of this ProgressBar. |
| Methods inherited from class org.xith3d.ui.hud.base.BackgroundSettableWidget |
|---|
drawBackground, getBackgroundColor, getBackgroundTexture, getBackgroundTileMode, setBackground, setBackground, setBackground, setBackgroundColor, setBackgroundTexture, setBackgroundTexture, setBackgroundTexture, setBackgroundTexture, setBackgroundTileMode, setNoBackground |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
protected static final boolean DEFAULT_HEAVYWEIGHT
| Constructor Detail |
|---|
public ProgressBar(boolean isHeavyWeight,
float width,
float height,
int minValue,
int maxValue,
ProgressBar.Description desc)
isHeavyWeight - width - the desired widthheight - the desired heightminValue - the initial minimum valuemaxValue - the initial maximum valuedesc - the ProgressBar.Description to describe this ProgressBar
public ProgressBar(boolean isHeavyWeight,
float width,
float height,
int minValue,
int maxValue)
isHeavyWeight - width - the desired widthheight - the desired heightminValue - the initial minimum valuemaxValue - the initial maximum value
public ProgressBar(boolean isHeavyWeight,
float width,
float height)
isHeavyWeight - width - the desired widthheight - the desired height
public ProgressBar(float width,
float height,
int minValue,
int maxValue,
ProgressBar.Description desc)
width - the desired widthheight - the desired heightminValue - the initial minimum valuemaxValue - the initial maximum valuedesc - the ProgressBar.Description to describe this ProgressBar
public ProgressBar(float width,
float height,
int minValue,
int maxValue)
width - the desired widthheight - the desired heightminValue - the initial minimum valuemaxValue - the initial maximum value
public ProgressBar(float width,
float height)
width - the desired widthheight - the desired height| Method Detail |
|---|
public void setFont(HUDFont font)
font - the Fontpublic final HUDFont getFont()
public void setFontColor(org.openmali.vecmath2.Colorf color)
color - the Colorpublic final org.openmali.vecmath2.Colorf getFontColor()
public final void setFont(HUDFont font,
org.openmali.vecmath2.Colorf color)
font - the Fontcolor - the font-colorpublic void setMinValue(int minValue)
minValue - the new minimum valuepublic final int getMinValue()
public void setMaxValue(int maxValue)
maxValue - the new minimum valuepublic final int getMaxValue()
public final void setMinAndMaxValue(int minValue,
int maxValue)
public final void setMinMaxAndValue(int minValue,
int maxValue,
int value)
protected java.lang.String makeText()
protected void setValue(int value,
boolean forced)
value - the new valueforced - public final void setValue(int value)
value - the new valuepublic final int getValue()
protected void drawWidget(Texture2DCanvas texCanvas,
int offsetX,
int offsetY,
int width,
int height,
boolean drawsSelf)
drawWidget in class Widgetprotected void init()
init in class Widget
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||