1
0
mirror of https://github.com/alecthomas/chroma.git synced 2025-02-21 19:06:18 +02:00

122 Commits

Author SHA1 Message Date
Alec Thomas
6d281667bb Merge pull request #49 from FooSoft/toml-lexer
Add lexer for TOML
2017-10-02 08:42:05 +11:00
Alex Yatskov
0f36e89eec Add lexer for TOML 2017-10-01 11:52:09 -07:00
Alec Thomas
63889d53db Merge pull request #48 from Dekker1/feature/minizinc
Add lexer for MiniZinc
2017-10-01 22:52:59 +11:00
Jip J. Dekker
8f804c9a34 Add lexer for MiniZinc 2017-10-01 22:37:43 +11:00
Alec Thomas
0e0960930d Don't output trailing \n for HTML-only fragment.
See #47.
2017-09-30 14:45:37 +10:00
Alec Thomas
ce3d6bf527 Invert default "ensure newline" behaviour so that it is opt-in.
See #47.
2017-09-30 14:41:05 +10:00
Alec Thomas
573c1d157d Ensure a newline exists at the end of files.
Fixes #42.
2017-09-29 21:59:52 +10:00
Alec Thomas
528bed2b60 Fix some capitalisation. 2017-09-29 09:56:36 +10:00
Alec Thomas
a430eb8138 Merge pull request #46 from DeedleFake/master
Add WDTE
2017-09-29 00:12:53 +10:00
Alec Thomas
33f604c892 Always use CSS class from StandardTypes.
As opposed to remapping to classes that exist in the current style.
2017-09-27 22:05:47 +10:00
Alec Thomas
80d3b96869 Ensure class names from default set exist. 2017-09-27 22:01:03 +10:00
Alec Thomas
2ca426a8d1 Make TypeMappingLexer a bit less prone to error. 2017-09-27 21:52:25 +10:00
Alec Thomas
cbc3d5b9f0 Implement special name mappings for EmacsLisp.
Fixes #43.
2017-09-27 21:32:45 +10:00
Alec Thomas
102aa61ac3 Add RemappingLexer.
This pattern is used heavily in Pygments for certain lexers,
particularly Lisp variants. See #43.
2017-09-27 11:30:55 +10:00
DeedleFake
d3a2d28ee2 Add WDTE. 2017-09-26 10:34:57 -04:00
Alec Thomas
c99eebc024 Merge pull request #39 from griffin-stewie/fix/capnproto_name
fix HTML entity reference
2017-09-27 00:34:18 +10:00
griffin-stewie
caf2542b1b fix HTML entity reference ' to ‘ 2017-09-26 22:37:54 +09:00
Alec Thomas
7debecf146 Update README. 2017-09-26 22:15:36 +10:00
Alec Thomas
fc9897da0d Add SystemVerilog and hexdump.
Fixes #33.
2017-09-26 22:13:55 +10:00
Alec Thomas
bc2d6680e4 Run gofmt -s over the codebase. v0.1.1 2017-09-26 22:05:55 +10:00
Alec Thomas
c39abfb916 Squish the GitHub style a bit. 2017-09-26 22:05:55 +10:00
Alec Thomas
be25514088 Merge pull request #37 from steambap/master
Add c# lexer
2017-09-26 14:18:14 +10:00
Weilin Shi
e6a24f7412 Add c# highlight fix #32 2017-09-26 12:15:59 +08:00
Alec Thomas
67b8161815 Merge pull request #36 from AbeEstrada/patch-1
Add 'dracula' style
2017-09-26 13:48:18 +10:00
Abe Estrada
0f9e25c566 Add 'dracula' style
Converted from https://github.com/dracula/pygments
2017-09-25 21:11:21 -06:00
Alec Thomas
559a557458 Merge pull request #34 from Calinou/rename-nimrod-to-nim
Rename the Nimrod lexer to Nim
2017-09-26 06:10:31 +10:00
Hugo Locurcio
8604f257c9 Rename the Nimrod lexer to Nim
It has been the official name of the language for a while now.
2017-09-25 20:08:20 +02:00
Alec Thomas
bdc1124369 Switch to Pygments-style CSS class names.
Add GitHub theme + CSS to style importer.
2017-09-25 21:46:25 +10:00
Alec Thomas
2181aa5f70 Fix goreleaser config (hopefully). v0.1.0 2017-09-25 18:15:44 +10:00
Alec Thomas
a75ba5dc2c Use goreleaser. 2017-09-25 16:47:55 +10:00
Alec Thomas
b0295f66bd Remove spurious newline in HTML output.
Fixes #29.
2017-09-25 15:25:32 +10:00
Alec Thomas
022592be12 Correctly prioritise names over aliases. 2017-09-25 11:56:25 +10:00
Alec Thomas
cf0d471c44 Merge pull request #26 from glaforge/patch-1
Missing 'as' and 'in' keywords for Groovy
2017-09-24 23:22:00 +10:00
Guillaume Laforge
cce6c8e193 Missing 'as' and 'in' keywords 2017-09-24 14:45:24 +02:00
Alec Thomas
b83a015e0b More YAML tweaks. 2017-09-24 21:57:29 +10:00
Alec Thomas
b25b614cb6 Remove comment. 2017-09-24 21:47:46 +10:00
Alec Thomas
237eebbe1a A naive YAML lexer.
Does not try to be smart in anyway. Instead, just highlights what it
can. Used this reference: https://learnxinyminutes.com/docs/yaml/

Fixes #13.
2017-09-24 21:47:05 +10:00
Alec Thomas
c984ca45c7 Add html.BaseLineNumber(n).
Fixes #22.
2017-09-24 20:33:50 +10:00
Alec Thomas
d1be6303e6 Merge pull request #25 from steambap/master
Add GDScript lexer
2017-09-24 19:30:07 +10:00
Weilin Shi
cff81ff391 Add GDScript lexer 2017-09-24 12:58:23 +08:00
Alec Thomas
0e1d1c1e77 Merge pull request #24 from rogersachan/patch-1
Remove old license
2017-09-24 09:09:45 +10:00
Roger
b3b9d8dc51 Remove old license 2017-09-23 19:04:18 -04:00
Alec Thomas
1af7e1a0bc Adjust line number padding a bit. 2017-09-23 22:45:05 +10:00
Alec Thomas
99d0e4924a Simplify command-line flags a bit. 2017-09-23 22:29:46 +10:00
Alec Thomas
d5083b3f7c Big changes to the style and colour APIs.
- Styles now use a builder system, to enforce immutability of styles.
- Corrected and cleaned up how style inheritance works.
- Added a brightening function to colours
- HTML formatter will now automatically pick line and highlight colours
  if they are not provided in the style. This is done by slightly
  darkening or lightening.

Fixes #21.
2017-09-23 22:09:46 +10:00
Alec Thomas
9d7539a4cd Fix bug in Turtle lexer. 2017-09-22 23:27:40 +10:00
Alec Thomas
a5a3b67010 Reprocess all rules after a LexerMutator is applied. 2017-09-22 23:14:32 +10:00
Alec Thomas
8170d52c25 Remove dependency on go-colorful.
Switched to a less accurate (but much simpler) colour distance function
as described here: https://www.compuphase.com/cmetric.htm

Fixes #17.
2017-09-22 23:00:03 +10:00
Alec Thomas
2ce2ec7f65 Fix bug with empty states. 2017-09-22 22:40:00 +10:00
Alec Thomas
0bb853fb4f Convert Include to a LexerMutator.
Fixes #18.
2017-09-22 22:29:17 +10:00