ReSharper.EnhancedTooltip icon indicating copy to clipboard operation
ReSharper.EnhancedTooltip copied to clipboard

Enhanced code completion item tooltips

Open citizenmatt opened this issue 10 years ago • 2 comments

Would be lovely to see this in the tooltips for code completion items...

citizenmatt avatar Sep 03 '15 13:09 citizenmatt

I'd like this too. Last time I checked, there was no extensibility point available, but that was a while ago (ReSharper 8.2 probably). Will have a look again.

MrJul avatar Sep 03 '15 15:09 MrJul

So I've just had to take a look in this area for other reasons, so thought I'd add some info. I think it's possible to override the formatting of tooltips for declared elements by either adding an instance of IDeclaredElementDescriptionProvider with a higher priority than any other IDeclaredElementDescriptionProvider implementation and that always returned a value, but then it would have to take over the formatting for all declared element descriptions - CSS, JS, CLR, and HTML.

Alternatively, you could create a new IDeclaredElementDescriptionPresenter component and use IHideImplementation<DeclaredElementDescriptionPresenter>, which would also allow overriding everything, but you could then defer to the existing IDeclaredElementDescriptionProvider instances.

But, this wouldn't do anything for any lookup item that implements IDescriptionProvidingLookupItem, which is CSS and JSON, and possibly more.

And I'm not sure this covers all of the ways to display code completion tooltips, so it might not work for everything...

citizenmatt avatar Aug 05 '16 04:08 citizenmatt