All Packages Class Hierarchy This Package Previous Next Index
Class org.w3c.tools.widgets.Slider
java.lang.Object
|
+----java.awt.Component
|
+----java.awt.Canvas
|
+----org.w3c.tools.widgets.Slider
- public class Slider
- extends Canvas
Slider :
-
pointer
-
-
Slider()
- Constructs an invisible Slider.
-
Slider(int, boolean)
- Constructs an invisible Slider.
-
getGoodX(int)
-
-
getGraduationLength()
-
-
getMinimumSize()
- Gets the mininimum size of this component.
-
getValue()
- Get the current value pointed by the slider.
-
initialize(double, double, double)
- Initialize the slider's bounds and Step
-
initialize(double, double, double, boolean)
-
-
initialize(long, long, long)
-
-
initialize(long, long, long, boolean)
-
-
main(String[])
-
-
movePointerTo(int, int)
-
-
movePointerTo(Point)
-
-
paint(Graphics)
- paint the slider.
-
paintGraduation(Graphics)
-
-
setBounds(double, double)
- Set the bounds of the slider.
-
setColor(Color)
- Set the slider's color.
-
setDefaultSize(double, double, double)
-
-
setMax(double)
- Set the maximum bound of the slider.
-
setMin(double)
- Set the minimum bound of the slider.
-
setStep(double)
- Set the step of the slider.
-
setValue(double)
- Set the value pointed by the slider.
-
setValue(long)
-
-
update()
-
-
update(Graphics)
- update the slider.
-
updateCurrentGraduation()
-
-
updateGraduationPosition()
-
-
updatePointerPosition(double)
-
-
updateSize(Dimension)
- Resizes this component so that it has width "width" and height "height".
-
updateSize(int, int)
- Resizes this component so that it has width "width"
and height "height".
pointer
protected Slider. Pointer pointer
Slider
public Slider(int minPixelStep,
boolean border)
- Constructs an invisible Slider.
use initialize to define it.
- Parameters:
- minPixelStep - - the min step (in pixels) between two positions.
- border - - if true draw a border arround the slider.
Slider
public Slider()
- Constructs an invisible Slider.
use initialize to define it.
updateCurrentGraduation
protected void updateCurrentGraduation()
getGoodX
protected int getGoodX(int x)
getValue
public double getValue()
- Get the current value pointed by the slider.
- Returns:
- the value.
updatePointerPosition
protected void updatePointerPosition(double value)
setValue
public void setValue(double value)
- Set the value pointed by the slider.
if the value is too high, resize the slider.
- Parameters:
- The - value to point.
setValue
public void setValue(long value)
movePointerTo
protected void movePointerTo(int x,
int y)
movePointerTo
protected void movePointerTo(Point p)
paint
public void paint(Graphics g)
- paint the slider.
- Overrides:
- paint in class Canvas
getGraduationLength
protected int getGraduationLength()
updateGraduationPosition
protected void updateGraduationPosition()
paintGraduation
protected void paintGraduation(Graphics g)
update
public void update(Graphics g)
- update the slider.
- Overrides:
- update in class Component
setDefaultSize
protected void setDefaultSize(double min,
double max,
double step)
updateSize
public void updateSize(Dimension d)
- Resizes this component so that it has width "width" and height "height".
- Parameters:
- d - - The dimension specifying the new size of this slider.
updateSize
public void updateSize(int width,
int height)
- Resizes this component so that it has width "width"
and height "height".
- Parameters:
- width - - The new width of this slider
- height - - The new height of this slider
getMinimumSize
public Dimension getMinimumSize()
- Gets the mininimum size of this component.
- Returns:
- A dimension object indicating this slider's minimum size.
- Overrides:
- getMinimumSize in class Component
setColor
public void setColor(Color color)
- Set the slider's color.
- Parameters:
- color - - the slider's color.
setMin
public void setMin(double min)
- Set the minimum bound of the slider.
Use initialize or SetBounds if you want to set more than one value.
- Parameters:
- min - - the min bound
- See Also:
- setMax, setBounds, setStep, initialize
setMax
public void setMax(double max)
- Set the maximum bound of the slider.
Use initialize or SetBounds if you want to set more than one value.
- Parameters:
- max - - the max bound
- See Also:
- setMin, setBounds, setStep, initialize
setBounds
public void setBounds(double min,
double max)
- Set the bounds of the slider.
- Parameters:
- min - - the min bound
- max - - the max bound
- See Also:
- setMin, setMax, setStep, initialize
setStep
public void setStep(double step)
- Set the step of the slider.
Use initialize or SetBounds if you want to set more than one value.
- Parameters:
- step - - the step between two position
- See Also:
- setMin, setMax, setBounds, initialize
initialize
public void initialize(double min,
double max,
double step)
- Initialize the slider's bounds and Step
- Parameters:
- min - - the min bound
- max - - the max bound
- step - - the step between two position
- See Also:
- setMin, setMax, setBounds, initialize
initialize
public void initialize(double min,
double max,
double step,
boolean border)
initialize
public void initialize(long min,
long max,
long step)
initialize
public void initialize(long min,
long max,
long step,
boolean border)
update
protected void update()
main
public static void main(String argv[])
All Packages Class Hierarchy This Package Previous Next Index