[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-source-highlight] [review] JSON language implementation

From: muji
Subject: [Help-source-highlight] [review] JSON language implementation
Date: Mon, 8 Apr 2013 18:32:39 +0200


Thanks for `source-highlight`, it is fast and easy to customize.

I am working on a tool that required highlighting of JSON documents printed to a terminal so I wrote a JSON language implementation[1] and style file[2].

It appears to function correctly but I would appreciate it if you could review and if it is deemed good enough merge into the next release?

It handles escaped strings correctly, ie:

"string": "my \"quoted\" value"

I wanted to be able to differentiate elements at a granular level so have introduced some JSON specific style names:

* keyquote - Quotation marks for keys
* valquote - Quotation marks for string values
* colon - The colon delimiter
* key - The string between key quotes

The number handling is taken from number.lang and can be replaced with an include of number.lang if you wish to merge this language definition.



mischa (aka muji).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]