Class FlatSpinnerUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.SpinnerUI
javax.swing.plaf.basic.BasicSpinnerUI
com.formdev.flatlaf.ui.FlatSpinnerUI
- All Implemented Interfaces:
FlatStylingSupport.StyleableUI
Provides the Flat LaF UI delegate for
JSpinner.
- UiDefault:
- Spinner.font Font, Spinner.background Color, Spinner.foreground Color, Spinner.border Border, Spinner.disableOnBoundaryValues boolean default is false, Spinner.editorAlignment int 0=center, 2=left, 4=right, 10=leading, 11=trailing, Spinner.editorBorderPainted boolean paint inner editor border; defaults to false , Component.minimumWidth int, Spinner.buttonStyle String button (default), mac or none, Component.arrowType String chevron (default) or triangle, Spinner.disabledBackground Color, Spinner.disabledForeground Color, Spinner.focusedBackground Color optional, Spinner.buttonBackground Color optional, Spinner.buttonSeparatorWidth int or float optional; defaults to Component.borderWidth, Spinner.buttonSeparatorColor Color optional, Spinner.buttonDisabledSeparatorColor Color optional, Spinner.buttonArrowColor Color, Spinner.buttonDisabledArrowColor Color, Spinner.buttonHoverArrowColor Color, Spinner.buttonPressedArrowColor Color, Spinner.padding Insets
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected Colorprotected Colorprotected Colorprotected Colorprotected Colorprotected Colorprotected Colorprotected floatprotected Stringprotected Colorprotected Colorprotected Colorprotected intprotected InsetsFields inherited from class BasicSpinnerUI
spinner -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidapplyStyle(Object style) protected ObjectapplyStyleProperty(String key, Object value) protected voidconfigureEditor(JComponent editor) protected JComponentprotected LayoutManagerprotected Componentprotected Componentstatic ComponentUIprotected ColorgetBackground(boolean enabled) protected ColorgetForeground(boolean enabled) getStyleableValue(JComponent c, String key) protected voidprotected voidprotected voidvoidstatic booleanisPermanentFocusOwner(JSpinner spinner) protected voidreplaceEditor(JComponent oldEditor, JComponent newEditor) protected voidprotected voidvoidupdate(Graphics g, JComponent c) Methods inherited from class BasicSpinnerUI
createPropertyChangeListener, getBaseline, getBaselineResizeBehavior, installKeyboardActions, installNextButtonListeners, installPreviousButtonListeners, uninstallUIMethods inherited from class ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, getMinimumSize, getPreferredSize, paint
-
Field Details
-
minimumWidth
protected int minimumWidth -
buttonStyle
-
arrowType
-
disabledBackground
-
disabledForeground
-
focusedBackground
-
buttonBackground
-
buttonSeparatorWidth
protected float buttonSeparatorWidth- Since:
- 2
-
buttonSeparatorColor
- Since:
- 2
-
buttonDisabledSeparatorColor
- Since:
- 2
-
buttonArrowColor
-
buttonDisabledArrowColor
-
buttonHoverArrowColor
-
buttonPressedArrowColor
-
padding
-
-
Constructor Details
-
FlatSpinnerUI
public FlatSpinnerUI()
-
-
Method Details
-
createUI
-
installUI
- Overrides:
installUIin classBasicSpinnerUI
-
installDefaults
protected void installDefaults()- Overrides:
installDefaultsin classBasicSpinnerUI
-
uninstallDefaults
protected void uninstallDefaults()- Overrides:
uninstallDefaultsin classBasicSpinnerUI
-
installListeners
protected void installListeners()- Overrides:
installListenersin classBasicSpinnerUI
-
uninstallListeners
protected void uninstallListeners()- Overrides:
uninstallListenersin classBasicSpinnerUI
-
installStyle
protected void installStyle()- Since:
- 2
-
applyStyle
- Since:
- 2
-
applyStyleProperty
-
getStyleableInfos
- Specified by:
getStyleableInfosin interfaceFlatStylingSupport.StyleableUI- Since:
- 2
-
getStyleableValue
- Specified by:
getStyleableValuein interfaceFlatStylingSupport.StyleableUI- Since:
- 2.5
-
createEditor
- Overrides:
createEditorin classBasicSpinnerUI
-
replaceEditor
- Overrides:
replaceEditorin classBasicSpinnerUI
-
configureEditor
- Since:
- 1.6
-
isPermanentFocusOwner
- Since:
- 1.3
-
getBackground
-
getForeground
-
createLayout
- Overrides:
createLayoutin classBasicSpinnerUI
-
createNextButton
- Overrides:
createNextButtonin classBasicSpinnerUI
-
createPreviousButton
- Overrides:
createPreviousButtonin classBasicSpinnerUI
-
update
- Overrides:
updatein classComponentUI
-