[Geany-devel] GProject - missing Geany patches

Colomban Wendling lists.ban at xxxxx
Sat Apr 30 21:57:49 UTC 2011

Le 28/04/2011 22:58, Jiří Techet a écrit :
> On Thu, Apr 28, 2011 at 19:46, Colomban Wendling
> <lists.ban at herbesfolles.org> wrote:
>> Le 28/04/2011 01:49, Colomban Wendling a écrit :
>>> Le 10/04/2011 15:03, Jiří Techet a écrit :
>>>> [...]
>>>> 2edb068b81cb6d541d667efecd0ec4c346f0df51 Open the file in the
>>>> msgwindow even if no linenumber is specified
>>> I'll review this one later (tomorrow if it goes right).
>> I don't really like the patch and preferred to change
>> msgwin_parse_grep_line() to something that directly parse
>> file[:line[...]] so no need to do everything twice.
> I agree it's not very nice, on the other hand I think it's the
> smallest patch that achieves what I need. Modifying
> msgwin_parse_grep_line() isn't enough, you'd have to modify
> parse_file_line() and be _very_ careful because you could screw up
> parse_compiler_error_line() which uses this function too with
> different parameters.

I wrote a different implementation, and I think it works OK. Actually I
replaced parse_grep_line() by a more generic implementation of
file[:line[...]] parsing.
If it has any flaw, just let me know :)

>> Though, why did you add a g_file_test(filename, G_FILE_EXISTS) before
>> document_open_file()? Was it not to show "unable to open file" when the
>> line don't actually contain a file or is this just a duplicate?
> Precisely, otherwise the error appears in status bar every time you
> click a message without a filename in it.

Oh yeah, otherwise everything may be a file, right. Thanks for the

>> However, again, I'm not sure why it's so important for your plugin since
>> it may easily add a line suffix, though it's a little hackish, I admit.
> Exactly. When I search for a file with the given name, then the result like
> foo_bar.c:851
> looks a little strange (I had to put the current cursor's position
> there if the file was opened, otherwise the buffer scrolled to a
> different place). So even though there's a workaround, I'd prefer to
> have it handled in geany.

Yeah true, even getting it to work properly is quiet a pain, right.
Anyway, implemented in SVN now.


More information about the Devel mailing list