|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JToolTip
public class JToolTip
This class is used to display ToolTips. ToolTips are small floating windows that display text when the mouse comes to rest over a Component. ToolTips are set for JComponents using JComponent.setToolTipText(String).
Nested Class Summary | |
---|---|
protected class |
JToolTip.AccessibleJToolTip
Provides the accessibility features for the JToolTip
component. |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary |
---|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
JToolTip()
Creates a new JToolTip instance. |
Method Summary | |
---|---|
AccessibleContext |
getAccessibleContext()
Returns the object that provides accessibility features for this JToolTip component. |
JComponent |
getComponent()
Returns the component that the tool tip is associated with. |
String |
getTipText()
Returns the text displayed by the tool tip. |
ToolTipUI |
getUI()
Returns the current UI delegate for this component. |
String |
getUIClassID()
Returns the string suffix used to identify the UI class, in this case "ToolTipUI" . |
protected String |
paramString()
Returns a string describing the attributes for the JToolTip
component, for use in debugging. |
void |
setComponent(JComponent c)
Sets the component that the tool tip is associated with and sends a PropertyChangeEvent (with the property name 'component') to all
registered listeners. |
void |
setTipText(String tipText)
Sets the text to be displayed by the tool tip and sends a PropertyChangeEvent (with the property name 'tiptext') to all
registered listeners. |
void |
updateUI()
This method resets the UI used to the Look and Feel default. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public JToolTip()
JToolTip
instance.
Method Detail |
---|
public String getTipText()
null
).setTipText(String)
public AccessibleContext getAccessibleContext()
JToolTip
component.
getAccessibleContext
in interface Accessible
getAccessibleContext
in class JComponent
JToolTip.AccessibleJToolTip
).public JComponent getComponent()
null
).setComponent(JComponent)
public ToolTipUI getUI()
public String getUIClassID()
"ToolTipUI"
.
getUIClassID
in class JComponent
"ToolTipUI"
.JComponent.setUI(javax.swing.plaf.ComponentUI)
,
JComponent.updateUI()
protected String paramString()
JToolTip
component, for use in debugging. The return value is guaranteed to be
non-null
, but the format of the string may vary between
implementations.
paramString
in class JComponent
JToolTip
.public void setComponent(JComponent c)
PropertyChangeEvent
(with the property name 'component') to all
registered listeners.
c
- the component (null
permitted).getComponent()
public void setTipText(String tipText)
PropertyChangeEvent
(with the property name 'tiptext') to all
registered listeners.
tipText
- the text (null
permitted).getTipText()
public void updateUI()
updateUI
in class JComponent
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |