Package com.formdev.flatlaf.ui
Class FlatEditorPaneUI
- java.lang.Object
-
- javax.swing.plaf.ComponentUI
-
- javax.swing.plaf.TextUI
-
- javax.swing.plaf.basic.BasicTextUI
-
- javax.swing.plaf.basic.BasicEditorPaneUI
-
- com.formdev.flatlaf.ui.FlatEditorPaneUI
-
- All Implemented Interfaces:
FlatStylingSupport.StyleableUI,ViewFactory
public class FlatEditorPaneUI extends BasicEditorPaneUI implements FlatStylingSupport.StyleableUI
Provides the Flat LaF UI delegate forJEditorPane.- UiDefault:
- EditorPane.font Font, EditorPane.background Color, EditorPane.foreground Color also used if not editable, EditorPane.caretForeground Color, EditorPane.selectionBackground Color, EditorPane.selectionForeground Color, EditorPane.disabledBackground Color used if not enabled, EditorPane.inactiveBackground Color used if not editable, EditorPane.inactiveForeground Color used if not enabled (yes, this is confusing; this should be named disabledForeground), EditorPane.border Border, EditorPane.margin Insets, EditorPane.caretBlinkRate int default is 500 milliseconds , Component.minimumWidth int, Component.isIntelliJTheme boolean, EditorPane.focusedBackground Color optional
-
-
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 ColordisabledBackgroundprotected ColorfocusedBackgroundprotected ColorinactiveBackgroundprotected booleanisIntelliJThemeprotected intminimumWidth
-
Constructor Summary
Constructors Constructor Description FlatEditorPaneUI()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidapplyStyle(Object style)protected ObjectapplyStyleProperty(String key, Object value)protected CaretcreateCaret()static ComponentUIcreateUI(JComponent c)DimensiongetMinimumSize(JComponent c)DimensiongetPreferredSize(JComponent c)Map<String,Class<?>>getStyleableInfos(JComponent c)ObjectgetStyleableValue(JComponent c, String key)protected voidinstallDefaults()protected voidinstallListeners()protected voidinstallStyle()voidinstallUI(JComponent c)protected voidpaintBackground(Graphics g)protected voidpaintSafely(Graphics g)protected voidpropertyChange(PropertyChangeEvent e)protected voiduninstallDefaults()protected voiduninstallListeners()-
Methods inherited from class javax.swing.plaf.basic.BasicEditorPaneUI
getEditorKit, getPropertyPrefix, uninstallUI
-
Methods inherited from class javax.swing.plaf.basic.BasicTextUI
create, create, createHighlighter, createKeymap, damageRange, damageRange, getComponent, getKeymapName, getMaximumSize, getNextVisualPositionFrom, getRootView, getToolTipText, getVisibleEditorRect, installKeyboardActions, modelChanged, modelToView, modelToView, modelToView2D, paint, setView, uninstallKeyboardActions, update, viewToModel, viewToModel, viewToModel2D
-
Methods inherited from class javax.swing.plaf.TextUI
getToolTipText2D
-
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior
-
-
-
-
Method Detail
-
createUI
public static ComponentUI createUI(JComponent c)
-
installUI
public void installUI(JComponent c)
- Overrides:
installUIin classBasicEditorPaneUI
-
installDefaults
protected void installDefaults()
- Overrides:
installDefaultsin classBasicTextUI
-
uninstallDefaults
protected void uninstallDefaults()
- Overrides:
uninstallDefaultsin classBasicTextUI
-
installListeners
protected void installListeners()
- Overrides:
installListenersin classBasicTextUI
-
uninstallListeners
protected void uninstallListeners()
- Overrides:
uninstallListenersin classBasicTextUI
-
createCaret
protected Caret createCaret()
- Overrides:
createCaretin classBasicTextUI
-
propertyChange
protected void propertyChange(PropertyChangeEvent e)
- Overrides:
propertyChangein classBasicEditorPaneUI
-
installStyle
protected void installStyle()
- Since:
- 2
-
applyStyle
protected void applyStyle(Object style)
- Since:
- 2
-
getStyleableInfos
public Map<String,Class<?>> getStyleableInfos(JComponent c)
- Specified by:
getStyleableInfosin interfaceFlatStylingSupport.StyleableUI- Since:
- 2
-
getStyleableValue
public Object getStyleableValue(JComponent c, String key)
- Specified by:
getStyleableValuein interfaceFlatStylingSupport.StyleableUI- Since:
- 2.5
-
getPreferredSize
public Dimension getPreferredSize(JComponent c)
- Overrides:
getPreferredSizein classBasicTextUI
-
getMinimumSize
public Dimension getMinimumSize(JComponent c)
- Overrides:
getMinimumSizein classBasicTextUI
-
paintSafely
protected void paintSafely(Graphics g)
- Overrides:
paintSafelyin classBasicTextUI
-
paintBackground
protected void paintBackground(Graphics g)
- Overrides:
paintBackgroundin classBasicTextUI
-
-