Hello myself Sujeet studying B.tech CSE at IIITD and looking to contribute to geany. I have knowledge of c,java,html and css.
Are you interested in writing a lexer / folder (for the TWiki markup language and some variations)?
On Friday, December 11, 2015 01:21:44 PM you wrote:
Hello myself Sujeet studying B.tech CSE at IIITD and looking to contribute to geany. I have knowledge of c,java,html and css.
Hello Rhkramer, Yes i am interested. Can you share more details. On Dec 12, 2015 5:10 AM, rhkramer@gmail.com wrote:
Are you interested in writing a lexer / folder (for the TWiki markup language and some variations)?
On Friday, December 11, 2015 01:21:44 PM you wrote:
Hello myself Sujeet studying B.tech CSE at IIITD and looking to
contribute
to geany. I have knowledge of c,java,html and css.
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
Sujeet,
(Shall I call you Sujeet?)
Yes, I can supply more details, and we can take this off list if either you or others on the list prefer.
I need to spend some time getting my head screwed on straight again as far as the syntax and so forth go.
Just a little preliminary information:
* A lexer / folder would actually be an addition to the Scintilla project, which is what the Geany project uses for--well, I guess I'd call it the main editing and display widget.
* IIRC, there are at least three ways to write a lexer / folder for Scintilla, one is as a native C/C++ module, one is in LUA, and I think there is a third way. I'd prefer to see it done as a native C/C++ module because I assume (I know) that would execute faster.
There are two "styles" which have been used, one is as a C subroutine and the other is as a C++ object. (My terminology probably isn't exactly correct.) I would prefer that the C++ object approach be used, as that is the more modern and I sort of hope it might also be faster (but I suspect it is not).
* One of the main variations to the basic TWiki Markup language that I need to handle is that I allow multiple TWiki records to exist in the same file, You could consider the file to be basically an mbox email file with TWiki records delimited by mbox From header, but with some restrictions placed on it.
I'd like the lexing of the From header to be sufficient to confirm that the header is valid, at least in the applications I use.
If I haven't yet scared you off, I'll go into more detail in my next email.
Randy Kramer
On Friday, December 11, 2015 11:33:24 PM you wrote:
Hello Rhkramer, Yes i am interested. Can you share more details.
On Dec 12, 2015 5:10 AM, rhkramer@gmail.com wrote:
Are you interested in writing a lexer / folder (for the TWiki markup language and some variations)?
On Friday, December 11, 2015 01:21:44 PM you wrote:
Hello myself Sujeet studying B.tech CSE at IIITD and looking to
contribute
to geany. I have knowledge of c,java,html and css.
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
On 13 December 2015 at 11:47, rhkramer@gmail.com wrote:
Sujeet,
(Shall I call you Sujeet?)
Yes, I can supply more details, and we can take this off list if either you or others on the list prefer.
You should always keep discussion on-list, that way you have less risk of proudly announcing your new feature only to be told you have wasted your time and you should have done it another way. Keeping it on-list means you are more likely to find out early before you do too much effort. :)
I need to spend some time getting my head screwed on straight again as far as the syntax and so forth go.
Just a little preliminary information:
- A lexer / folder would actually be an addition to the Scintilla project,
which is what the Geany project uses for--well, I guess I'd call it the main editing and display widget.
Correct, its better to submit new lexers there.
- IIRC, there are at least three ways to write a lexer / folder for
Scintilla, one is as a native C/C++ module, one is in LUA, and I think there is a third way. I'd prefer to see it done as a native C/C++ module because I assume (I know) that would execute faster.
Geany only supports C++ lexers, lua ones are a Scite feature AFAIK.
There are two "styles" which have been used, one is as a C subroutine and the other is as a C++ object. (My terminology probably isn't exactly correct.) I would prefer that the C++ object approach be used, as that is the more modern and I sort of hope it might also be faster (but I suspect it is not).
The speed difference is probably immaterial, what you need is a clear easily maintained implementation for submission to Scintilla, so making it similar to other lexers is the way to go.
- One of the main variations to the basic TWiki Markup language that I need
to handle is that I allow multiple TWiki records to exist in the same file, You could consider the file to be basically an mbox email file with TWiki records delimited by mbox From header, but with some restrictions placed on it.
I'd like the lexing of the From header to be sufficient to confirm that the header is valid, at least in the applications I use.
Scintilla lexers do not do syntax or semantic checking, they are for highlighting only and should be tolerant of erroneous code, since it will exist whilst you are typing. You would need to put the checking code elsewhere, in a plugin maybe.
If I haven't yet scared you off, I'll go into more detail in my next email.
Randy Kramer
On Friday, December 11, 2015 11:33:24 PM you wrote:
Hello Rhkramer, Yes i am interested. Can you share more details.
On Dec 12, 2015 5:10 AM, rhkramer@gmail.com wrote:
Are you interested in writing a lexer / folder (for the TWiki markup language and some variations)?
On Friday, December 11, 2015 01:21:44 PM you wrote:
Hello myself Sujeet studying B.tech CSE at IIITD and looking to
contribute
to geany. I have knowledge of c,java,html and css.
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
Thanks for the response--I'm deleting a lot of the older stuff to focus just on the newer stuff.
On Saturday, December 12, 2015 09:21:52 PM you wrote:
You should always keep discussion on-list, that way you have less risk of proudly announcing your new feature only to be told you have wasted your time and you should have done it another way. Keeping it on-list means you are more likely to find out early before you do too much effort. :)
I agree.
Correct, its better to submit new lexers there.
Yes, in the end, it will be submitted there. Should I infer that you prefer to see the development and discussion moved to one of its lists?
Geany only supports C++ lexers, lua ones are a Scite feature AFAIK.
So that eliminates the usability of a Lua lexer, which is mostly a good thing, but another issue may come up--I'll mention it below.
The speed difference is probably immaterial, what you need is a clear easily maintained implementation for submission to Scintilla, so making it similar to other lexers is the way to go.
Originally, the lexers were written in C. As Scintilla has evolved into C++, some, but I don't think yet all of the old lexers have evolved to C++, and, my understanding is that C++ is the preferred approach.
- One of the main variations to the basic TWiki Markup language that I
need
to handle is that I allow multiple TWiki records to exist in the same file, You could consider the file to be basically an mbox email file with TWiki records delimited by mbox From header, but with some
------------------------------------------------------^the
restrictions placed on it.
I'd like the lexing of the From header to be sufficient to confirm that the header is valid, at least in the applications I use.
Scintilla lexers do not do syntax or semantic checking, they are for highlighting only and should be tolerant of erroneous code, since it will exist whilst you are typing. You would need to put the checking code elsewhere, in a plugin maybe.
In the lexers / folders / syntax highlighters I've developed for other editors (Kate and Nedit (with a pseudo-folding feature), I incorporated enough checking into them that they can confirm the syntax to a sufficient degree that it works in the other applications that I used the files in (currently kmail and nmail).
I hope to get the same accomplished for the Scintilla based editors. I was considering a possible fallback (or a simplified initial approach) of having a pretty simple check with the lexer / folder (the beginning of each record is the top level folding point) and then having something like a Lua "macro" perform a more detailed check on demand. I don't know / remember if Scintilla has another macro language or something like that could be called on demand.
Never-the-less, my goal is to eventually have the highlighter check in enough detail to be sure the From header works in kmail, nmail, and in the syntax highlighter I've written for kate. (The nedit syntax highlighter I wrote is for an older version of my "system" and the data files are not directly compatible with the Kate version, and I do not expect them to be compatible with the Scintilla version.)
If I hear a positive response from Sujeet (that is, that he is still interested, in the next email I'll detail what I need to have a valid From header.
Randy Kramer
...
Correct, its better to submit new lexers there.
Yes, in the end, it will be submitted there. Should I infer that you prefer to see the development and discussion moved to one of its lists?
Up to you, but you are going to want to ask questions of the Scintilla maintainer (see below) so probably best.
The speed difference is probably immaterial, what you need is a clear easily maintained implementation for submission to Scintilla, so making it similar to other lexers is the way to go.
Originally, the lexers were written in C. As Scintilla has evolved into C++, some, but I don't think yet all of the old lexers have evolved to C++, and, my understanding is that C++ is the preferred approach.
Check with Neil, there are lexers maintained by him in both forms.
- One of the main variations to the basic TWiki Markup language that I
need
to handle is that I allow multiple TWiki records to exist in the same file, You could consider the file to be basically an mbox email file with TWiki records delimited by mbox From header, but with some
------------------------------------------------------^the
restrictions placed on it.
I'd like the lexing of the From header to be sufficient to confirm that the header is valid, at least in the applications I use.
Scintilla lexers do not do syntax or semantic checking, they are for highlighting only and should be tolerant of erroneous code, since it will exist whilst you are typing. You would need to put the checking code elsewhere, in a plugin maybe.
In the lexers / folders / syntax highlighters I've developed for other editors (Kate and Nedit (with a pseudo-folding feature), I incorporated enough checking into them that they can confirm the syntax to a sufficient degree that it works in the other applications that I used the files in (currently kmail and nmail).
Well I guess you can set a specific style for syntax that you don't like, the way C files show a specific style for unclosed strings, but note they only do that if the cursor moves off the line to avoid being too annoying.
I hope to get the same accomplished for the Scintilla based editors. I was considering a possible fallback (or a simplified initial approach) of having a pretty simple check with the lexer / folder (the beginning of each record is the top level folding point) and then having something like a Lua "macro" perform a more detailed check on demand. I don't know / remember if Scintilla has another macro language or something like that could be called on demand.
No.
Never-the-less, my goal is to eventually have the highlighter check in enough detail to be sure the From header works in kmail, nmail, and in the syntax highlighter I've written for kate. (The nedit syntax highlighter I wrote is for an older version of my "system" and the data files are not directly compatible with the Kate version, and I do not expect them to be compatible with the Scintilla version.)
If I hear a positive response from Sujeet (that is, that he is still interested, in the next email I'll detail what I need to have a valid From header.
Perhaps you should both consider asking on the Scintilla list first before going too far.
Also there hasn't been a great clamour of interest for a mail file editor, so it isn't guaranteed to be included.
Randy Kramer
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
Thanks for the response.
Again, deleted a lot of stuff that is old or doesn't need a reply.
On Sunday, December 13, 2015 09:23:54 AM you wrote:
Also there hasn't been a great clamour of interest for a mail file editor, so it isn't guaranteed to be included.
I assumed, but I guess I should ask.
If I had a Scintilla lexer, even if it is not distributed with Scite, iirc, it is fairly easy to add / activate it for my own use. I guess I assumed I could to the same for any Scintilla based editor (like Geany)?
Randy Kramer
PS: If I see something else I should have responded to, I'll post again, otherwise you can assume I'm in agreement.
On 12/13/2015 06:47 AM, rhkramer@gmail.com wrote:
If I had a Scintilla lexer, even if it is not distributed with Scite, iirc, it is fairly easy to add / activate it for my own use. I guess I assumed I could to the same for any Scintilla based editor (like Geany)?
If you get those guys interested let me know. I was trying to get them to fix up some highlighting errors in zsh but they were basically not interested. I'd do it myself if I knew how, but I have no idea where to start.
On 14 December 2015 at 02:50, Ray Andrews rayandrews@eastlink.ca wrote:
On 12/13/2015 06:47 AM, rhkramer@gmail.com wrote:
If I had a Scintilla lexer, even if it is not distributed with Scite, iirc, it is fairly easy to add / activate it for my own use. I guess I assumed I could to the same for any Scintilla based editor (like Geany)?
If you get those guys interested let me know. I was trying to get them to fix up some highlighting errors in zsh but they were basically not interested. I'd do it myself if I knew how, but I have no idea where to start.
Scintilla is a project maintained by one person in their own time. Like all open source projects, he will accept well written additions or changes contributed by others, but he is unable to perform significant maintenance on all the contributed lexers by himself, due to time and the detailed knowledge of the language needed. He is usually good about stating that he won't be able to work on it himself.
For contributed lexers the individual maintainers may help if they have time and knowledge of what is to be changed (and this was the problem with the zsh changes, nobody could define them), although some of the maintainers have also disappeared and no longer contribute.
So for changes to Scintilla, yes it is usually necessary to do it yourself, and if its done well it is probably likely to be accepted, despite Neils occasionally voiced concerns about long term maintainability and utility of all those lexers.
Cheers Lex
Users mailing list Users@lists.geany.org https://lists.geany.org/cgi-bin/mailman/listinfo/users
On 12/13/2015 02:45 PM, Lex Trotman wrote:
Scintilla is a project maintained by one person in their own time.
Just one guy? I subscribed to their list, and there seemed to be several people involved.
Like all open source projects, he will accept well written additions or changes contributed by others, but he is unable to perform significant maintenance on all the contributed lexers by himself, due to time and the detailed knowledge of the language needed. He is usually good about stating that he won't be able to work on it himself. For contributed lexers the individual maintainers may help if they have time and knowledge of what is to be changed (and this was the problem with the zsh changes, nobody could define them), although some of the maintainers have also disappeared and no longer contribute. So for changes to Scintilla, yes it is usually necessary to do it yourself, and if its done well it is probably likely to be accepted, despite Neils occasionally voiced concerns about long term maintainability and utility of all those lexers. Cheers Lex
Well, if I knew where to start I'd certainly be willing. As I said to them, a 99% accuracy should be easy even if there is some obscure exception and 100% should be achievable with work. One of the people on their list said he might look into it over the holidays, and that's where it lies at the moment.
On 2015-12-13 3:47 PM, Ray Andrews wrote:
On 12/13/2015 02:45 PM, Lex Trotman wrote:
Scintilla is a project maintained by one person in their own time.
Just one guy? I subscribed to their list, and there seemed to be several people involved.
One guy that makes commits (usually). Most of the lexers were contributed and maintained by other people, but all changes usually go through Neil.
Like all open source projects, he will accept well written additions or changes contributed by others, but he is unable to perform significant maintenance on all the contributed lexers by himself, due to time and the detailed knowledge of the language needed. He is usually good about stating that he won't be able to work on it himself. For contributed lexers the individual maintainers may help if they have time and knowledge of what is to be changed (and this was the problem with the zsh changes, nobody could define them), although some of the maintainers have also disappeared and no longer contribute. So for changes to Scintilla, yes it is usually necessary to do it yourself, and if its done well it is probably likely to be accepted, despite Neils occasionally voiced concerns about long term maintainability and utility of all those lexers. Cheers Lex
Well, if I knew where to start I'd certainly be willing. As I said to them, a 99% accuracy should be easy even if there is some obscure exception and 100% should be achievable with work. One of the people on their list said he might look into it over the holidays, and that's where it lies at the moment.
"where to start" is a bit vague, but reading the source code is a pretty good starting point[0]:
http://sourceforge.net/p/scintilla/code/ci/default/tree/lexers/LexBash.cxx
You can also ask specific questions on scintilla-interest mailing list or even on Geany's development mailing list.
Cheers, Matthew Brush
[0]: assuming you know C++, otherwise a good starting point would be learning C++ :)
On 2015-12-13 3:55 PM, Matthew Brush wrote:
On 2015-12-13 3:47 PM, Ray Andrews wrote:
On 12/13/2015 02:45 PM, Lex Trotman wrote:
Scintilla is a project maintained by one person in their own time.
Just one guy? I subscribed to their list, and there seemed to be several people involved.
One guy that makes commits (usually). Most of the lexers were contributed and maintained by other people, but all changes usually go through Neil.
Like all open source projects, he will accept well written additions or changes contributed by others, but he is unable to perform significant maintenance on all the contributed lexers by himself, due to time and the detailed knowledge of the language needed. He is usually good about stating that he won't be able to work on it himself. For contributed lexers the individual maintainers may help if they have time and knowledge of what is to be changed (and this was the problem with the zsh changes, nobody could define them), although some of the maintainers have also disappeared and no longer contribute. So for changes to Scintilla, yes it is usually necessary to do it yourself, and if its done well it is probably likely to be accepted, despite Neils occasionally voiced concerns about long term maintainability and utility of all those lexers. Cheers Lex
Well, if I knew where to start I'd certainly be willing. As I said to them, a 99% accuracy should be easy even if there is some obscure exception and 100% should be achievable with work. One of the people on their list said he might look into it over the holidays, and that's where it lies at the moment.
"where to start" is a bit vague, but reading the source code is a pretty good starting point[0]:
http://sourceforge.net/p/scintilla/code/ci/default/tree/lexers/LexBash.cxx
And of course the documentation, which among other useful details, contains some easy to miss links at the top which explain how lexers work:
http://www.scintilla.org/ScintillaDoc.html
I found the "Beginner's Guide to lexing and folding" one quite good.
Cheers, Matthew Brush
On 12/13/2015 04:02 PM, Matthew Brush wrote:
"where to start" is a bit vague, but reading the source code is a pretty good starting point[0]:
http://sourceforge.net/p/scintilla/code/ci/default/tree/lexers/LexBash.cxx
And of course the documentation, which among other useful details, contains some easy to miss links at the top which explain how lexers work:
http://www.scintilla.org/ScintillaDoc.html
I found the "Beginner's Guide to lexing and folding" one quite good.
Cheers, Matthew Brush
Ok, noted and filed. Too bad about the C++ tho. I'm proficient in C but I rather loathe C++. But I did speak it at one time and we can't stop 'progress' ....
On 2015-12-13 4:18 PM, Ray Andrews wrote:
On 12/13/2015 04:02 PM, Matthew Brush wrote:
"where to start" is a bit vague, but reading the source code is a pretty good starting point[0]:
http://sourceforge.net/p/scintilla/code/ci/default/tree/lexers/LexBash.cxx
And of course the documentation, which among other useful details, contains some easy to miss links at the top which explain how lexers work:
http://www.scintilla.org/ScintillaDoc.html
I found the "Beginner's Guide to lexing and folding" one quite good.
Cheers, Matthew Brush
Ok, noted and filed. Too bad about the C++ tho. I'm proficient in C but I rather loathe C++. But I did speak it at one time and we can't stop 'progress' ....
If it helps, it's not very "C++-ish", it's more like "C With Classes".
Cheers, Matthew Brush
On 2015-12-11 10:21 AM, Sujeet IIITD wrote:
Hello myself Sujeet studying B.tech CSE at IIITD and looking to contribute to geany. I have knowledge of c,java,html and css.
Welcome Sujeet. Please feel free to post any questions or ideas for stuff you would like to work on to the development mailing list.
Cheers, Matthew Brush