diff options
author | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-06-02 11:38:18 +0300 |
---|---|---|
committer | Robin Haberkorn <robin.haberkorn@googlemail.com> | 2025-06-03 02:13:20 +0300 |
commit | bf4ce2f28a5d4cc3f1f4a7a1d2450e6893ff5d7b (patch) | |
tree | f7abbd91c59221f801d11926ad303358bf5887c3 | |
parent | 442268285a5f8b1d53052b6c7b0566d9200e71c7 (diff) | |
download | sciteco-bf4ce2f28a5d4cc3f1f4a7a1d2450e6893ff5d7b.tar.gz |
added LaTeX lexer config
-rw-r--r-- | freebsd/pkg-plist | 1 | ||||
-rw-r--r-- | lib/Makefile.am | 3 | ||||
-rw-r--r-- | lib/lexers/latex.tes | 32 |
3 files changed, 35 insertions, 1 deletions
diff --git a/freebsd/pkg-plist b/freebsd/pkg-plist index 0f06e0b..8f99bdd 100644 --- a/freebsd/pkg-plist +++ b/freebsd/pkg-plist @@ -50,6 +50,7 @@ share/man/man7/%%PROGRAM_PREFIX%%sciteco.7.gz %%LEXILLA%%%%DATADIR%%/lib/lexers/java.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/js.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/kix.tes +%%LEXILLA%%%%DATADIR%%/lib/lexers/latex.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/lisp.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/lout.tes %%LEXILLA%%%%DATADIR%%/lib/lexers/lua.tes diff --git a/lib/Makefile.am b/lib/Makefile.am index b8832ab..c272b0e 100644 --- a/lib/Makefile.am +++ b/lib/Makefile.am @@ -105,6 +105,7 @@ dist_lexer_DATA += lexers/verilog.tes \ lexers/asciidoc.tes \ lexers/troff.tes \ lexers/sql.tes \ - lexers/css.tes + lexers/css.tes \ + lexers/latex.tes endif diff --git a/lib/lexers/latex.tes b/lib/lexers/latex.tes new file mode 100644 index 0000000..de3d1cf --- /dev/null +++ b/lib/lexers/latex.tes @@ -0,0 +1,32 @@ +!* LaTeX *! + +@[lexer.test.latex]{ + :EN*.texQ*"S -1 ' + :EN*.styQ* +} + +@[lexer.set.latex]{ + ESSETILEXERlatex + + !* command *! + :M[color.keyword],1M[color.set] + !* tag opening *! + :M[color.string],2M[color.set] + !* math inline *! + !!:M[color.preproc2],3M[color.set] + :M[color.comment],4M[color.set] + !* tag closing *! + :M[color.string],5M[color.set] + !* math block *! + !!:M[color.preproc2],6M[color.set] + :M[color.comment],7M[color.set] + !* verbatim segment *! + !!:M[color.string],8M[color.set] + !* short command *! + :M[color.preproc],9M[color.set] + !* special char *! + :M[color.preproc2],10M[color.set] + !* command optional argument *! + :M[color.string2],11M[color.set] + :M[color.error],12M[color.set] +} |