views:

388

answers:

2

Hi, does Delphi 2010 have C# Style XML comments that show up when hovering over the method call?

/// <summary>
/// My comment here
/// </summary>
+7  A: 

I just tried it in D2007 and it works. I put your test comment above a method declaration (inside the class declaration) and rebuilt. When you now hover over a call to that method you'll see "My comment here" inside the tooltip.

You must have that HTML evaluation thingie enabled for this to work. See Options -> Editor options -> Code Insight -> Symbol description (translated fron a German IDE).

Ulrich Gerhardt
I actually deactivated this for performance reasons a while ago - Thank you!
Stefan Schultze
I normally have it disabled too. :-)
Ulrich Gerhardt
Note that, although it WORKS, I've yet to find a single piece of documentation about using this in Delphi, other than "it exists and works with our help popup" - there's nothing about which elements are supported, or even a note saying "we use what C# uses". I know CNPack adds these elements to the code completion pop-up - not sure about other plug-ins.
Michael Madsen
+1  A: 

It does work - in Delphi 2007 and 2009 there are issues with it - you have to have a type keywork before every class, or it only picks out the first set of documentation (no idea why), and if you click the 'Build XML documentation' option, it seems to get lost when compiling lots of units and gives up - I hope this is fixed in Delphi 2010.

Having said that documentation inline is better than no documentation at all!

This link to Embarcadero is about the only thing that I can find, although I think there are utilities in the Architect and Enterprise versions of Delphi to produce external documentation.

Mmarquee
+1 for the link
François