[Geany-Devel] Find/highlight matching opening/closing

Volodymyr Kononenko vmkononenko at xxxxx
Thu Mar 28 10:10:05 UTC 2013


I am sorry if this message will not jump into necessary thread. I'm
replying to digest message in Gmail and setting appropriate subject.

> A little googling showed me, that this feature is in Geany wishlist. So, I
> > wish to implement it.
> > After the brief investigation I've found, that it may be implemented in
> > on_update_ui (src/editor.c) by checking active lexer, and if it is HTML,
> > then calling editor_highlight_html_tag function (or something like this).
>
> You should do language specific stuff in a plugin, you can connect to
> the editor-notify signal.  Just ensure you return false.
>
> >
> > Is it OK to implement on the editor level, or you think it would be
> correct
> > to implement on the Scintilla lexer level (LexHTML.cxx)? Please, suggest.
>
> I assume you want to make it work like brace matching, when the cursor
> is in/next to a tag highlight the opposing tag.
>


Exactly.


> It is probably not possible to implement in the lexer as it won't be
> called for changes to the cursor position.
>

Ok, I will implement it as a plugin. Thank you for the tips!

-- 
Best regards,
Volodymyr Kononenko
http://kononenko.ws
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.geany.org/pipermail/devel/attachments/20130328/2e992840/attachment.html>


More information about the Devel mailing list