Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## javax.swing
Class ToolTipManager

    java.lang.Object
      |
      +--java.awt.event.MouseAdapter
            |
            +--javax.swing.ToolTipManager

public class ToolTipManager
extends java.awt.event.MouseAdapter
implements java.awt.event.MouseMotionListener

Manages all the ToolTips in the system.

See Also:
  `JComponent.createToolTip()`

Inner Class Summary
`protected class` | `ToolTipManager.insideTimerAction`
`protected class` | `ToolTipManager.outsideTimerAction`
`protected class` | `ToolTipManager.stillInsideTimerAction`

Field Summary
`protected boolean` | `heavyWeightPopupEnabled`
`protected boolean` | `lightWeightPopupEnabled`

Method Summary
`int` | `getDismissDelay()` Returns the dismisal delay value.
`int` | `getInitialDelay()` Returns the initial delay value.
`int` | `getReshowDelay()` Returns the reshow delay value.
`boolean` | `isEnabled()` Returns true if this object is enabled.
`boolean` | `isLightWeightPopupEnabled()` Returns true if lightweight (all-Java) Tooltips are in use, or false if heavyweight (native peer) Tooltips are being used.
`void` | `mouseDragged(java.awt.event.MouseEvent event)`
`void` | `mouseEntered(java.awt.event.MouseEvent event)`
`void` | `mouseExited(java.awt.event.MouseEvent event)`
`void` | `mouseMoved(java.awt.event.MouseEvent event)`
`void` | `mousePressed(java.awt.event.MouseEvent event)`
`void` | `registerComponent(JComponent component)` Register a component for tooltip management.
`void` | `setDismissDelay(int microSeconds)` Specifies the dismisal delay value.
`void` | `setEnabled(boolean flag)` Enables or disables the tooltip.
`void` | `setInitialDelay(int microSeconds)` Specifies the initial delay value.
`void` | `setLightWeightPopupEnabled(boolean aFlag)` Deprecated. As of Swing1.1 replaced by `setToolTipWindowUsePolicy(int)`.
`void` | `setReshowDelay(int microSeconds)` Specifies the time to delay before reshowing the tooltip.
`static ToolTipManager` | `sharedInstance()` Returns a shared ToolTipManager instance.
`void` | `unregisterComponent(JComponent component)` Remove a component from tooltip control.

Methods inherited from class java.awt.event.MouseAdapter
`mouseClicked, mouseReleased`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### lightWeightPopupEnabled

    protected boolean lightWeightPopupEnabled

### heavyWeightPopupEnabled

    protected boolean heavyWeightPopupEnabled

Method Detail

### setEnabled

    public void setEnabled(boolean flag)

  Enables or disables the tooltip.
  Parameters:
    `flag` - true to enable the tip

### isEnabled

    public boolean isEnabled()

  Returns true if this object is enabled.
  Returns:
    true if this object is enabled

### setLightWeightPopupEnabled

    public void setLightWeightPopupEnabled(boolean aFlag)

  Deprecated. As of Swing1.1 replaced by `setToolTipWindowUsePolicy(int)`.
  When displaying the JToolTip, the ToolTipManager choose to use a light weight JPanel if it fits. This method allows you to disable this feature. You have to do disable it if your application mixes light weight and heavy weights components.

### isLightWeightPopupEnabled

    public boolean isLightWeightPopupEnabled()

  Returns true if lightweight (all-Java) Tooltips are in use, or false if heavyweight (native peer) Tooltips are being used.
  Returns:
    true if lightweight ToolTips are in use

### setInitialDelay

    public void setInitialDelay(int microSeconds)

  Specifies the initial delay value.
  Parameters:
    `microSeconds` - an int specifying the number of microseconds to delay (after the cursor has paused) before displaying the tooltip
  See Also:
    `getInitialDelay()`

### getInitialDelay

    public int getInitialDelay()

  Returns the initial delay value.
  Returns:
    an int representing the initial delay value
  See Also:
    `setInitialDelay(int)`

### setDismissDelay

    public void setDismissDelay(int microSeconds)

  Specifies the dismisal delay value.
  Parameters:
    `microSeconds` - an int specifying the number of microseconds to delay (after the cursor has moved on) before taking away the tooltip
  See Also:
    `getDismissDelay()`

### getDismissDelay

    public int getDismissDelay()

  Returns the dismisal delay value.
  Returns:
    an int representing the dismisal delay value
  See Also:
    `setDismissDelay(int)`

### setReshowDelay

    public void setReshowDelay(int microSeconds)

  Specifies the time to delay before reshowing the tooltip.
  Parameters:
    `microSeconds` - an int specifying the time in microseconds before reshowing the tooltip if the cursor stops again
  See Also:
    `getReshowDelay()`

### getReshowDelay

    public int getReshowDelay()

  Returns the reshow delay value.
  Returns:
    an int representing the reshow delay value
  See Also:
    `setReshowDelay(int)`

### sharedInstance

    public static ToolTipManager sharedInstance()

  Returns a shared ToolTipManager instance.
  Returns:
    a shared ToolTipManager object

### registerComponent

    public void registerComponent(JComponent component)

  Register a component for tooltip management.
  Parameters:
    `component` - a JComponent object

### unregisterComponent

    public void unregisterComponent(JComponent component)

  Remove a component from tooltip control.
  Parameters:
    `component` - a JComponent object

### mouseEntered

    public void mouseEntered(java.awt.event.MouseEvent event)

  Overrides:
    mouseEntered in class java.awt.event.MouseAdapter

### mouseExited

    public void mouseExited(java.awt.event.MouseEvent event)

  Overrides:
    mouseExited in class java.awt.event.MouseAdapter

### mousePressed

    public void mousePressed(java.awt.event.MouseEvent event)

  Overrides:
    mousePressed in class java.awt.event.MouseAdapter

### mouseDragged

    public void mouseDragged(java.awt.event.MouseEvent event)

  Specified by:
    mouseDragged in interface java.awt.event.MouseMotionListener

### mouseMoved

    public void mouseMoved(java.awt.event.MouseEvent event)

  Specified by:
    mouseMoved in interface java.awt.event.MouseMotionListener

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1998 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.