textpow1x 0.11.0 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (173) hide show
  1. data/Gemfile +1 -2
  2. data/Gemfile.lock +11 -10
  3. data/README.rdoc +4 -6
  4. data/Rakefile +2 -7
  5. data/lib/textpow.rb +4 -0
  6. data/lib/textpow/syntax/actionscript.syntax +97 -0
  7. data/lib/textpow/syntax/active4d.syntax +276 -0
  8. data/lib/textpow/syntax/active4d_html.syntax +311 -0
  9. data/lib/textpow/syntax/active4d_ini.syntax +50 -0
  10. data/lib/textpow/syntax/active4d_library.syntax +21 -0
  11. data/lib/textpow/syntax/ada.syntax +33 -0
  12. data/lib/textpow/syntax/antlr.syntax +151 -0
  13. data/lib/textpow/syntax/apache.syntax +191 -0
  14. data/lib/textpow/syntax/applescript.syntax +384 -0
  15. data/lib/textpow/syntax/asp.syntax +70 -0
  16. data/lib/textpow/syntax/asp_vb.net.syntax +129 -0
  17. data/lib/textpow/syntax/bibtex.syntax +151 -0
  18. data/lib/textpow/syntax/blog_html.syntax +41 -0
  19. data/lib/textpow/syntax/blog_markdown.syntax +42 -0
  20. data/lib/textpow/syntax/blog_text.syntax +27 -0
  21. data/lib/textpow/syntax/blog_textile.syntax +27 -0
  22. data/lib/textpow/syntax/broken/markdown.syntax +543 -0
  23. data/lib/textpow/syntax/broken/php.syntax +1253 -0
  24. data/lib/textpow/syntax/buggy/nemerle.syntax +74 -0
  25. data/lib/textpow/syntax/build.syntax +53 -0
  26. data/lib/textpow/syntax/bulletin_board.syntax +287 -0
  27. data/lib/textpow/syntax/c++.syntax +186 -0
  28. data/lib/textpow/syntax/c.syntax +414 -0
  29. data/lib/textpow/syntax/cake.syntax +55 -0
  30. data/lib/textpow/syntax/camlp4.syntax +36 -0
  31. data/lib/textpow/syntax/cm.syntax +32 -0
  32. data/lib/textpow/syntax/coffeescript.syntax +216 -0
  33. data/lib/textpow/syntax/coldfusion.syntax +119 -0
  34. data/lib/textpow/syntax/context_free.syntax +176 -0
  35. data/lib/textpow/syntax/cs.syntax +59 -0
  36. data/lib/textpow/syntax/css.syntax +195 -0
  37. data/lib/textpow/syntax/css_experimental.syntax +1925 -0
  38. data/lib/textpow/syntax/csv.syntax +68 -0
  39. data/lib/textpow/syntax/d.syntax +142 -0
  40. data/lib/textpow/syntax/diff.syntax +81 -0
  41. data/lib/textpow/syntax/dokuwiki.syntax +204 -0
  42. data/lib/textpow/syntax/dot.syntax +47 -0
  43. data/lib/textpow/syntax/doxygen.syntax +43 -0
  44. data/lib/textpow/syntax/dylan.syntax +62 -0
  45. data/lib/textpow/syntax/eiffel.syntax +78 -0
  46. data/lib/textpow/syntax/erlang.syntax +922 -0
  47. data/lib/textpow/syntax/f-script.syntax +80 -0
  48. data/lib/textpow/syntax/fortran.syntax +141 -0
  49. data/lib/textpow/syntax/fxscript.syntax +142 -0
  50. data/lib/textpow/syntax/greasemonkey.syntax +34 -0
  51. data/lib/textpow/syntax/gri.syntax +83 -0
  52. data/lib/textpow/syntax/groovy.syntax +191 -0
  53. data/lib/textpow/syntax/gtd.syntax +22 -0
  54. data/lib/textpow/syntax/gtdalt.syntax +143 -0
  55. data/lib/textpow/syntax/haml.syntax +88 -0
  56. data/lib/textpow/syntax/haskell.syntax +88 -0
  57. data/lib/textpow/syntax/html-asp.syntax +27 -0
  58. data/lib/textpow/syntax/html.syntax +362 -0
  59. data/lib/textpow/syntax/html_django.syntax +36 -0
  60. data/lib/textpow/syntax/html_for_asp.net.syntax +424 -0
  61. data/lib/textpow/syntax/html_mason.syntax +119 -0
  62. data/lib/textpow/syntax/html_rails.syntax +40 -0
  63. data/lib/textpow/syntax/html_tcl.syntax +26 -0
  64. data/lib/textpow/syntax/icalendar.syntax +32 -0
  65. data/lib/textpow/syntax/inform.syntax +48 -0
  66. data/lib/textpow/syntax/ini.syntax +55 -0
  67. data/lib/textpow/syntax/installer_distribution_script.syntax +77 -0
  68. data/lib/textpow/syntax/io.syntax +81 -0
  69. data/lib/textpow/syntax/java.syntax +211 -0
  70. data/lib/textpow/syntax/javaproperties.syntax +20 -0
  71. data/lib/textpow/syntax/javascript.syntax +256 -0
  72. data/lib/textpow/syntax/javascript_+_prototype.syntax +72 -0
  73. data/lib/textpow/syntax/javascript_+_prototype_bracketed.syntax +140 -0
  74. data/lib/textpow/syntax/jquery_javascript.syntax +114 -0
  75. data/lib/textpow/syntax/json.syntax +136 -0
  76. data/lib/textpow/syntax/languagedefinition.syntax +708 -0
  77. data/lib/textpow/syntax/latex.syntax +566 -0
  78. data/lib/textpow/syntax/latex_beamer.syntax +41 -0
  79. data/lib/textpow/syntax/latex_log.syntax +50 -0
  80. data/lib/textpow/syntax/latex_memoir.syntax +64 -0
  81. data/lib/textpow/syntax/lexflex.syntax +219 -0
  82. data/lib/textpow/syntax/lighttpd.syntax +54 -0
  83. data/lib/textpow/syntax/lilypond.syntax +492 -0
  84. data/lib/textpow/syntax/lisp.syntax +61 -0
  85. data/lib/textpow/syntax/literate_haskell.syntax +24 -0
  86. data/lib/textpow/syntax/logo.syntax +29 -0
  87. data/lib/textpow/syntax/logtalk.syntax +152 -0
  88. data/lib/textpow/syntax/lua.syntax +86 -0
  89. data/lib/textpow/syntax/m.syntax +142 -0
  90. data/lib/textpow/syntax/macports_portfile.syntax +163 -0
  91. data/lib/textpow/syntax/mail.syntax +118 -0
  92. data/lib/textpow/syntax/makefile.syntax +36 -0
  93. data/lib/textpow/syntax/man.syntax +17 -0
  94. data/lib/textpow/syntax/mediawiki.syntax +567 -0
  95. data/lib/textpow/syntax/mel.syntax +92 -0
  96. data/lib/textpow/syntax/mips.syntax +66 -0
  97. data/lib/textpow/syntax/mod_perl.syntax +50 -0
  98. data/lib/textpow/syntax/modula-3.syntax +47 -0
  99. data/lib/textpow/syntax/moinmoin.syntax +189 -0
  100. data/lib/textpow/syntax/mootools.syntax +572 -0
  101. data/lib/textpow/syntax/movable_type.syntax +162 -0
  102. data/lib/textpow/syntax/multimarkdown.syntax +39 -0
  103. data/lib/textpow/syntax/objective-c++.syntax +18 -0
  104. data/lib/textpow/syntax/objective-c.syntax +233 -0
  105. data/lib/textpow/syntax/ocaml.syntax +764 -0
  106. data/lib/textpow/syntax/ocamllex.syntax +167 -0
  107. data/lib/textpow/syntax/ocamlyacc.syntax +184 -0
  108. data/lib/textpow/syntax/old/YAML.yaml +160 -0
  109. data/lib/textpow/syntax/old/txt2tags.yaml +139 -0
  110. data/lib/textpow/syntax/opengl.syntax +14 -0
  111. data/lib/textpow/syntax/pascal.syntax +77 -0
  112. data/lib/textpow/syntax/perl.syntax +1113 -0
  113. data/lib/textpow/syntax/plain_text.syntax +32 -0
  114. data/lib/textpow/syntax/pmwiki.syntax +113 -0
  115. data/lib/textpow/syntax/postscript.syntax +114 -0
  116. data/lib/textpow/syntax/processing.syntax +106 -0
  117. data/lib/textpow/syntax/prolog.syntax +40 -0
  118. data/lib/textpow/syntax/property_list.syntax +635 -0
  119. data/lib/textpow/syntax/python.syntax +868 -0
  120. data/lib/textpow/syntax/python_django.syntax +21 -0
  121. data/lib/textpow/syntax/qmake_project.syntax +114 -0
  122. data/lib/textpow/syntax/qt_c++.syntax +26 -0
  123. data/lib/textpow/syntax/quake3_config.syntax +32 -0
  124. data/lib/textpow/syntax/r.syntax +81 -0
  125. data/lib/textpow/syntax/r_console.syntax +16 -0
  126. data/lib/textpow/syntax/ragel.syntax +201 -0
  127. data/lib/textpow/syntax/rd_r_documentation.syntax +91 -0
  128. data/lib/textpow/syntax/regexp.syntax +50 -0
  129. data/lib/textpow/syntax/regular_expressions_oniguruma.syntax +107 -0
  130. data/lib/textpow/syntax/regular_expressions_python.syntax +109 -0
  131. data/lib/textpow/syntax/release_notes.syntax +46 -0
  132. data/lib/textpow/syntax/remind.syntax +253 -0
  133. data/lib/textpow/syntax/restructuredtext.syntax +250 -0
  134. data/lib/textpow/syntax/rez.syntax +80 -0
  135. data/lib/textpow/syntax/ruby.syntax +1035 -0
  136. data/lib/textpow/syntax/ruby_experimental.syntax +145 -0
  137. data/lib/textpow/syntax/ruby_on_rails.syntax +88 -0
  138. data/lib/textpow/syntax/s5.syntax +69 -0
  139. data/lib/textpow/syntax/sass.syntax +45 -0
  140. data/lib/textpow/syntax/scheme.syntax +347 -0
  141. data/lib/textpow/syntax/scilab.syntax +41 -0
  142. data/lib/textpow/syntax/setext.syntax +147 -0
  143. data/lib/textpow/syntax/shell-unix-generic.syntax +384 -0
  144. data/lib/textpow/syntax/slate.syntax +149 -0
  145. data/lib/textpow/syntax/smarty.syntax +63 -0
  146. data/lib/textpow/syntax/sql.syntax +237 -0
  147. data/lib/textpow/syntax/sql_rails.syntax +18 -0
  148. data/lib/textpow/syntax/ssh-config.syntax +33 -0
  149. data/lib/textpow/syntax/standard_ml.syntax +121 -0
  150. data/lib/textpow/syntax/strings_file.syntax +39 -0
  151. data/lib/textpow/syntax/subversion_commit_message.syntax +36 -0
  152. data/lib/textpow/syntax/sweave.syntax +84 -0
  153. data/lib/textpow/syntax/swig.syntax +57 -0
  154. data/lib/textpow/syntax/tcl.syntax +152 -0
  155. data/lib/textpow/syntax/template_toolkit.syntax +121 -0
  156. data/lib/textpow/syntax/tex.syntax +86 -0
  157. data/lib/textpow/syntax/tex_math.syntax +49 -0
  158. data/lib/textpow/syntax/textile.syntax +215 -0
  159. data/lib/textpow/syntax/tsv.syntax +50 -0
  160. data/lib/textpow/syntax/twiki.syntax +241 -0
  161. data/lib/textpow/syntax/txt2tags.syntax +79 -0
  162. data/lib/textpow/syntax/vectorscript.syntax +57 -0
  163. data/lib/textpow/syntax/xhtml_1.0.syntax +4027 -0
  164. data/lib/textpow/syntax/xml.syntax +180 -0
  165. data/lib/textpow/syntax/xml_strict.syntax +92 -0
  166. data/lib/textpow/syntax/xsl.syntax +60 -0
  167. data/lib/textpow/syntax/yaml.syntax +160 -0
  168. data/lib/textpow/syntax/yui_javascript.syntax +176 -0
  169. data/lib/textpow/version.rb +2 -2
  170. data/spec/spec_helper.rb +2 -0
  171. data/spec/textpow_spec.rb +34 -0
  172. metadata +169 -5
  173. data/test/textpow_test.rb +0 -24
