]> git.lizzy.rs Git - micro.git/blob - runtime/syntax/tex.yaml
929fdbc837375a3e2b4dfd96c35d0ce8c3cbcb56
[micro.git] / runtime / syntax / tex.yaml
1 filetype: tex
2
3 detect: 
4     filename: "\\.tex$|bib|\\.bib$|cls|\\.cls$"
5
6 rules:
7     # colorize the identifiers of {<identifier>} and [<identifier>]
8     - identifier:
9         start: "\\{"
10         end: "\\}"
11         rules: []
12     - identifier:
13         start: "\\["
14         end: "\\]"
15         rules: []
16     # numbers
17     - constant.number: "\\b[0-9]+(\\.[0-9]+)?([[:space:]](pt|mm|cm|in|ex|em|bp|pc|dd|cc|nd|nc|sp))?\\b"
18     # let brackets have the default color again
19     - default: "[{}\\[\\]]"
20     - special: "[&\\\\]"
21     # macros
22     - statement: "\\\\@?[a-zA-Z_]+"
23     # comments
24     - comment:
25         start: "%"
26         end: "$"
27         rules: []
28     - comment:
29         start: "\\\\begin\\{comment\\}"
30         end: "\\\\end\\{comment\\}"
31         rules: []