Class SpinningCalendarHeaderHandler.SpinningCalendarHeader

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.jdesktop.swingx.JXPanel
org.jdesktop.swingx.plaf.basic.SpinningCalendarHeaderHandler.SpinningCalendarHeader
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible, Scrollable, AlphaPaintable, BackgroundPaintable
Enclosing class:
SpinningCalendarHeaderHandler

protected static class SpinningCalendarHeaderHandler.SpinningCalendarHeader extends JXPanel
The custom header component controlled and configured by this handler.
See Also:
  • Field Details

    • prevButton

      private AbstractButton prevButton
    • nextButton

      private AbstractButton nextButton
    • monthText

      private JLabel monthText
    • yearSpinner

      private JSpinner yearSpinner
    • surroundMonth

      private boolean surroundMonth
  • Constructor Details

    • SpinningCalendarHeader

      public SpinningCalendarHeader()
  • Method Details

    • setActions

      public void setActions(Action prev, Action next, SpinnerModel model)
      Installs the actions and models to be used by this component.
      Parameters:
      prev - the action to use for the previous button
      next - the action to use for the next button
      model - the spinner model to use for the spinner.
    • setSpinnerFocusable

      public void setSpinnerFocusable(boolean focusable)
      Sets the focusable property of the spinner's editor's text field. The default value is false.
      Parameters:
      focusable - the focusable property of the spinner's editor.
    • setArrowsSurroundMonth

      public void setArrowsSurroundMonth(boolean surroundMonth)
      The default value is false.
      Parameters:
      surroundMonth -
    • setMonthText

      public void setMonthText(String text)
      Sets the text to use for the month label.
      Parameters:
      text - the text to use for the month label.
    • setFont

      public void setFont(Font font)

      Overridden to set the font of its child components.

      Overrides:
      setFont in class JComponent
    • setBackground

      public void setBackground(Color bg)

      Overridden to set the background of its child compenents.

      Overrides:
      setBackground in class JComponent
    • installZoomAction

      private void installZoomAction(SpinnerModel model)
    • uninstallZoomAction

      private void uninstallZoomAction()
    • initComponents

      private void initComponents()
    • addComponents

      private void addComponents()
    • createComponents

      private void createComponents()
    • createMonthText

      private JLabel createMonthText()
    • createSpinner

      private JSpinner createSpinner()
      Creates and returns the JSpinner used for year navigation.
      Returns:
    • createNavigationButton

      private AbstractButton createNavigationButton()