HELP: how do I show a declaration tooltip

Milian Wolff mail at milianw.de
Mon Aug 31 18:47:50 UTC 2009


David Nolden, 31.08.2009:
> Am Donnerstag 27 August 2009 18:41:47 schrieb Milian Wolff:
> > What is the preferred way to show a declaration tooltip?
> >
> > I put my hopes on DUChain::self()->emitDeclarationSelected() but the
> > contextbrowser requires views and does a lot stuff internally...
> >
> > Essentially I just want to create a tooltip a bit below the cursor
> > position. Actually I want to fix
> > https://bugs.kde.org/show_bug.cgi?id=189966 , i.e. show the tooltip when
> > a user hovers an entry which resembles a declaration in the classbrowser.
> >
> > You find my current approach attached, but sadly it doesn't show
> > anything :( The signals and such stuff is properly delegated so I think
> > something in the contextbrowser is messing up... Isn't there a simpler
> > way to show the tooltip?
>
> emitDeclarationSelected does not trigger the tooltip to be shown, it just
> causes the declaration to be use-highlighted, shown in the context-browser,
> and hopefully also in the code-flow view soon.
>
> Showing a tooltip is slightly more complicated right now, see
> ContextBrowserPlugin::showToolTip for example. We should move some of that
> code into a central location, as it already is replicated in a few other
> places.

Some questions so I can hack on that eventually:

a) Where should I put the code?
b) Where is it already replicated?
-- 
Milian Wolff
mail at milianw.de
http://milianw.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20090831/77423dbb/attachment.sig>


More information about the KDevelop-devel mailing list