Package com.formdev.flatlaf.ui
Class FlatPasswordFieldUI
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.TextUI
-
- javax.swing.plaf.basic.BasicTextUI
-
- javax.swing.plaf.basic.BasicTextFieldUI
-
- com.formdev.flatlaf.ui.FlatTextFieldUI
-
- com.formdev.flatlaf.ui.FlatPasswordFieldUI
-
- All Implemented Interfaces:
ViewFactory
public class FlatPasswordFieldUI extends FlatTextFieldUI
Provides the Flat LaF UI delegate forJPasswordField.- UiDefault:
- PasswordField.font Font, PasswordField.background Color, PasswordField.foreground Color also used if not editable, PasswordField.caretForeground Color, PasswordField.selectionBackground Color, PasswordField.selectionForeground Color, PasswordField.disabledBackground Color used if not enabled, PasswordField.inactiveBackground Color used if not editable, PasswordField.inactiveForeground Color used if not enabled (yes, this is confusing; this should be named disabledForeground), PasswordField.border Border, PasswordField.margin Insets, PasswordField.caretBlinkRate int default is 500 milliseconds , Component.minimumWidth int, Component.isIntelliJTheme boolean, PasswordField.placeholderForeground Color, PasswordField.focusedBackground Color optional, TextComponent.selectAllOnFocusPolicy String never, once (default) or always, TextComponent.selectAllOnMouseClick boolean , PasswordField.echoChar character, PasswordField.showCapsLock boolean, PasswordField.capsLockIcon Icon
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class javax.swing.plaf.basic.BasicTextUI
BasicTextUI.BasicCaret, BasicTextUI.BasicHighlighter
-
-
Field Summary
Fields Modifier and Type Field Description protected IconcapsLockIconprotected booleanshowCapsLock-
Fields inherited from class com.formdev.flatlaf.ui.FlatTextFieldUI
focusedBackground, isIntelliJTheme, minimumWidth, placeholderForeground
-
-
Constructor Summary
Constructors Constructor Description FlatPasswordFieldUI()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Viewcreate(Element elem)static ComponentUIcreateUI(JComponent c)protected InsetsgetPadding()protected StringgetPropertyPrefix()protected voidinstallDefaults()protected voidinstallKeyboardActions()protected voidinstallListeners()protected booleanisCapsLockVisible()protected voidpaintCapsLock(Graphics g)protected voidpaintSafely(Graphics g)protected voiduninstallDefaults()protected voiduninstallListeners()-
Methods inherited from class com.formdev.flatlaf.ui.FlatTextFieldUI
createCaret, getMinimumSize, getPreferredSize, getVisibleEditorRect, paintBackground, paintPlaceholder, propertyChange, scrollCaretToVisible
-
Methods inherited from class javax.swing.plaf.basic.BasicTextFieldUI
getBaseline, getBaselineResizeBehavior
-
Methods inherited from class javax.swing.plaf.basic.BasicTextUI
create, createHighlighter, createKeymap, damageRange, damageRange, getComponent, getEditorKit, getKeymapName, getMaximumSize, getNextVisualPositionFrom, getRootView, getToolTipText, installUI, modelChanged, modelToView, modelToView, modelToView2D, paint, setView, uninstallKeyboardActions, uninstallUI, update, viewToModel, viewToModel, viewToModel2D
-
Methods inherited from class javax.swing.plaf.TextUI
getToolTipText2D
-
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount
-
-
-
-
Field Detail
-
showCapsLock
protected boolean showCapsLock
-
capsLockIcon
protected Icon capsLockIcon
-
-
Method Detail
-
createUI
public static ComponentUI createUI(JComponent c)
-
getPropertyPrefix
protected String getPropertyPrefix()
- Overrides:
getPropertyPrefixin classBasicTextFieldUI
-
installDefaults
protected void installDefaults()
- Overrides:
installDefaultsin classFlatTextFieldUI
-
uninstallDefaults
protected void uninstallDefaults()
- Overrides:
uninstallDefaultsin classFlatTextFieldUI
-
installListeners
protected void installListeners()
- Overrides:
installListenersin classFlatTextFieldUI
-
uninstallListeners
protected void uninstallListeners()
- Overrides:
uninstallListenersin classFlatTextFieldUI
-
installKeyboardActions
protected void installKeyboardActions()
- Overrides:
installKeyboardActionsin classBasicTextUI
-
create
public View create(Element elem)
- Specified by:
createin interfaceViewFactory- Overrides:
createin classBasicTextFieldUI
-
paintSafely
protected void paintSafely(Graphics g)
- Overrides:
paintSafelyin classFlatTextFieldUI
-
paintCapsLock
protected void paintCapsLock(Graphics g)
-
isCapsLockVisible
protected boolean isCapsLockVisible()
- Since:
- 1.4
-
getPadding
protected Insets getPadding()
- Overrides:
getPaddingin classFlatTextFieldUI- Since:
- 1.4
-
-