[Geany-devel] Function Definition

Colomban Wendling lists.ban at xxxxx
Fri Apr 16 18:39:59 UTC 2010

jordan a écrit :
>> As Enzo said, there is the scope to determine if a particular line is
>> part of a function or not, but its is not supported by every tag
>> generator used by Geany. What I personally chose was to walk the tag
>> list and find the tag closest to the current line. Tweaking this way a
>> bit gives quite good results.
>> And for the function definition, see the tag list, there is everything
>> you probably want (or almost). One missing thing is the argument list –
>> I personally chose to fix this with a regular expression, but there
>> might be better solutions; for example if hard-coded things are
>> acceptable, a custom argument parser is a somewhat easy task.
> How do I access the scope, or this tag list you speak of, I noticed
> nothing like that in plug-in api documentation?
See the tm_file field of GeanyDocument. I don't know exactly for the
scope, but the tag list is doc->tm_file->tags_array.

More information about the Devel mailing list