1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239
|
# JOE syntax highlight file for Elixir
# Written by Andrey Lisin (at gmail.com)
# TODO
# - test attributes and docstrings highlighting
# - maybe highlight arithmetical operations
# - comprehensions highlighting
# Changes
# - fix atom with underscore highlighting
# - distinct docstrings and module attributes
=Idle
=Ident
=Comment
=Keyword
=Statement +Keyword
=Conditional +Statement
=Type
=DefinedIdent +Ident
=DefinedType +DefinedIdent
=DefinedFunction +DefinedIdent
=Operator +Keyword
=Constant
=Boolean +Constant
=Number +Constant
=String +Constant
=StringEscape +Escape
=StringVariable +StringEscape
=Atom +Constant +DefinedIdent
=Attribute +Define +Preproc
=Brace +Escape
=Bracket +Brace
=Underscore +Keyword
=ModAttr +Atom # key in %{key: value}
:idle Idle
* idle
"#" line_comment noeat
"A-Z" type recolor=-1
"a-z" ident noeat
"_" underscore recolor=-1
"'" single_quoted recolor=-1
"\"" double_quoted recolor=-1
":" atom recolor=-1
"@" modattr recolor=-1
"[]" brack recolor=-1
"{}" brace recolor=-1
"|" maybe_pipe
"\\" maybe_opt
"-" maybe_rarrow recolor=-1
"<" maybe_larrow recolor=-1
"0-9" decimal recolor=-1
:line_comment Comment comment
* line_comment
"BFHNTX" line_comment noeat call=comment_todo.comment_todo()
"\n" idle
:single_quoted String string
* single_quoted
"'" idle
:double_quoted String string
* double_quoted
"#" maybe_extrapolation
"\"" idle
:maybe_extrapolation String string
* double_quoted noeat
"{" extrapolation recolor=-2
:extrapolation StringVariable string
* extrapolation
"}" double_quoted
"\"" double_quoted noeat
:atom Atom
* idle noeat
"a-zA-Z0-9_" atom
:modattr ModAttr
* idle
"a-zA-Z0-9_" modattr
" " maybe_edoc
:maybe_edoc Idle
* idle
" " maybe_edoc
"\"" string_dq_1 recolor=-1
:string_dq_1 String string
* double_quoted recolor=-1
"\"" string_dq_2
:string_dq_2 Comment comment
* idle
"\"" docstr_dq recolor=-3
:docstr_dq Comment comment
* docstr_dq
"\"" docstr_dq_1
:docstr_dq_1 Comment comment
* docstr_dq
"\"" docstr_dq_2
:docstr_dq_2 Comment comment
* docstr_dq
"\"" idle
:brace Brace
* idle noeat
:brack Bracket
* idle noeat
:maybe_larrow Idle
"-" arrow recolor=-2
* idle noeat
:maybe_rarrow Idle
">" arrow recolor=-2
* idle noeat
:arrow Operator
* idle noeat
:maybe_pipe Idle
* idle
">" pipe recolor=-2
:pipe Operator
* idle noeat
:maybe_opt Idle
* idle
"\\" opt recolor=-2
:opt Keyword
* idle noeat
:decimal Number
* idle noeat
"0-9_" decimal
"." float
:float Number
* idle noeat
"0-9" float
:underscore Underscore
* idle noeat
"a-zA-Z0-9?_" underscore
:type Type
"a-zA-Z0-9_" type
* idle noeat
:ident Ident
* ident1 noeat buffer mark
:ident1 Ident
* idle noeat strings
"def" start_func_def
"defp" start_func_def
"defmodule" start_mod_def
"defprotocol" start_def
"defmacro" start_def
"defmacrop" start_def
"defdelegate" start_def
"defexception" start_def
"defstruct" start_def
"defimpl" start_def
"defcallback" start_def
"import" start_mod_def
"require" start_mod_def
"test" start_def
"use" start_mod_def
"alias" start_mod_def
"end" stmt
"do" kw
"for" loop
"if" cond
"else" cond
"unless" cond
"case" cond
"cond" cond
"true" bool
"false" bool
"fn" kw
done
"a-zA-Z_0-9" ident1
":" attr noeat recolormark
:attr Attribute
* idle
:kw Keyword
* idle noeat
:stmt Statement
* idle noeat
:cond Conditional
* idle noeat
:bool Boolean
* idle noeat
:start_def Statement
* def
:start_mod_def Statement
* moddef
:start_func_def Statement
* funcdef
:def DefinedIdent
* def
" (" idle noeat
:funcdef DefinedFunction
* funcdef
" (" idle noeat
:moddef DefinedType
* moddef
" " idle noeat
"\n" idle
|