Disable Tooltip Delay In Java Swing

I am not really sure if there is a concrete way to do this. In my case, what I did was create a dirty hack to prolong a tooltip’s visible delay by making use of the ToolTipManager setDismissDelay() method.

I figure nobody would look at a tooltip for a whole 10 minutes so that it what I set as default value. By setting the setDismissDelay() method to 10 minutes of equivalent milliseconds in the component’s mouseEntered event, the tooltip will always show itself until the mouse cursor is off the component’s area when mouseExited is invoked.

As I said, it may not be the accurate way to stop the delay but it works! 😉

Related Posts Plugin for WordPress, Blogger...

1 comment

Leave a Reply

Your email address will not be published. Required fields are marked *