ToolTips in the system.
ToolTipManager contains numerous properties for configuring how long it
will take for the tooltips to become visible, and how long till they
hide. Consider a component that has a different tooltip based on where
the mouse is, such as JTree. When the mouse moves into the JTree and
over a region that has a valid tooltip, the tooltip will become
visible after initialDelay milliseconds. After
dismissDelay milliseconds the tooltip will be hidden. If
the mouse is over a region that has a valid tooltip, and the tooltip
is currently visible, when the mouse moves to a region that doesn't have
a valid tooltip the tooltip will be hidden. If the mouse then moves back
into a region that has a valid tooltip within reshowDelay
milliseconds, the tooltip will immediately be shown, otherwise the
tooltip will be shown again after initialDelay milliseconds.
JComponent#createToolTip
| Modifier and Type | Class and Description |
|---|---|
| private class | |
| protected class | ToolTipManager.
Inside timer action. |
| private class | |
| protected class | ToolTipManager.
Outside timer action. |
| protected class | ToolTipManager.
Still inside timer action. |
| Modifier and Type | Field and Description |
|---|---|
| private KeyListener | |
| pack-priv boolean | |
| pack-priv Timer | |
| pack-priv Timer | |
| private FocusListener | |
| protected boolean | heavyWeightPopupEnabled
Heavyweight popup enabled. |
| private KeyStroke | |
| pack-priv JComponent | |
| pack-priv Timer | |
| protected boolean | lightWeightPopupEnabled
Lightweight popup enabled. |
| private static ToolTipManager | |
| pack-priv MouseEvent | |
| private MouseMotionListener | |
| private Rectangle | |
| private Rectangle | |
| private KeyStroke | |
| pack-priv Point | |
| pack-priv boolean | |
| pack-priv JToolTip | |
| private boolean | |
| pack-priv transient Popup | |
| pack-priv String | |
| private Window | window
The Window tip is being displayed in. This will be non-null if the Window tip is in differs from that of insideComponent's Window. |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| private void | checkForTipChange(MouseEvent event)
Checks to see if the tooltip needs to be changed in response to
the MouseMoved event |
| private FocusListener | |
| pack-priv static Frame | |
| public int | Returns: an integer representing the dismissal delay value, in millisecondsReturns the dismissal delay value. |
| private GraphicsConfiguration | |
| private int | |
| public int | Returns: an integer representing the initial delay value, in millisecondsReturns the initial delay value. |
| private int | |
| private int | |
| public int | |
| private int | |
| private void | |
| pack-priv void | |
| private void | |
| public boolean | Returns: true if this object is enabled, false otherwiseReturns true if this object is enabled. |
| public boolean | Returns: true if lightweightToolTips are in useReturns true if lightweight (all-Java) |
| public void | mouseDragged(MouseEvent
the event in question event)Overrides java. Implements java. Called when the mouse is pressed and dragged. |
| public void | mouseEntered(MouseEvent
the event in question event)Overrides java. Implements java. Called when the mouse enters the region of a component. |
| public void | mouseExited(MouseEvent
the event in question event)Overrides java. Implements java. Called when the mouse exits the region of a component. |
| public void | mouseMoved(MouseEvent
the event in question event)Overrides java. Implements java. Called when the mouse is moved. |
| public void | mousePressed(MouseEvent
the event in question event)Overrides java. Implements java. Called when the mouse is pressed. |
| public void | registerComponent(JComponent
a component)JComponent object to addRegisters a component for tooltip management. |
| public void | setDismissDelay(int
the number of milliseconds to delay
before taking away the tooltip milliseconds)Specifies the dismissal delay value. |
| public void | |
| public void | setInitialDelay(int
the number of milliseconds to delay
(after the cursor has paused) before displaying the
tooltip milliseconds)Specifies the initial delay value. |
| public void | setLightWeightPopupEnabled(boolean
true if a lightweight panel is desired, false otherwise aFlag)When displaying the |
| public void | setReshowDelay(int
time in milliseconds milliseconds)Used to specify the amount of time before the user has to wait
|
| public static ToolTipManager | |
| private void | |
| pack-priv void | |
| public void | unregisterComponent(JComponent
a component)JComponent object to removeRemoves a component from tooltip control. |
| accessibilityKeyListener | back to summary |
|---|---|
| private KeyListener accessibilityKeyListener | |
| enabled | back to summary |
|---|---|
| pack-priv boolean enabled | |
| enterTimer | back to summary |
|---|---|
| pack-priv Timer enterTimer | |
| exitTimer | back to summary |
|---|---|
| pack-priv Timer exitTimer | |
| focusChangeListener | back to summary |
|---|---|
| private FocusListener focusChangeListener | |
| heavyWeightPopupEnabled | back to summary |
|---|---|
| protected boolean heavyWeightPopupEnabled Heavyweight popup enabled. | |
| hideTip | back to summary |
|---|---|
| private KeyStroke hideTip | |
| insideComponent | back to summary |
|---|---|
| pack-priv JComponent insideComponent | |
| insideTimer | back to summary |
|---|---|
| pack-priv Timer insideTimer | |
| lightWeightPopupEnabled | back to summary |
|---|---|
| protected boolean lightWeightPopupEnabled Lightweight popup enabled. | |
| manager | back to summary |
|---|---|
| private static ToolTipManager manager | |
| mouseEvent | back to summary |
|---|---|
| pack-priv MouseEvent mouseEvent | |
| moveBeforeEnterListener | back to summary |
|---|---|
| private MouseMotionListener moveBeforeEnterListener | |
| popupFrameRect | back to summary |
|---|---|
| private Rectangle popupFrameRect | |
| popupRect | back to summary |
|---|---|
| private Rectangle popupRect | |
| postTip | back to summary |
|---|---|
| private KeyStroke postTip | |
| preferredLocation | back to summary |
|---|---|
| pack-priv Point preferredLocation | |
| showImmediately | back to summary |
|---|---|
| pack-priv boolean showImmediately | |
| tip | back to summary |
|---|---|
| pack-priv JToolTip tip | |
| tipShowing | back to summary |
|---|---|
| private boolean tipShowing | |
| tipWindow | back to summary |
|---|---|
| pack-priv transient Popup tipWindow | |
| toolTipText | back to summary |
|---|---|
| pack-priv String toolTipText | |
| window | back to summary |
|---|---|
| private Window window The Window tip is being displayed in. This will be non-null if the Window tip is in differs from that of insideComponent's Window. | |
| ToolTipManager | back to summary |
|---|---|
pack-priv ToolTipManager()
| |
| checkForTipChange | back to summary |
|---|---|
| private void checkForTipChange(MouseEvent event) Checks to see if the tooltip needs to be changed in response to
the MouseMoved event | |
| createFocusChangeListener | back to summary |
|---|---|
| private FocusListener createFocusChangeListener() | |
| frameForComponent | back to summary |
|---|---|
| pack-priv static Frame frameForComponent(Component component) | |
| getDismissDelay | back to summary |
|---|---|
| public int getDismissDelay() Returns the dismissal delay value.
| |
| getDrawingGC | back to summary |
|---|---|
| private GraphicsConfiguration getDrawingGC(Point toFind) | |
| getHeightAdjust | back to summary |
|---|---|
| private int getHeightAdjust(Rectangle a, Rectangle b) | |
| getInitialDelay | back to summary |
|---|---|
| public int getInitialDelay() Returns the initial delay value.
| |
| getPopupFitHeight | back to summary |
|---|---|
| private int getPopupFitHeight(Rectangle popupRectInScreen, Component invoker) | |
| getPopupFitWidth | back to summary |
|---|---|
| private int getPopupFitWidth(Rectangle popupRectInScreen, Component invoker) | |
| getReshowDelay | back to summary |
|---|---|
| public int getReshowDelay() Returns the reshow delay property.
| |
| getWidthAdjust | back to summary |
|---|---|
| private int getWidthAdjust(Rectangle a, Rectangle b) | |
| hide | back to summary |
|---|---|
| private void hide(JComponent source) | |
| hideTipWindow | back to summary |
|---|---|
| pack-priv void hideTipWindow() | |
| initiateToolTip | back to summary |
|---|---|
| private void initiateToolTip(MouseEvent event) | |
| isEnabled | back to summary |
|---|---|
| public boolean isEnabled() Returns true if this object is enabled.
| |
| isLightWeightPopupEnabled | back to summary |
|---|---|
| public boolean isLightWeightPopupEnabled() Returns true if lightweight (all-Java)
| |
| mouseDragged | back to summary |
|---|---|
| public void mouseDragged(MouseEvent event) Overrides java. Implements java. Called when the mouse is pressed and dragged. Does nothing.
| |
| mouseEntered | back to summary |
|---|---|
| public void mouseEntered(MouseEvent event) Overrides java. Implements java. Called when the mouse enters the region of a component. This determines whether the tool tip should be shown.
| |
| mouseExited | back to summary |
|---|---|
| public void mouseExited(MouseEvent event) Overrides java. Implements java. Called when the mouse exits the region of a component. Any tool tip showing should be hidden.
| |
| mouseMoved | back to summary |
|---|---|
| public void mouseMoved(MouseEvent event) Overrides java. Implements java. Called when the mouse is moved. Determines whether the tool tip should be displayed.
| |
| mousePressed | back to summary |
|---|---|
| public void mousePressed(MouseEvent event) Overrides java. Implements java. Called when the mouse is pressed. Any tool tip showing should be hidden.
| |
| registerComponent | back to summary |
|---|---|
| public void registerComponent(JComponent component) Registers a component for tooltip management.
This will register key bindings to show and hide the tooltip text
only if
| |
| setDismissDelay | back to summary |
|---|---|
| public void setDismissDelay(int milliseconds) Specifies the dismissal delay value.
| |
| setEnabled | back to summary |
|---|---|
| public void setEnabled(boolean flag) Enables or disables the tooltip.
| |
| setInitialDelay | back to summary |
|---|---|
| public void setInitialDelay(int milliseconds) Specifies the initial delay value.
| |
| setLightWeightPopupEnabled | back to summary |
|---|---|
| public void setLightWeightPopupEnabled(boolean aFlag) When displaying the
| |
| setReshowDelay | back to summary |
|---|---|
| public void setReshowDelay(int milliseconds) Used to specify the amount of time before the user has to wait
| |
| sharedInstance | back to summary |
|---|---|
| public static ToolTipManager sharedInstance() Returns a shared
| |
| show | back to summary |
|---|---|
| private void show(JComponent source) | |
| showTipWindow | back to summary |
|---|---|
| pack-priv void showTipWindow() | |
| unregisterComponent | back to summary |
|---|---|
| public void unregisterComponent(JComponent component) Removes a component from tooltip control.
| |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | keyPressed(KeyEvent e)
Overrides java. Implements java. Invoked when a key has been pressed. |
| public void | menuKeyPressed(MenuKeyEvent e)
Implements javax. Invoked when a key has been pressed. |
| public void | menuKeyReleased(MenuKeyEvent e)
Implements javax. Invoked when a key has been released. |
| public void | menuKeyTyped(MenuKeyEvent e)
Implements javax. Invoked when a key has been typed. |
| AccessibilityKeyListener | back to summary |
|---|---|
| private AccessibilityKeyListener() | |
| keyPressed | back to summary |
|---|---|
| public void keyPressed(KeyEvent e) Overrides java. Implements java. Doc from java. Invoked when a key has been pressed. | |
| menuKeyPressed | back to summary |
|---|---|
| public void menuKeyPressed(MenuKeyEvent e) Implements javax. Doc from javax. Invoked when a key has been pressed.
| |
| menuKeyReleased | back to summary |
|---|---|
| public void menuKeyReleased(MenuKeyEvent e) Implements javax. Doc from javax. Invoked when a key has been released.
| |
| menuKeyTyped | back to summary |
|---|---|
| public void menuKeyTyped(MenuKeyEvent e) Implements javax. Doc from javax. Invoked when a key has been typed. This event occurs when a key press is followed by a key release.
| |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public void | actionPerformed(ActionEvent e)
Implements java. Invoked when an action occurs. |
| insideTimerAction | back to summary |
|---|---|
| protected insideTimerAction() Constructs an | |
| actionPerformed | back to summary |
|---|---|
| public void actionPerformed(ActionEvent e) Implements java. Doc from java. Invoked when an action occurs. | |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public void | mouseMoved(MouseEvent e)
Overrides java. Implements java. Invoked when the mouse button has been moved on a component (with no buttons no down). |
| MoveBeforeEnterListener | back to summary |
|---|---|
| private MoveBeforeEnterListener() | |
| mouseMoved | back to summary |
|---|---|
| public void mouseMoved(MouseEvent e) Overrides java. Implements java. Doc from java. Invoked when the mouse button has been moved on a component (with no buttons no down). | |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public void | actionPerformed(ActionEvent e)
Implements java. Invoked when an action occurs. |
| outsideTimerAction | back to summary |
|---|---|
| protected outsideTimerAction() Constructs an | |
| actionPerformed | back to summary |
|---|---|
| public void actionPerformed(ActionEvent e) Implements java. Doc from java. Invoked when an action occurs. | |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public void | actionPerformed(ActionEvent e)
Implements java. Invoked when an action occurs. |
| stillInsideTimerAction | back to summary |
|---|---|
| protected stillInsideTimerAction() Constructs a | |
| actionPerformed | back to summary |
|---|---|
| public void actionPerformed(ActionEvent e) Implements java. Doc from java. Invoked when an action occurs. | |