Is it possible to make it so that the tooltip displayed will change when over certain keywords inside of some swing object? The content will be completely defined by the code so I could use text positioning if that would help. Thanks
Edit:
Okay, specifically what I would be doing is creating a custom display box for text to use as a combat log. This will be overtop my animations, a hud if you will. What I am thinking, is that I can use a tooltip to display the attributes behind combat calculations, while de-cluttering the log for people who know how things work already.
Override
getToolTipText(...)
. Simple example:With a text component you would need to use the mouse point and the getViewToModel() method to get the text from the Document.