Package org.jdesktop.swingx.plaf
Class PromptTextAreaUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.TextUI
org.jdesktop.swingx.plaf.PromptTextUI
org.jdesktop.swingx.plaf.PromptTextAreaUI
PromptTextUI
implementation for rendering prompts on
JTextArea
s and uses a JTextArea
as a prompt component.- Author:
- Peter Weishapl petw@gmx.net
-
Nested Class Summary
Nested classes/interfaces inherited from class org.jdesktop.swingx.plaf.PromptTextUI
PromptTextUI.PainterHighlighter
-
Field Summary
Fields inherited from class org.jdesktop.swingx.plaf.PromptTextUI
delegate, promptComponent
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected JTextComponent
Returns a sharedJTextArea
.OverridesgetPromptComponent(JTextComponent)
to additionally updateJTextArea
specific properties.modelToView
(JTextComponent t, int pos) Deprecated.Methods inherited from class org.jdesktop.swingx.plaf.PromptTextUI
contains, damageRange, damageRange, equals, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getEditorKit, getMaximumSize, getMinimumSize, getNextVisualPositionFrom, getPreferredSize, getRootView, getToolTipText2D, hashCode, installUI, modelToView, modelToView2D, modelToView2D, paint, paintPromptComponent, shouldPaintPrompt, toString, uninstallUI, update, viewToModel, viewToModel, viewToModel2D
Methods inherited from class javax.swing.plaf.TextUI
getToolTipText
Methods inherited from class javax.swing.plaf.ComponentUI
createUI, getBaselineResizeBehavior
-
Constructor Details
-
PromptTextAreaUI
Creates a newPromptTextAreaUI
.- Parameters:
delegate
-
-
-
Method Details
-
getPromptComponent
OverridesgetPromptComponent(JTextComponent)
to additionally updateJTextArea
specific properties.- Overrides:
getPromptComponent
in classPromptTextUI
- Parameters:
txt
- JTextComponent- Returns:
- the adjusted prompt component
-
createPromptComponent
Returns a sharedJTextArea
.- Specified by:
createPromptComponent
in classPromptTextUI
- Returns:
- JTextComponent
-
modelToView
Deprecated.- Overrides:
modelToView
in classPromptTextUI
- Throws:
BadLocationException
-