[Geany-devel] geany vim syntax reader

Enrico Tröger enrico.troeger at xxxxx
Thu May 7 20:09:12 UTC 2009

On Thu, 7 May 2009 00:31:31 +0200, Frank wrote:

>On Tue, 5 May 2009 09:24:13 -0400
>Charles Bevan <cfbevan at gmail.com> wrote:
>> I was thinking of making a vim syntax reader as a plugin. It would be
>> nice to start out small by only implementing the adapter that would
>> read the vim file and translate it to set the appropriate formatting
>> on the currently active document only. If the plugin goes well and is

Sounds cool so far. This way the plugin could be some kind of testbed
for getting some working code and step by sep improvements.

>> used often, it may be possible to implement it in the main project
>> and allow the vim reader to act like a built in language.

Yes or maybe use it directly. The current highlighting code is far from
optimal and needs some improvements at some point, e.g. to support
common default highlighting styles to define pseudo styles which are
equal or similar in many filetypes. And when doing this, your code
could be integrated or even replace the current code. But this needs
way more discussing before :).

>Enrico or Nick may correct me but I think such a plugin would need deep
>access to Scintilla's functions and other stuff. Since I don't know the

Probably not. The four Scintilla messages: SCI_STYLESETFORE,
(as found in set_sci_style() in src/highlighting.c) should be enough
for a start.

>syntax of the mentioned vim files very well, wouldn't it be possible to
>just write a small tool (maybe a sh script) which is converting the
>file to Geany's format here and provide it in 'normal' way to Geany?

That would be probably easier with the drawback that changing the vim
scheme source file would require a new conversion into Geany's format.


P.S.: I added you to the geany-plugins project at Sourceforge, so you
can start committing any code you have :).

Get my GPG key from http://www.uvena.de/pub.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: not available
URL: <http://lists.geany.org/pipermail/devel/attachments/20090507/000fac75/attachment.pgp>

More information about the Devel mailing list