Class SubstanceProgressBarUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ProgressBarUI
javax.swing.plaf.basic.BasicProgressBarUI
org.pushingpixels.substance.internal.ui.SubstanceProgressBarUI
UI for progress bars in Substance look and feel.
-
Nested Class Summary
Nested classes/interfaces inherited from class javax.swing.plaf.basic.BasicProgressBarUI
BasicProgressBarUI.ChangeHandler -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected intprotected org.pushingpixels.trident.Timelineprotected org.pushingpixels.trident.Timelineprotected intInner margin.protected floatThe speed factor for the indeterminate progress bars.protected PropertyChangeListenerProperty change listener.protected ChangeListenerValue change listener on the associated progress bar.Fields inherited from class javax.swing.plaf.basic.BasicProgressBarUI
boxRect, changeListener, progressBar -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic ComponentUIcreateUI(JComponent comp) protected intgetAmountFull(Insets b, int width, int height) protected Rectanglestatic StringReturns the memory usage string.protected Dimensionprotected Dimensionprotected Colorprotected Colorprotected RectanglegetStringRectangle(String progressString, int x, int y, int width, int height) Returns the rectangle for the progress bar string.protected voidprotected voidvoidvoidprotected voidpaintString(Graphics g, int x, int y, int width, int height, int amountFull, Insets b) protected voidprotected voidprotected voidMethods inherited from class javax.swing.plaf.basic.BasicProgressBarUI
getAnimationIndex, getBaseline, getBaselineResizeBehavior, getBoxLength, getCellLength, getCellSpacing, getFrameCount, getMaximumSize, getMinimumSize, getPreferredSize, getStringPlacement, incrementAnimationIndex, installUI, paint, setAnimationIndex, setCellLength, setCellSpacing, uninstallDefaults, uninstallUIMethods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, update
-
Field Details
-
substanceValueChangeListener
Value change listener on the associated progress bar. -
substancePropertyChangeListener
Property change listener. Tracks changes to thefontproperty. -
margin
protected int marginInner margin. -
speed
protected float speedThe speed factor for the indeterminate progress bars. -
displayedValue
protected int displayedValue -
displayTimeline
protected org.pushingpixels.trident.Timeline displayTimeline -
indeterminateLoopTimeline
protected org.pushingpixels.trident.Timeline indeterminateLoopTimeline
-
-
Constructor Details
-
SubstanceProgressBarUI
public SubstanceProgressBarUI()
-
-
Method Details
-
createUI
-
installDefaults
protected void installDefaults()- Overrides:
installDefaultsin classBasicProgressBarUI
-
installListeners
protected void installListeners()- Overrides:
installListenersin classBasicProgressBarUI
-
uninstallListeners
protected void uninstallListeners()- Overrides:
uninstallListenersin classBasicProgressBarUI
-
paintDeterminate
- Overrides:
paintDeterminatein classBasicProgressBarUI
-
getSelectionBackground
- Overrides:
getSelectionBackgroundin classBasicProgressBarUI
-
getSelectionForeground
- Overrides:
getSelectionForegroundin classBasicProgressBarUI
-
paintIndeterminate
- Overrides:
paintIndeterminatein classBasicProgressBarUI
-
getBox
- Overrides:
getBoxin classBasicProgressBarUI
-
startAnimationTimer
protected void startAnimationTimer()- Overrides:
startAnimationTimerin classBasicProgressBarUI
-
stopAnimationTimer
protected void stopAnimationTimer()- Overrides:
stopAnimationTimerin classBasicProgressBarUI
-
getMemoryUsage
Returns the memory usage string.- Returns:
- The memory usage string.
-
getAmountFull
- Overrides:
getAmountFullin classBasicProgressBarUI
-
getPreferredInnerHorizontal
- Overrides:
getPreferredInnerHorizontalin classBasicProgressBarUI
-
getPreferredInnerVertical
- Overrides:
getPreferredInnerVerticalin classBasicProgressBarUI
-
paintString
protected void paintString(Graphics g, int x, int y, int width, int height, int amountFull, Insets b) - Overrides:
paintStringin classBasicProgressBarUI
-
getStringRectangle
Returns the rectangle for the progress bar string.- Parameters:
progressString- Progress bar string.x- x location of bounding boxy- y location of bounding boxwidth- width of bounding boxheight- height of bounding box- Returns:
- The rectangle for the progress bar string.
-