newlisp.vom and .vimrc

Notices and updates
Locked
Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

newlisp.vom and .vimrc

Post by Lutz »

added parenthesis coloring and re-did .vimrc to match new newlisp.vim from Cyril.

http://newlisp.org/code/newlisp.vim.txt

http://newlisp.org/code/vimrc.txt

Lutz

ps: the only missing part for complete compatibility with the newLISP GS editor would be a special color for quoted symbols (don't know how to do this :-( , perhaps Cyril knows ;-) )

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

Unfortunately the parenthesis coloring ruins Cyril's error coloring for unmatched parenthesis, needs help!

Lutz

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

Post by Cyril »

Lutz wrote:Unfortunately the parenthesis coloring ruins Cyril's error coloring for unmatched parenthesis, needs help!
Fixed. Version 1.2 uploaded to it's usual place. It is not the version 1.2 I've not promised to do in other tread, that one is underway (will be 1.3)! I have also uploaded it at the Vim site as script #2067.

BTW, in your patch you have linked newlispParenthesis group to Parenthesis group, but there is no standard Parenthesis group in Vim! At least, there is no such group in Vim version 7.1.130 which I am using. So I have not seen any changes in highlighting. In my version 1.2 I have linked parentheses to standard Delimiter group instead. If you have the Parentheses group in you Vim, then probably it is better to re-link it in your .vimrc, not in plugin distributed. Use hi link newlispParenthesis Parenthesis (note the absence of def -- the very intent of def(ault) is to allow overriding it in .vimrc).
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.3

Post by Cyril »

Definitely I am blessed by Gods tonight! Version 1.3 is ready and uploaded to my page and to the Vim site. Now it highlights documentation keywords (like @author) and HTML markup in comments. It doesn't although validate HTML -- it is newLISP syntax file, after all. ;-)

You can look at rather random examples here.
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.4

Post by Cyril »

Call me crazy, but I have done version 1.4! Now it understands real newlispdoc syntax in comments, not just a rough approximation as 1.3 did. Addresses of file itself and examples see in my previous message.

The only pitfall is that I am not sure whether it still works with Vim 6.x versions. I do my development with 7.1 and I have used some rather advanced features of Vim, and I do not remember in which Vim version they have been introduced.
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.5

Post by Cyril »

Show must go on? It does! Version 1.5 released. By popular demand (where "popular" means "of Lutz" ;-), quoted symbols are highlighted now.

BTW, do you know that Russian language has a special word for "one and a half"?
With newLISP you can grow your lists from the right side!

cormullion
Posts: 2038
Joined: Tue Nov 29, 2005 8:28 pm
Location: latiitude 50N longitude 3W
Contact:

Re: version 1.5

Post by cormullion »

Cyril wrote:BTW, do you know that Russian language has a special word for "one and a half"?
;-) No. But there's one in latin, too, isn't there - sesqui.

Lutz
Posts: 5289
Joined: Thu Sep 26, 2002 4:45 pm
Location: Pasadena, California
Contact:

Post by Lutz »

Cyril wrote:... it understands real newlispdoc syntax ... quoted symbols are highlighted now ...
simply amazing :), thanks

Lutz

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.6

Post by Cyril »

Version 1.6 is released. No new functionality, a bugfix only. A nasty bug (two nasty bugs really) was triggered when switching syntax off and back on or when changing colorscheme. If you are always using default colorscheme (or some other, but always the same) and never turn highlighting off and on, you are not affected. Now you can safely play with colors in the quest for the end of rainbow! ;-)
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.7

Post by Cyril »

Another bugfix version. Keyword @example was processed incorrectly (the script was erroneously supposed that it has the same one-line syntax as @module, @author etc.). I have found this when really tried to write some docs to some my code.
With newLISP you can grow your lists from the right side!

rickyboy
Posts: 607
Joined: Fri Apr 08, 2005 7:13 pm
Location: Front Royal, Virginia

Re: version 1.5

Post by rickyboy »

cormullion wrote:
Cyril wrote:BTW, do you know that Russian language has a special word for "one and a half"?
;-) No. But there's one in latin, too, isn't there - sesqui.
The Russian is полтора. And there's one word in Greek for it too: εναμισι. :-)
(λx. x x) (λx. x x)

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.8

Post by Cyril »

Another bugfix version. In previous versions, if you written two 'monospace' items in one line of documentation, the text between them was treated as monospace too. The similar with <italic>.
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.9

Post by Cyril »

After the three bug-fixing versions at least a feature-starring one! This version marks as an error non top-level expressions started in the first column. Why? Most sane programmers used some or another form of indentation, and the nested expressions have a very little chance to touch the left side of the screen. The only reason of such an event is that lisp considers the expression being nested, but you, the programmer, being top-level. This can happen (and regularly does happen) with me if I forgot some right parentheses in previous expression. So the idea is: if you are finished to type a function definition, and start a new function with first column, and Vim highlights the first opening parenthesis as an error -- check for unclosed parentheses in the previous definition.

If you like to start nested lists with the first column (maybe for a reason), then stay with version 1.8 -- or wait for 1.10. I am planning to make all error marks disable-able (each kind of error individually). But it will happen tomorrow, not before -- this night I am going to sleep! ;-)
With newLISP you can grow your lists from the right side!

Cyril
Posts: 183
Joined: Tue Oct 30, 2007 6:27 pm
Location: Moscow, Russia
Contact:

version 1.10

Post by Cyril »

Cyril wrote:If you like to start nested lists with the first column (maybe for a reason), then stay with version 1.8 -- or wait for 1.10. I am planning to make all error marks disable-able (each kind of error individually). But it will happen tomorrow, not before -- this night I am going to sleep! ;-)
I was too optimistic about "tomorrow", but this is at last done! With version 1.10 you can choose which kinds of errors you want to highlight. For example, if you don't like the nested left parenthesis in the leftmost column checking introduced in version 1.9, you can now write let g:newlisp_noerrors = "1" in your .vimrc and this test will be disabled. Assigning "12345" will disable all tests.

Another change: @example keyword in documentation comments processed closer with newlispdoc behavior.
With newLISP you can grow your lists from the right side!

Locked