From 971c7e5d25ee79bac7c5a857f0faa08f3e690080 Mon Sep 17 00:00:00 2001 From: Alison Watson Date: Mon, 6 Jan 2020 08:47:57 -0500 Subject: [PATCH] vim: make listchars customizable and make defaults ascii --- computers/rain/vconf | 21 +++++++++++++++ vim/vimrc | 62 +++++++++++++++++++++++++++----------------- 2 files changed, 59 insertions(+), 24 deletions(-) diff --git a/computers/rain/vconf b/computers/rain/vconf index c549785..6003d19 100644 --- a/computers/rain/vconf +++ b/computers/rain/vconf @@ -26,4 +26,25 @@ let _agw.colors=[ \ 'base16-unikitty-dark', \] +let _agw.mode_map.nov='n→' +let _agw.mode_map.noV='n↓' +let _agw.mode_map['no']='n↔' +let _agw.mode_map.niI='←i' +let _agw.mode_map.niR='←R' +let _agw.mode_map.niV='←v' +let _agw.mode_map.v='v→' +let _agw.mode_map.V='v↓' +let _agw.mode_map['']='v↔' +let _agw.mode_map.s='s→' +let _agw.mode_map.S='s↓' +let _agw.mode_map['']='s↔' +let _agw.mode_map.ic='↗c' +let _agw.mode_map.ix='↗x' +let _agw.mode_map.Rc='↗r' +let _agw.mode_map.Rx='↗X' + +let _agw.listc.s="·" +let _agw.listc.r="‼" +let _agw.listc.l="¶" + " EOF diff --git a/vim/vimrc b/vim/vimrc index df0d80f..981ac86 100644 --- a/vim/vimrc +++ b/vim/vimrc @@ -2,36 +2,45 @@ let _agw={} -let _agw.mode_map = { +let _agw.mode_map={ \ 'n' : '~ ', \ 'no' : 'n ', -\ 'nov' : 'n→', -\ 'noV' : 'n↓', -\ 'no' : 'n↔', -\ 'niI' : '←i', -\ 'niR' : '←R', -\ 'niV' : '←v', -\ 'v' : 'v→', -\ 'V' : 'v↓', -\ '' : 'v↔', -\ 's' : 's→', -\ 'S' : 's↓', -\ '' : 's↔', +\ 'nov' : 'n>', +\ 'noV' : 'n_', +\ 'no' : 'n-', +\ 'niI' : '', +\ 'V' : 'v_', +\ '' : 'v-', +\ 's' : 's>', +\ 'S' : 's_', +\ '' : 's-', \ 'i' : 'i ', -\ 'ic' : '↗c', -\ 'ix' : '↗x', +\ 'ic' : '^c', +\ 'ix' : '^x', \ 'R' : 'R ', -\ 'Rc' : '↗r', +\ 'Rc' : '^r', \ 'Rv' : "R'", -\ 'Rx' : '↗X', +\ 'Rx' : '^X', \ 'c' : '% ', \ 'cv' : ":'", \ 'ce' : ': ', -\ 'r' : '↲ ', -\ 'rm' : '⎬ ', -\ 'r?' : "↲'", -\ '!' : '… ', -\ 't' : '…!', +\ 'r' : '] ', +\ 'rm' : '| ', +\ 'r?' : "]'", +\ '!' : '. ', +\ 't' : '.!', +\} + +let _agw.listc={ +\ 't': "|-", +\ 's': ".", +\ 'r': "!", +\ 'e': ">", +\ 'p': "<", +\ 'l': "/", \} let _agw.languages=[ @@ -223,10 +232,15 @@ set belloff=all if _agw.use_list >= 1 set list - set listchars=tab:├─,space:·,trail:‼,extends:≫,precedes:≪ + let &listchars= + \ "tab:".._agw.listc.t.. + \ ",space:".._agw.listc.s.. + \ ",trail:".._agw.listc.r.. + \ ",extends:".._agw.listc.e.. + \ ",precedes:".._agw.listc.p if _agw.use_list >= 2 - set listchars+=eol:¶ + let &listchars..="eol:".._agw.listc.l endif endif