@@ -0,0 +1,566 @@
1
+ ---
2
+ name: LaTeX
3
+ fileTypes:
4
+ - tex
5
+ firstLineMatch: ^\\documentclass(?!.*\{beamer\})
6
+ scopeName: text.tex.latex
7
+ uuid: 3BEEA00C-6B1D-11D9-B8AD-000D93589AF6
8
+ foldingStartMarker: \\begin\{.*\}|%.*\(fold\)\s*$
9
+ patterns:
10
+ - name: meta.space-after-command.latex
11
+ match: (?=\s)(?<=\\[\w@]|\\[\w@]{2}|\\[\w@]{3}|\\[\w@]{4}|\\[\w@]{5}|\\[\w@]{6})\s
12
+ - name: meta.preamble.latex
13
+ endCaptures:
14
+ "0":
15
+ name: punctuation.definition.arguments.end.latex
16
+ begin: ((\\)(?:usepackage|documentclass))(?:(\[)([^\]]*)(\]))?(\{)
17
+ contentName: support.class.latex
18
+ beginCaptures:
19
+ "6":
20
+ name: punctuation.definition.arguments.begin.latex
21
+ "1":
22
+ name: keyword.control.preamble.latex
23
+ "2":
24
+ name: punctuation.definition.function.latex
25
+ "3":
26
+ name: punctuation.definition.arguments.begin.latex
27
+ "4":
28
+ name: variable.parameter.latex
29
+ "5":
30
+ name: punctuation.definition.arguments.end.latex
31
+ end: \}
32
+ patterns:
33
+ - include: $self
34
+ - name: meta.include.latex
35
+ endCaptures:
36
+ "0":
37
+ name: punctuation.definition.arguments.end.latex
38
+ begin: ((\\)(?:include|input))(\{)
39
+ contentName: support.class.latex
40
+ beginCaptures:
41
+ "1":
42
+ name: keyword.control.include.latex
43
+ "2":
44
+ name: punctuation.definition.function.latex
45
+ "3":
46
+ name: punctuation.definition.arguments.begin.latex
47
+ end: \}
48
+ patterns:
49
+ - include: $self
50
+ - name: meta.function.section.latex
51
+ endCaptures:
52
+ "0":
53
+ name: punctuation.definition.arguments.end.latex
54
+ begin: "(?x)\n\
55
+ \t\t\t\t(\t\t\t\t\t\t\t\t\t\t\t\t\t# Capture 1\n\
56
+ \t\t\t\t\t(\\\\)\t\t\t\t\t\t\t\t\t\t\t# Marker\n\
57
+ \t\t\t\t\t(?:\n\
58
+ \t\t\t\t\t\t(?:sub){0,2}section\t\t\t\t\t\t\t# Functions\n\
59
+ \t\t\t\t\t | (?:sub)?paragraph\n\
60
+ \t\t\t\t\t | chapter|part|addpart\n\
61
+ \t\t\t\t\t | addchap|addsec|minisec\n\
62
+ \t\t\t\t\t)\n\
63
+ \t\t\t\t\t(?:\\*)?\t\t\t\t\t\t\t\t\t\t\t# Optional Unnumbered\n\
64
+ \t\t\t\t)\n\
65
+ \t\t\t\t(?:\n\
66
+ \t\t\t\t\t(\\[)([^\\[]*?)(\\])\t\t\t\t\t\t\t\t# Optional Title\n\
67
+ \t\t\t\t)??\n\
68
+ \t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t\t\t# Opening Bracket\n\
69
+ \t\t\t\t"
70
+ contentName: entity.name.section.latex
71
+ beginCaptures:
72
+ "6":
73
+ name: punctuation.definition.arguments.begin.latex
74
+ "1":
75
+ name: support.function.section.latex
76
+ "2":
77
+ name: punctuation.definition.function.latex
78
+ "3":
79
+ name: punctuation.definition.arguments.optional.begin.latex
80
+ "4":
81
+ name: entity.name.section.latex
82
+ "5":
83
+ name: punctuation.definition.arguments.optional.end.latex
84
+ end: \}
85
+ patterns:
86
+ - include: $self
87
+ comment: this works OK with all kinds of crazy stuff as long as section is one line
88
+ - name: meta.function.embedded.java.latex
89
+ captures:
90
+ "6":
91
+ name: punctuation.definition.arguments.optional.begin.latex
92
+ "7":
93
+ name: punctuation.definition.arguments.optional.end.latex
94
+ "8":
95
+ name: comment.line.percentage.latex
96
+ "1":
97
+ name: support.function.be.latex
98
+ "2":
99
+ name: punctuation.definition.function.latex
100
+ "3":
101
+ name: punctuation.definition.arguments.begin.latex
102
+ "4":
103
+ name: variable.parameter.function.latex
104
+ "5":
105
+ name: punctuation.definition.arguments.end.latex
106
+ begin: (?:\s*)((\\)begin)(\{)(lstlisting)(\})(?:(\[).*(\]))?(\s*%\s*(?i:Java)\n?)
107
+ contentName: source.java.embedded
108
+ end: ((\\)end)(\{)(lstlisting)(\})
109
+ patterns:
110
+ - include: source.java
111
+ - name: meta.function.embedded.python.latex
112
+ captures:
113
+ "6":
114
+ name: punctuation.definition.arguments.optional.begin.latex
115
+ "7":
116
+ name: punctuation.definition.arguments.optional.end.latex
117
+ "8":
118
+ name: comment.line.percentage.latex
119
+ "1":
120
+ name: support.function.be.latex
121
+ "2":
122
+ name: punctuation.definition.function.latex
123
+ "3":
124
+ name: punctuation.definition.arguments.begin.latex
125
+ "4":
126
+ name: variable.parameter.function.latex
127
+ "5":
128
+ name: punctuation.definition.arguments.end.latex
129
+ begin: (?:\s*)((\\)begin)(\{)(lstlisting)(\})(?:(\[).*(\]))?(\s*%.*\n?)?
130
+ contentName: source.python.embedded
131
+ end: ((\\)end)(\{)(lstlisting)(\})
132
+ patterns:
133
+ - include: source.python
134
+ comment: Put the lstlisting match before the more general environment listing. Someday it would be nice to make this rule general enough to figure out which language is inside the lstlisting environment rather than my own personal use for python. --Brad
135
+ - name: meta.function.verbatim.latex
136
+ captures:
137
+ "1":
138
+ name: support.function.be.latex
139
+ "2":
140
+ name: punctuation.definition.function.latex
141
+ "3":
142
+ name: punctuation.definition.arguments.begin.latex
143
+ "4":
144
+ name: variable.parameter.function.latex
145
+ "5":
146
+ name: punctuation.definition.arguments.end.latex
147
+ begin: (?:\s*)((\\)begin)(\{)((?:V|v)erbatim)(\})
148
+ contentName: markup.raw.verbatim.latex
149
+ end: ((\\)end)(\{)(\4)(\})
150
+ - name: meta.function.begin-document.latex
151
+ captures:
152
+ "1":
153
+ name: support.function.be.latex
154
+ "2":
155
+ name: punctuation.definition.function.latex
156
+ "3":
157
+ name: punctuation.definition.arguments.begin.latex
158
+ "4":
159
+ name: variable.parameter.function.latex
160
+ "5":
161
+ name: punctuation.definition.arguments.end.latex
162
+ match: (?:\s*)((\\)begin)(\{)(document)(\})
163
+ comment: These two patterns match the \begin{document} and \end{document} commands, so that the environment matching pattern following them will ignore those commands.
164
+ - name: meta.function.end-document.latex
165
+ captures:
166
+ "1":
167
+ name: support.function.be.latex
168
+ "2":
169
+ name: punctuation.definition.function.latex
170
+ "3":
171
+ name: punctuation.definition.arguments.begin.latex
172
+ "4":
173
+ name: variable.parameter.function.latex
174
+ "5":
175
+ name: punctuation.definition.arguments.end.latex
176
+ match: (?:\s*)((\\)end)(\{)(document)(\})
177
+ - name: meta.function.environment.math.latex
178
+ captures:
179
+ "1":
180
+ name: support.function.be.latex
181
+ "2":
182
+ name: punctuation.definition.function.latex
183
+ "3":
184
+ name: punctuation.definition.arguments.begin.latex
185
+ "4":
186
+ name: variable.parameter.function.latex
187
+ "5":
188
+ name: punctuation.definition.arguments.end.latex
189
+ begin: "(?x)\n\
190
+ \t\t\t\t\t(?:\\s*)\t\t\t\t\t\t\t\t\t\t# Optional whitespace\n\
191
+ \t\t\t\t\t((\\\\)begin)\t\t\t\t\t\t\t\t\t# Marker - Function\n\
192
+ \t\t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t# Open Bracket\n\
193
+ \t\t\t\t\t\t(\n\
194
+ \t\t\t\t\t\t\t(?:\n\
195
+ \t\t\t\t\t\t\t\talign|equation|eqnarray\t\t\t# Argument\n\
196
+ \t\t\t\t\t\t\t | multline|aligned|alignat\n\
197
+ \t\t\t\t\t\t\t | split|gather|gathered\n\
198
+ \t\t\t\t\t\t\t)\n\
199
+ \t\t\t\t\t\t\t(?:\\*)?\t\t\t\t\t\t\t\t# Optional Unnumbered\n\
200
+ \t\t\t\t\t\t)\n\
201
+ \t\t\t\t\t(\\})\t\t\t\t\t\t\t\t\t\t# Close Bracket\n\
202
+ \t\t\t\t\t(\\s*\\n)?\t\t\t\t# Match to end of line absent of content\n\
203
+ \t\t\t\t"
204
+ contentName: string.other.math.block.environment.latex
205
+ end: "(?x)\n\
206
+ \t\t\t\t\t(?:\\s*)\t\t\t\t\t\t\t\t\t\t# Optional whitespace\n\
207
+ \t\t\t\t\t((\\\\)end)\t\t\t\t\t\t\t\t\t# Marker - Function\n\
208
+ \t\t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t# Open Bracket\n\
209
+ \t\t\t\t\t\t(\\4)\t\t\t\t# Previous capture from begin\n\
210
+ \t\t\t\t\t(\\})\t\t\t\t\t\t\t\t\t\t# Close Bracket\n\
211
+ \t\t\t\t\t(?:\\s*\\n)?\t\t\t\t# Match to end of line absent of content\n\
212
+ \t\t\t\t"
213
+ patterns:
214
+ - include: $base
215
+ - name: meta.function.environment.tabular.latex
216
+ captures:
217
+ "1":
218
+ name: support.function.be.latex
219
+ "2":
220
+ name: punctuation.definition.function.latex
221
+ "3":
222
+ name: punctuation.definition.arguments.begin.latex
223
+ "4":
224
+ name: variable.parameter.function.latex
225
+ "5":
226
+ name: punctuation.definition.arguments.end.latex
227
+ begin: "(?x)\n\
228
+ \t\t\t\t\t(?:\\s*)\t\t\t\t\t\t\t\t\t\t# Optional whitespace\n\
229
+ \t\t\t\t\t((\\\\)begin)\t\t\t\t\t\t\t\t\t# Marker - Function\n\
230
+ \t\t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t# Open Bracket\n\
231
+ \t\t\t\t\t\t(array|tabular[xy*]?)\n\
232
+ \t\t\t\t\t(\\})\t\t\t\t\t\t\t\t\t\t# Close Bracket\n\
233
+ \t\t\t\t\t(\\s*\\n)?\t\t\t\t# Match to end of line absent of content\n\
234
+ \t\t\t\t"
235
+ contentName: meta.data.environment.tabular.latex
236
+ end: "(?x)\n\
237
+ \t\t\t\t\t(?:\\s*)\t\t\t\t\t\t\t\t\t\t# Optional whitespace\n\
238
+ \t\t\t\t\t((\\\\)end)\t\t\t\t\t\t\t\t\t# Marker - Function\n\
239
+ \t\t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t# Open Bracket\n\
240
+ \t\t\t\t\t\t(\\4)\t\t\t\t# Previous capture from begin\n\
241
+ \t\t\t\t\t(\\})\t\t\t\t\t\t\t\t\t\t# Close Bracket\n\
242
+ \t\t\t\t\t(?:\\s*\\n)?\t\t\t\t# Match to end of line absent of content\n\
243
+ \t\t\t\t"
244
+ patterns:
245
+ - name: punctuation.definition.table.row.latex
246
+ match: \\
247
+ - name: meta.row.environment.tabular.latex
248
+ begin: (?:^|(?<=\\\\))(?!\\\\|\s*\\end\{(?:tabular|array))
249
+ end: (?=\\\\|\s*\\end\{(?:tabular|array))
250
+ patterns:
251
+ - name: punctuation.definition.table.cell.latex
252
+ match: "&"
253
+ - name: meta.cell.environment.tabular.latex
254
+ begin: (?:^|(?<=&))((?!&|\\\\|$))
255
+ end: (?=&|\\\\|\s*\\end\{(?:tabular|array))
256
+ patterns:
257
+ - include: $base
258
+ - include: $base
259
+ - include: $base
260
+ - name: meta.function.environment.list.latex
261
+ captures:
262
+ "1":
263
+ name: support.function.be.latex
264
+ "2":
265
+ name: punctuation.definition.function.latex
266
+ "3":
267
+ name: punctuation.definition.arguments.latex
268
+ "4":
269
+ name: variable.parameter.function.latex
270
+ "5":
271
+ name: punctuation.definition.arguments.latex
272
+ begin: (?:\s*)((\\)begin)(\{)(itemize|enumerate|description|list)(\})
273
+ end: ((\\)end)(\{)(\4)(\})(?:\s*\n)?
274
+ patterns:
275
+ - include: $base
276
+ - name: meta.function.environment.general.latex
277
+ captures:
278
+ "1":
279
+ name: support.function.be.latex
280
+ "2":
281
+ name: punctuation.definition.function.latex
282
+ "3":
283
+ name: punctuation.definition.arguments.latex
284
+ "4":
285
+ name: variable.parameter.function.latex
286
+ "5":
287
+ name: punctuation.definition.arguments.latex
288
+ begin: (?:\s*)((\\)begin)(\{)(\w+[*]?)(\})
289
+ end: ((\\)end)(\{)(\4)(\})(?:\s*\n)?
290
+ patterns:
291
+ - include: $base
292
+ - name: storage.type.function.latex
293
+ captures:
294
+ "1":
295
+ name: punctuation.definition.function.latex
296
+ match: (\\)(newcommand|renewcommand)\b
297
+ - endCaptures:
298
+ "0":
299
+ name: punctuation.definition.marginpar.end.latex
300
+ begin: ((\\)marginpar)(\{)
301
+ contentName: meta.paragraph.margin.latex
302
+ beginCaptures:
303
+ "1":
304
+ name: support.function.marginpar.latex
305
+ "2":
306
+ name: punctuation.definition.function.latex
307
+ "3":
308
+ name: punctuation.definition.marginpar.begin.latex
309
+ end: \}
310
+ patterns:
311
+ - include: $base
312
+ - endCaptures:
313
+ "0":
314
+ name: punctuation.definition.footnote.end.latex
315
+ begin: ((\\)footnote)(\{)
316
+ contentName: meta.footnote.latex
317
+ beginCaptures:
318
+ "1":
319
+ name: support.function.footnote.latex
320
+ "2":
321
+ name: punctuation.definition.function.latex
322
+ "3":
323
+ name: punctuation.definition.footnote.begin.latex
324
+ end: \}
325
+ patterns:
326
+ - include: $base
327
+ - name: meta.function.emph.latex
328
+ endCaptures:
329
+ "0":
330
+ name: punctuation.definition.emph.end.latex
331
+ begin: ((\\)emph)(\{)
332
+ contentName: markup.italic.emph.latex
333
+ beginCaptures:
334
+ "1":
335
+ name: support.function.emph.latex
336
+ "2":
337
+ name: punctuation.definition.function.latex
338
+ "3":
339
+ name: punctuation.definition.emph.begin.latex
340
+ end: \}
341
+ patterns:
342
+ - include: $base
343
+ - name: meta.function.textit.latex
344
+ endCaptures:
345
+ "0":
346
+ name: punctuation.definition.textit.end.latex
347
+ captures:
348
+ "1":
349
+ name: support.function.textit.latex
350
+ "2":
351
+ name: punctuation.definition.function.latex
352
+ "3":
353
+ name: punctuation.definition.textit.begin.latex
354
+ begin: ((\\)textit)(\{)
355
+ contentName: markup.italic.textit.latex
356
+ end: \}
357
+ patterns:
358
+ - include: $base
359
+ comment: "We put the keyword in a capture and name this capture, so that disabling spell checking for \xE2\x80\x9Ckeyword\xE2\x80\x9D won't be inherited by the argument to \\textit{...}.\n\n\
360
+ Put specific matches for particular LaTeX keyword.functions before the last two more general functions"
361
+ - name: meta.function.textbf.latex
362
+ endCaptures:
363
+ "0":
364
+ name: punctuation.definition.textbf.end.latex
365
+ captures:
366
+ "1":
367
+ name: support.function.textbf.latex
368
+ "2":
369
+ name: punctuation.definition.function.latex
370
+ "3":
371
+ name: punctuation.definition.textbf.begin.latex
372
+ begin: ((\\)textbf)(\{)
373
+ contentName: markup.bold.textbf.latex
374
+ end: \}
375
+ patterns:
376
+ - include: $base
377
+ - name: meta.function.texttt.latex
378
+ endCaptures:
379
+ "0":
380
+ name: punctuation.definition.texttt.end.latex
381
+ captures:
382
+ "1":
383
+ name: support.function.texttt.latex
384
+ "2":
385
+ name: punctuation.definition.function.latex
386
+ "3":
387
+ name: punctuation.definition.texttt.begin.latex
388
+ begin: ((\\)texttt)(\{)
389
+ contentName: markup.raw.texttt.latex
390
+ end: \}
391
+ patterns:
392
+ - include: $base
393
+ - name: meta.scope.item.latex
394
+ captures:
395
+ "0":
396
+ name: keyword.other.item.latex
397
+ "1":
398
+ name: punctuation.definition.keyword.latex
399
+ match: (\\)item\b
400
+ - name: meta.citation.latex
401
+ endCaptures:
402
+ "0":
403
+ name: punctuation.definition.arguments.latex
404
+ captures:
405
+ "6":
406
+ name: punctuation.definition.arguments.optional.end.latex
407
+ "7":
408
+ name: punctuation.definition.arguments.latex
409
+ "1":
410
+ name: keyword.control.cite.latex
411
+ "2":
412
+ name: punctuation.definition.keyword.latex
413
+ "3":
414
+ name: punctuation.definition.arguments.optional.begin.latex
415
+ "4":
416
+ name: punctuation.definition.arguments.optional.end.latex
417
+ "5":
418
+ name: punctuation.definition.arguments.optional.begin.latex
419
+ begin: "(?x)\n\
420
+ \t\t\t\t\t(\n\
421
+ \t\t\t\t\t\t(\\\\)\t\t\t\t\t\t\t\t\t\t# Marker\n\
422
+ \t\t\t\t\t\t(?:foot)?(?:full)?(?:no)?(?:short)?\t\t# Function Name\n\
423
+ \t\t\t\t\t\tcite\n\
424
+ \t\t\t\t\t\t(?:al)?(?:t|p|author|year(?:par)?|title)?[ANP]*\n\
425
+ \t\t\t\t\t\t\\*?\t\t\t\t\t\t\t\t\t\t\t# Optional Unabreviated\n\
426
+ \t\t\t\t\t)\n\
427
+ \t\t\t\t\t(?:(\\[)[^\\]]*(\\]))?\t\t\t\t\t\t\t\t# Optional\n\
428
+ \t\t\t\t\t(?:(\\[)[^\\]]*(\\]))?\t\t\t\t\t\t\t\t# Arguments\n\
429
+ \t\t\t\t\t(\\{)\t\t\t\t\t\t\t\t\t\t\t# Opening Bracket\n\
430
+ \t\t\t\t"
431
+ end: \}
432
+ patterns:
433
+ - name: constant.other.reference.citation.latex
434
+ match: "[\\w:.]+"
435
+ - name: meta.reference.label.latex
436
+ endCaptures:
437
+ "0":
438
+ name: punctuation.definition.arguments.begin.latex
439
+ begin: ((\\)(?:\w*[r|R]ef\*?))(\{)
440
+ beginCaptures:
441
+ "1":
442
+ name: keyword.control.ref.latex
443
+ "2":
444
+ name: punctuation.definition.keyword.latex
445
+ "3":
446
+ name: punctuation.definition.arguments.begin.latex
447
+ end: \}
448
+ patterns:
449
+ - name: constant.other.reference.label.latex
450
+ match: "[a-zA-Z0-9\\.,:/*!^_-]"
451
+ - name: meta.definition.label.latex
452
+ endCaptures:
453
+ "0":
454
+ name: punctuation.definition.arguments.end.latex
455
+ begin: ((\\)label)(\{)
456
+ beginCaptures:
457
+ "1":
458
+ name: keyword.control.label.latex
459
+ "2":
460
+ name: punctuation.definition.keyword.latex
461
+ "3":
462
+ name: punctuation.definition.arguments.begin.latex
463
+ end: \}
464
+ patterns:
465
+ - name: variable.parameter.definition.label.latex
466
+ match: "[a-zA-Z0-9\\.,:/*!^_-]"
467
+ - name: meta.function.verb.latex
468
+ captures:
469
+ "1":
470
+ name: support.function.verb.latex
471
+ "2":
472
+ name: punctuation.definition.function.latex
473
+ "3":
474
+ name: punctuation.definition.verb.latex
475
+ "4":
476
+ name: markup.raw.verb.latex
477
+ "5":
478
+ name: punctuation.definition.verb.latex
479
+ match: ((\\)verb[\*]?)\s*((?<=\s)\S|[^a-zA-Z])(.*?)(\3|$)
480
+ - name: string.quoted.double.european.latex
481
+ endCaptures:
482
+ "0":
483
+ name: punctuation.definition.string.end.latex
484
+ begin: "\"`"
485
+ beginCaptures:
486
+ "0":
487
+ name: punctuation.definition.string.begin.latex
488
+ end: "\"'"
489
+ patterns:
490
+ - include: $base
491
+ - name: string.quoted.double.latex
492
+ endCaptures:
493
+ "0":
494
+ name: punctuation.definition.string.end.latex
495
+ begin: "``"
496
+ beginCaptures:
497
+ "0":
498
+ name: punctuation.definition.string.begin.latex
499
+ end: "''|\""
500
+ patterns:
501
+ - include: $base
502
+ - name: string.quoted.double.guillemot.latex
503
+ endCaptures:
504
+ "0":
505
+ name: punctuation.definition.string.end.latex
506
+ begin: "\">"
507
+ beginCaptures:
508
+ "0":
509
+ name: punctuation.definition.string.begin.latex
510
+ end: "\"<"
511
+ patterns:
512
+ - include: $base
513
+ - name: string.quoted.double.guillemot.latex
514
+ endCaptures:
515
+ "0":
516
+ name: punctuation.definition.string.end.latex
517
+ begin: "\"<"
518
+ beginCaptures:
519
+ "0":
520
+ name: punctuation.definition.string.begin.latex
521
+ end: "\">"
522
+ patterns:
523
+ - include: $base
524
+ - name: string.other.math.latex
525
+ endCaptures:
526
+ "0":
527
+ name: punctuation.definition.string.end.latex
528
+ begin: \\\(
529
+ beginCaptures:
530
+ "0":
531
+ name: punctuation.definition.string.begin.latex
532
+ end: \\\)
533
+ patterns:
534
+ - include: $base
535
+ - name: string.other.math.latex
536
+ endCaptures:
537
+ "0":
538
+ name: punctuation.definition.string.end.latex
539
+ begin: \\\[
540
+ beginCaptures:
541
+ "0":
542
+ name: punctuation.definition.string.begin.latex
543
+ end: \\\]
544
+ patterns:
545
+ - include: $base
546
+ - name: meta.escape-character.latex
547
+ match: \\$
548
+ - name: invalid.illegal.string.quoted.single.latex
549
+ match: (?<!\S)'.*?'
550
+ - name: invalid.illegal.string.quoted.double.latex
551
+ match: (?<!\S)".*?"
552
+ - name: constant.character.latex
553
+ captures:
554
+ "1":
555
+ name: punctuation.definition.constant.latex
556
+ match: (\\)(text(s(terling|ixoldstyle|urd|e(ction|venoldstyle|rvicemark))|yen|n(ineoldstyle|umero|aira)|c(ircledP|o(py(left|right)|lonmonetary)|urrency|e(nt(oldstyle)?|lsius))|t(hree(superior|oldstyle|quarters(emdash)?)|i(ldelow|mes)|w(o(superior|oldstyle)|elveudash)|rademark)|interrobang(down)?|zerooldstyle|o(hm|ne(superior|half|oldstyle|quarter)|penbullet|rd(feminine|masculine))|d(i(scount|ed|v(orced)?)|o(ng|wnarrow|llar(oldstyle)?)|egree|agger(dbl)?|blhyphen(char)?)|uparrow|p(ilcrow|e(so|r(t(housand|enthousand)|iodcentered))|aragraph|m)|e(stimated|ightoldstyle|uro)|quotes(traight(dblbase|base)|ingle)|f(iveoldstyle|ouroldstyle|lorin|ractionsolidus)|won|l(not|ira|e(ftarrow|af)|quill|angle|brackdbl)|a(s(cii(caron|dieresis|acute|grave|macron|breve)|teriskcentered)|cutedbl)|r(ightarrow|e(cipe|ferencemark|gistered)|quill|angle|brackdbl)|g(uarani|ravedbl)|m(ho|inus|u(sicalnote)?|arried)|b(igcircle|orn|ullet|lank|a(ht|rdbl)|rokenbar)))\b
557
+ - name: meta.column-specials.latex
558
+ captures:
559
+ "1":
560
+ name: punctuation.definition.column-specials.begin.latex
561
+ "2":
562
+ name: punctuation.definition.column-specials.end.latex
563
+ match: (?:<|>)(\{)\$(\})
564
+ - include: text.tex
565
+ foldingStopMarker: \\end\{.*\}|%.*\(end\)\s*$
566
+ keyEquivalent: ^~L