Class FVSliderUI


  • public class FVSliderUI
    extends javax.swing.plaf.basic.BasicSliderUI
    Custom UI for a slider that dynamically adjusts the thumb height based on the size of the given JScrollPane and {JTable}. Note: This is used instead of a {link BasicScrollBarUI} instance because of the complexity of trying to adjust the thumb size of a JScrollBar that is not attached to a JScrollPane instance.
    • Nested Class Summary

      • Nested classes/interfaces inherited from class javax.swing.plaf.basic.BasicSliderUI

        javax.swing.plaf.basic.BasicSliderUI.ActionScroller, javax.swing.plaf.basic.BasicSliderUI.ChangeHandler, javax.swing.plaf.basic.BasicSliderUI.ComponentHandler, javax.swing.plaf.basic.BasicSliderUI.FocusHandler, javax.swing.plaf.basic.BasicSliderUI.PropertyChangeHandler, javax.swing.plaf.basic.BasicSliderUI.ScrollListener, javax.swing.plaf.basic.BasicSliderUI.TrackListener
    • Field Summary

      • Fields inherited from class javax.swing.plaf.basic.BasicSliderUI

        changeListener, componentListener, contentRect, focusInsets, focusListener, focusRect, insetCache, labelRect, leftToRightCache, MAX_SCROLL, MIN_SCROLL, NEGATIVE_SCROLL, POSITIVE_SCROLL, propertyChangeListener, scrollListener, scrollTimer, slider, thumbRect, tickRect, trackBuffer, trackListener, trackRect
    • Constructor Summary

      Constructors 
      Constructor Description
      FVSliderUI​(javax.swing.JSlider slider, javax.swing.JScrollPane scrollPane, javax.swing.JTable table, ChunkReader reader, ChunkModel model)
      Constructor.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected void calculateThumbSize()
      This is the method that the base class uses to determine thumb size.
      • Methods inherited from class javax.swing.plaf.basic.BasicSliderUI

        calculateContentRect, calculateFocusRect, calculateGeometry, calculateLabelRect, calculateThumbLocation, calculateTickRect, calculateTrackBuffer, calculateTrackRect, createChangeListener, createComponentListener, createFocusListener, createPropertyChangeListener, createScrollListener, createTrackListener, createUI, drawInverted, getBaseline, getBaselineResizeBehavior, getFocusColor, getHeightOfHighValueLabel, getHeightOfLowValueLabel, getHeightOfTallestLabel, getHighestValue, getHighestValueLabel, getHighlightColor, getLowestValue, getLowestValueLabel, getMaximumSize, getMinimumHorizontalSize, getMinimumSize, getMinimumVerticalSize, getPreferredHorizontalSize, getPreferredSize, getPreferredVerticalSize, getShadowColor, getThumbSize, getTickLength, getWidthOfHighValueLabel, getWidthOfLowValueLabel, getWidthOfWidestLabel, installDefaults, installKeyboardActions, installListeners, installUI, isDragging, labelsHaveSameBaselines, paint, paintFocus, paintHorizontalLabel, paintLabels, paintMajorTickForHorizSlider, paintMajorTickForVertSlider, paintMinorTickForHorizSlider, paintMinorTickForVertSlider, paintThumb, paintTicks, paintTrack, paintVerticalLabel, recalculateIfInsetsChanged, recalculateIfOrientationChanged, scrollByBlock, scrollByUnit, scrollDueToClickInTrack, setThumbLocation, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUI, valueForXPosition, valueForYPosition, xPositionForValue, yPositionForValue, yPositionForValue
      • Methods inherited from class javax.swing.plaf.ComponentUI

        contains, getAccessibleChild, getAccessibleChildrenCount, update
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • FVSliderUI

        public FVSliderUI​(javax.swing.JSlider slider,
                          javax.swing.JScrollPane scrollPane,
                          javax.swing.JTable table,
                          ChunkReader reader,
                          ChunkModel model)
        Constructor.
        Parameters:
        slider -
        scrollPane -
        table -
        reader -
        model -
    • Method Detail

      • calculateThumbSize

        protected void calculateThumbSize()
        This is the method that the base class uses to determine thumb size. We override so it can be determined by the size of the table and the viewport.
        Overrides:
        calculateThumbSize in class javax.swing.plaf.basic.BasicSliderUI