Class ToolTipInfo
- java.lang.Object
-
- org.fife.ui.rsyntaxtextarea.parser.ToolTipInfo
-
public class ToolTipInfo extends Object
Wrapper for a tool tip and a listener for hyperlink events in the tool tip (assuming the tip is HTML). If theRSyntaxTextAreainstance hasFocusableTips enabled, and the user clicks on a hyperlink in the tool tip, the specifiedHyperlinkListenerwill be called.
-
-
Constructor Summary
Constructors Constructor Description ToolTipInfo(String text, HyperlinkListener listener)Constructor.ToolTipInfo(String text, HyperlinkListener l, URL imageBase)Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description HyperlinkListenergetHyperlinkListener()Returns the listener to call when hyperlinks are clicked in the tool tip.URLgetImageBase()Returns the base URL that any images in the HTML tool tip live in.StringgetToolTipText()Returns the tool tip text to display.
-
-
-
Constructor Detail
-
ToolTipInfo
public ToolTipInfo(String text, HyperlinkListener listener)
Constructor.- Parameters:
text- The tool tip text, ornullfor none.listener- The hyperlink listener, ornullfor none.
-
ToolTipInfo
public ToolTipInfo(String text, HyperlinkListener l, URL imageBase)
Constructor.- Parameters:
text- The tool tip text, ornullfor none.l- The hyperlink listener, ornullfor none.imageBase- The base URL for images in the HTMLtext, ornullfor the default.
-
-
Method Detail
-
getHyperlinkListener
public HyperlinkListener getHyperlinkListener()
Returns the listener to call when hyperlinks are clicked in the tool tip.- Returns:
- The listener, or
nullfor none.
-
getImageBase
public URL getImageBase()
Returns the base URL that any images in the HTML tool tip live in. This allows you to reference images in a jar file in yourFocusableTips. Note that if whatgetToolTipText()returns isn't HTML, this value is effectively ignored.- Returns:
- The image base, or
nullfor the default.
-
getToolTipText
public String getToolTipText()
Returns the tool tip text to display.- Returns:
- The tool tip text, or
nullfor none.
-
-