buoy.widget
Class BProgressBar
public class BProgressBar
BProgressBar is a Widget that displays the status of some operation. It is a horizontal or vertical
bar that gradually fills up to indicate what fraction of the operation is complete. It optionally
can also display a line of text describing the current state of the operation.
You can specify minimum and maximum progress values for the bar, to reflect the number of steps in
the operation being monitored. When the current progress value is equal to the minimum value, the
bar is shown completely empty. When it is equal to the maximum value, the bar is shown completely
full.
If you do not know how long an operation will take, the progress bar can be put into an
"indeterminate" state. This causes the entire bar to animate continuously to show that work
is being done.
int | getMaximum() - Get the progress bar's maximum progress value.
|
int | getMinimum() - Get the progress bar's minimum progress value.
|
BProgressBar.Orientation | getOrientation() - Get the progress bar's orientation, HORIZONTAL or VERTICAL.
|
String | getProgressText() - Get the line of text displayed on the progress bar.
|
boolean | getShowProgressText() - Get whether the progress bar displays a line of text describing the operation whose progress
is being monitored.
|
int | getValue() - Get the progress bar's current progress value.
|
boolean | isIndeterminate() - Get whether this progress bar is in indeterminate mode.
|
void | setIndeterminate(boolean indeterminate) - Set whether this progress bar is in indeterminate mode.
|
void | setMaximum(int max) - Set the progress bar's maximum progress value.
|
void | setMinimum(int min) - Set the progress bar's minimum progress value.
|
void | setOrientation(BProgressBar.Orientation orient) - Set the progress bar's orientation, HORIZONTAL or VERTICAL.
|
void | setProgressText(String text) - Set the line of text displayed on the progress bar.
|
void | setShowProgressText(boolean show) - Set whether the progress bar displays a line of text describing the operation whose progress
is being monitored.
|
void | setValue(int value) - Set the progress bar's current progress value.
|
addEventLink , dispatchEvent , getBackground , getBounds , getComponent , getCursor , getFont , getMaximumSize , getMinimumSize , getName , getParent , getPreferredSize , hasFocus , isEnabled , isFocusable , isVisible , repaint , requestFocus , setBackground , setCursor , setEnabled , setFocusable , setFont , setName , setVisible |
BProgressBar
public BProgressBar()
Create a horizontal BProgressBar which does not display text. The minimum and maximum progress
values are 0 and 100, respectively.
BProgressBar
public BProgressBar(BProgressBar.Orientation orient,
int min,
int max)
Create a new BProgressBar. The initial progress value is set to min.
orient
- the progress bar orientation (HORIZONTAL or VERTICAL)min
- the minimum value on the progress barmax
- the maximum value on the progress bar
BProgressBar
public BProgressBar(int min,
int max)
Create a horizontal BProgressBar which does not display text. The initial progress value is
set to min.
min
- the minimum value on the progress barmax
- the maximum value on the progress bar
getMaximum
public int getMaximum()
Get the progress bar's maximum progress value.
getMinimum
public int getMinimum()
Get the progress bar's minimum progress value.
getOrientation
public BProgressBar.Orientation getOrientation()
Get the progress bar's orientation, HORIZONTAL or VERTICAL.
getProgressText
public String getProgressText()
Get the line of text displayed on the progress bar. This text is only shown if
setShowProgessText(true) has been called.
getShowProgressText
public boolean getShowProgressText()
Get whether the progress bar displays a line of text describing the operation whose progress
is being monitored.
getValue
public int getValue()
Get the progress bar's current progress value.
isIndeterminate
public boolean isIndeterminate()
Get whether this progress bar is in indeterminate mode. In indeterminate mode, the entire
progress bar animates continuously to show that work is being done, but no indication is given
of how much remains.
setIndeterminate
public void setIndeterminate(boolean indeterminate)
Set whether this progress bar is in indeterminate mode. In indeterminate mode, the entire
progress bar animates continuously to show that work is being done, but no indication is given
of how much remains.
setMaximum
public void setMaximum(int max)
Set the progress bar's maximum progress value.
setMinimum
public void setMinimum(int min)
Set the progress bar's minimum progress value.
setOrientation
public void setOrientation(BProgressBar.Orientation orient)
Set the progress bar's orientation, HORIZONTAL or VERTICAL.
setProgressText
public void setProgressText(String text)
Set the line of text displayed on the progress bar. This text is only shown if
setShowProgessText(true) has been called.
setShowProgressText
public void setShowProgressText(boolean show)
Set whether the progress bar displays a line of text describing the operation whose progress
is being monitored.
setValue
public void setValue(int value)
Set the progress bar's current progress value.
Written by Peter Eastman.