-
Notifications
You must be signed in to change notification settings - Fork 18
Expand file tree
/
Copy pathflor.vim
More file actions
45 lines (34 loc) · 1.13 KB
/
flor.vim
File metadata and controls
45 lines (34 loc) · 1.13 KB
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
" MIT licensed
" in the vimrc file itself:
"au BufRead *.flo set filetype=flor
"au BufRead *.flor set filetype=flor
"au BufRead *.flon set filetype=flor
"au BufRead *.fln set filetype=flor
" Quit when a (custom) syntax file is already loaded
if exists("b:current_syntax")
finish
endif
syn match florSpecial ";"
syn match florSpecial "|"
syn match florSpecial "\\"
syn match florSpecial "\v\s_"
syn match florSpecial /\v,[\n\r\t]*$/
"syn match florOn /\v^\s*on\s(cancel|error|receive)\b/
"syn match florOn "on receive"
syn match florHead /^[ ]*[^ ;#\[\]{}()]\+/
syn match florHead /;\@<=[ ]*[^ ;#\[\]{}()]\+/
syn match florKey /\v\zs[^' ]+\ze[ ]*:/
syn keyword florKey if unless null
syn keyword florKex null
syn region florString start=+"+ skip=+\\"+ end=+"+
syn region florString start=+'+ skip=+\\'+ end=+'+
syn region florString start=+/+ skip=+\\/+ end=+/+
syn region florComment start="#" end="\n"
hi def link florHead Keyword
hi def link florString String
hi def link florComment Comment
hi def link florSpecial Special
hi def link florKey Keyword
hi def link florKex Special
"hi def link florOn Keyword
let b:current_syntax = "flor"