aboutsummaryrefslogtreecommitdiff
path: root/ligature_plugins/python.vim
blob: 2f9b1b6c2c9318fa26bdc5330783e1557dafb229 (plain)
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
" This is a fork of vim-cute-python
" with a few character replacements to
" play well with scientifica

" we need the conceal feature (vim ≥ 7.3)
if !has('conceal')
    finish
endif

syntax clear pythonOperator

syntax match pythonOperator "\<is\>"

syntax match pyNiceOperator "\<in\>" conceal cchar=syntax match pyNiceOperator "\<or\>" conceal cchar=syntax match pyNiceOperator "\<and\>" conceal cchar=syntax match pyNiceOperator "<=" conceal cchar=syntax match pyNiceOperator ">=" conceal cchar=syntax match pyNiceOperator "=\@<!===\@!" conceal cchar=syntax match pyNiceOperator "!=" conceal cchar=syntax keyword pyNiceOperator sum conceal cchar=syntax match pyNiceOperator "\<\%(math\.\)\?sqrt\>" conceal cchar=syntax match pyNiceKeyword "\<\%(math\.\)\?pi\>" conceal cchar=π

syntax match pyNiceOperator " \* " conceal cchar=·

syntax keyword pyNiceStatement lambda conceal cchar=λ

hi link pyNiceOperator Operator
hi link pyNiceStatement Statement
hi link pyNiceKeyword Keyword
hi! link Conceal Operator

setlocal conceallevel=1