[Gambas-user] Typing in - help for own function

Rolf-Werner Eilert eilert-sprachen at ...221...
Mon Nov 16 17:40:45 CET 2015


Am 16.11.2015 17:25, schrieb Tobias Boege:
> On Mon, 16 Nov 2015, Rolf-Werner Eilert wrote:
>> Just had this idea: When I type in the name of a function in one of the
>> classes of my project (an own function), the help pops up and tells me
>> about the variables needed and the data type of that function.
>>
>> But it would be helpful (e. g. after a longer time of absence) to have
>> some kind of explanation or declaration text to tell me how this
>> function was meant to be used. So, is there a way of quoting some kind
>> of comment which is then shown in this help window? Or if not, wouldn't
>> it be a nice-to-have? ;)
>>
>> I'm thinking about a special quote character, e. g. # or & in a comment,
>> or a pair of commands (forming a block) or something.
>>
> I could barely live without that. Try the double-apostrophe:
>
>    '' Analyze a line.
>    ''
>    '' **Remember that the result is ByRef.**
>    Public Function Analyze(sLine As String, hRes As AnalyzeResult) As Boolean
>      ' ...
>    End
>
> As you will see, you can use the usual Gambas Markdown syntax inside these
> comments.
>
> With the triple-apostrophe ''' in the class header you can write
> documentation for the current class.
>
> Regards,
> Tobi
>
Aaaah great! Thank you Tobi.

The space after the ' ' seems to be important, and it has to be written 
above the function declaration, not within, right?

Regards
Rolf





More information about the User mailing list