[jsword-devel] Hebrew/Greek defs as tooltips

Yingjie Lan lanyjie at yahoo.com
Thu Jan 14 03:21:00 MST 2010

> From: Tonny Kohar <tonny.kohar at gmail.com>
> Subject: Re: [jsword-devel] Hebrew/Greek defs as tooltips
> To: "J-Sword Developers Mailing List" <jsword-devel at crosswire.org>
> Date: Tuesday, January 12, 2010, 9:34 AM
> Hi,
> On Mon, Jan 11, 2010 at 8:45 PM, Yingjie Lan <lanyjie at yahoo.com>
> wrote:
> >
> > Wow, this is cool. Do you need to subclass JToolTip to
> achieve that?
> no I didn't subclass JToolTip.
> I just create a panel with scrollbar (JScrollPane) and the
> JEditorPane
> (with html renderer enabled). Then embed that panel into
> javax.swing.Popup
> eg:
> popup = PopupFactory.getSharedInstance().getPopup(owner,
> myTooltipPanel, prefPoint.x, prefPoint.y);
> popup.show();
> I choose to use jpanel because it allow much more
> customability rather
> than subclass JToolTip. With JPanel you can even put
> button, toolbar,
> etc if you need it.

Hi Tonney, thank you very much for sharing this with me, I found it really helpful in improving my implementation. I am grateful for your sound advices, why didn't I thought of popups! That gives me much more flexibility and control than tool tips. Thanks!



More information about the jsword-devel mailing list