Re: [scite] Adding properties for a Java like language

66 views
Skip to first unread message

Neil Hodgson

unread,
Apr 19, 2013, 9:54:20 AM4/19/13
to scite-i...@googlegroups.com
Ani:

> I am trying to add support for a java like language in SciTE.
> I am able to get some basic things working by modifying the cpp/java properties
> file. However, there is one big difference with this language, and that is :
> the identifiers can have hyphens(-) and colons(:)

The lexer for C++/Java treats hyphens and colons as operators and does not support their use inside names.

There is a good chance that none of the current lexers supports your language. You could write a new lexer, perhaps by modifying an existing one.

It is possible to write lexers in Lua for use in SciTE.
http://www.scintilla.org/ScriptLexer.html

Neil

Ani

unread,
Apr 20, 2013, 10:24:05 AM4/20/13
to scite-i...@googlegroups.com, nyama...@me.com
>   The lexer for C++/Java treats hyphens and colons as operators and does not support their use inside names. 
>   There is a good chance that none of the current lexers supports your language. You could write a new lexer, perhaps by modifying an existing one. 
>  It is possible to write lexers in Lua for use in SciTE. 
http://www.scintilla.org/ScriptLexer.html 
> Neil

Thanks Neil,
I will try the Lua lexer extension (as I have little more familiarity in Lua, than in C++ :) )
If there are some script_<language> lexer examples, I shall start by picking one
and modifying.

Neil Hodgson

unread,
Apr 21, 2013, 2:31:52 AM4/21/13
to scite-i...@googlegroups.com
Ani:

If there are some script_<language> lexer examples, I shall start by picking one
and modifying.

   There are two example lexers on the referenced page.

   Neil

Ani A

unread,
Apr 25, 2013, 6:34:54 AM4/25/13
to scite-i...@googlegroups.com
Hi Neil,

The file script_<language>.lua  (or just <language>.lua?) will reside in /usr/share/scite/, and I will also need a <language>.properties
is that correct ?

--
Regards,
A. Aniruddha


--
You received this message because you are subscribed to a topic in the Google Groups "scite-interest" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/scite-interest/AyMR8YGzX-8/unsubscribe?hl=en.
To unsubscribe from this group and all its topics, send an email to scite-interes...@googlegroups.com.
To post to this group, send email to scite-i...@googlegroups.com.
Visit this group at http://groups.google.com/group/scite-interest?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Neil Hodgson

unread,
Apr 25, 2013, 6:44:18 PM4/25/13
to scite-i...@googlegroups.com
Ani A:

The file script_<language>.lua  (or just <language>.lua?) will reside in /usr/share/scite/, and I will also need a <language>.properties
is that correct ?

   OnStyle goes into the Lua startup script or into a file that you call from that script. If you want to put properties in a separate file then go ahead. I'd put them initially in user properties and then split them out once things are working.

   Neil

Reply all
Reply to author
Forward
0 new messages