Skip to content

Commit 9c3b3cb

Browse files
committed
don't modify lz
My config sets lazyredraw already, and I'm too lazy to fix the code properly.
1 parent 83dcfaf commit 9c3b3cb

File tree

2 files changed

+28
-28
lines changed

2 files changed

+28
-28
lines changed

autoload/DrawIt.vim

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -355,27 +355,27 @@ fun! DrawIt#DrawItStart(...)
355355
call DrawIt#SaveUserMaps("bn","",":\<c-v>","DrawIt")
356356

357357
" DrawItStart: DrawIt maps (Charles Campbell) {{{3
358-
nmap <silent> <buffer> <script> <nowait> <left> :set lz<CR>:silent! call <SID>DrawLeft()<CR>:set nolz<CR>
359-
nmap <silent> <buffer> <script> <nowait> <right> :set lz<CR>:silent! call <SID>DrawRight()<CR>:set nolz<CR>
360-
nmap <silent> <buffer> <script> <nowait> <up> :set lz<CR>:silent! call <SID>DrawUp()<CR>:set nolz<CR>
361-
nmap <silent> <buffer> <script> <nowait> <down> :set lz<CR>:silent! call <SID>DrawDown()<CR>:set nolz<CR>
362-
nmap <silent> <buffer> <script> <nowait> <s-left> :set lz<CR>:silent! call <SID>MoveLeft()<CR>:set nolz<CR>
363-
nmap <silent> <buffer> <script> <nowait> <s-right> :set lz<CR>:silent! call <SID>MoveRight()<CR>:set nolz<CR>
364-
nmap <silent> <buffer> <script> <nowait> <s-up> :set lz<CR>:silent! call <SID>MoveUp()<CR>:set nolz<CR>
365-
nmap <silent> <buffer> <script> <nowait> <s-down> :set lz<CR>:silent! call <SID>MoveDown()<CR>:set nolz<CR>
366-
nmap <silent> <buffer> <script> <nowait> <space> :set lz<CR>:silent! call <SID>DrawErase()<CR>:set nolz<CR>
367-
nmap <silent> <buffer> <script> <nowait> > :set lz<CR>:silent! call <SID>DrawSpace('>',1)<CR>:set nolz<CR>
368-
nmap <silent> <buffer> <script> <nowait> < :set lz<CR>:silent! call <SID>DrawSpace('<',2)<CR>:set nolz<CR>
369-
nmap <silent> <buffer> <script> <nowait> ^ :set lz<CR>:silent! call <SID>DrawSpace('^',3)<CR>:set nolz<CR>
370-
nmap <silent> <buffer> <script> <nowait> v :set lz<CR>:silent! call <SID>DrawSpace('v',4)<CR>:set nolz<CR>
371-
nmap <silent> <buffer> <script> <nowait> <home> :set lz<CR>:silent! call <SID>DrawSlantUpLeft()<CR>:set nolz<CR>
372-
nmap <silent> <buffer> <script> <nowait> <end> :set lz<CR>:silent! call <SID>DrawSlantDownLeft()<CR>:set nolz<CR>
373-
nmap <silent> <buffer> <script> <nowait> <pageup> :set lz<CR>:silent! call <SID>DrawSlantUpRight()<CR>:set nolz<CR>
374-
nmap <silent> <buffer> <script> <nowait> <pagedown> :set lz<CR>:silent! call <SID>DrawSlantDownRight()<CR>:set nolz<CR>
375-
nmap <silent> <buffer> <script> <nowait> <Leader>> :set lz<CR>:silent! call <SID>DrawFatRArrow()<CR>:set nolz<CR>
376-
nmap <silent> <buffer> <script> <nowait> <Leader>< :set lz<CR>:silent! call <SID>DrawFatLArrow()<CR>:set nolz<CR>
377-
nmap <silent> <buffer> <script> <nowait> <Leader>^ :set lz<CR>:silent! call <SID>DrawFatUArrow()<CR>:set nolz<CR>
378-
nmap <silent> <buffer> <script> <nowait> <Leader>v :set lz<CR>:silent! call <SID>DrawFatDArrow()<CR>:set nolz<CR>
358+
nmap <silent> <buffer> <script> <nowait> <left> :silent! call <SID>DrawLeft()<CR>
359+
nmap <silent> <buffer> <script> <nowait> <right> :silent! call <SID>DrawRight()<CR>
360+
nmap <silent> <buffer> <script> <nowait> <up> :silent! call <SID>DrawUp()<CR>
361+
nmap <silent> <buffer> <script> <nowait> <down> :silent! call <SID>DrawDown()<CR>
362+
nmap <silent> <buffer> <script> <nowait> <s-left> :silent! call <SID>MoveLeft()<CR>
363+
nmap <silent> <buffer> <script> <nowait> <s-right> :silent! call <SID>MoveRight()<CR>
364+
nmap <silent> <buffer> <script> <nowait> <s-up> :silent! call <SID>MoveUp()<CR>
365+
nmap <silent> <buffer> <script> <nowait> <s-down> :silent! call <SID>MoveDown()<CR>
366+
nmap <silent> <buffer> <script> <nowait> <space> :silent! call <SID>DrawErase()<CR>
367+
nmap <silent> <buffer> <script> <nowait> > :silent! call <SID>DrawSpace('>',1)<CR>
368+
nmap <silent> <buffer> <script> <nowait> < :silent! call <SID>DrawSpace('<',2)<CR>
369+
nmap <silent> <buffer> <script> <nowait> ^ :silent! call <SID>DrawSpace('^',3)<CR>
370+
nmap <silent> <buffer> <script> <nowait> v :silent! call <SID>DrawSpace('v',4)<CR>
371+
nmap <silent> <buffer> <script> <nowait> <home> :silent! call <SID>DrawSlantUpLeft()<CR>
372+
nmap <silent> <buffer> <script> <nowait> <end> :silent! call <SID>DrawSlantDownLeft()<CR>
373+
nmap <silent> <buffer> <script> <nowait> <pageup> :silent! call <SID>DrawSlantUpRight()<CR>
374+
nmap <silent> <buffer> <script> <nowait> <pagedown> :silent! call <SID>DrawSlantDownRight()<CR>
375+
nmap <silent> <buffer> <script> <nowait> <Leader>> :silent! call <SID>DrawFatRArrow()<CR>
376+
nmap <silent> <buffer> <script> <nowait> <Leader>< :silent! call <SID>DrawFatLArrow()<CR>
377+
nmap <silent> <buffer> <script> <nowait> <Leader>^ :silent! call <SID>DrawFatUArrow()<CR>
378+
nmap <silent> <buffer> <script> <nowait> <Leader>v :silent! call <SID>DrawFatDArrow()<CR>
379379
nmap <silent> <buffer> <script> <nowait> <Leader>f :call <SID>Flood()<cr>
380380
nmap <silent> <buffer> <script> <nowait> <Leader>g :call <SID>ToggleGrid()<cr>
381381
@@ -411,8 +411,8 @@ fun! DrawIt#DrawItStart(...)
411411
let allreg= "abcdefghijklmnopqrstuvwxyz"
412412
while strlen(allreg) > 0
413413
let ireg= strpart(allreg,0,1)
414-
exe "nmap <silent> <buffer> <nowait> <Leader>p".ireg.' :<c-u>set lz<cr>:silent! call <SID>PutBlock("'.ireg.'",0)<cr>:set nolz<cr>'
415-
exe "nmap <silent> <buffer> <nowait> <Leader>r".ireg.' :<c-u>set lz<cr>:silent! call <SID>PutBlock("'.ireg.'",1)<cr>:set nolz<cr>'
414+
exe "nmap <silent> <buffer> <nowait> <Leader>p".ireg.' :silent! call <SID>PutBlock("'.ireg.'",0)<cr>'
415+
exe "nmap <silent> <buffer> <nowait> <Leader>r".ireg.' :silent! call <SID>PutBlock("'.ireg.'",1)<cr>'
416416
let allreg= strpart(allreg,1)
417417
endwhile
418418

plugin/DrawItPlugin.vim

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,9 @@ set cpo&vim
3838
" ---------------------------------------------------------------------
3939
" Public Interface: {{{1
4040
" commands:
41-
com! -nargs=0 -bang DrawIt set lz|if <bang>0|call DrawIt#DrawItStop()|else|call DrawIt#DrawItStart()|endif|set nolz
42-
com! -nargs=? DIstart set lz|call DrawIt#DrawItStart(<q-args>)|set nolz
43-
com! -nargs=0 DIstop set lz|call DrawIt#DrawItStop()|set nolz
41+
com! -nargs=0 -bang DrawIt if <bang>0|call DrawIt#DrawItStop()|else|call DrawIt#DrawItStart()|endif
42+
com! -nargs=? DIstart call DrawIt#DrawItStart(<q-args>)
43+
com! -nargs=0 DIstop call DrawIt#DrawItStop()
4444

4545
" commands: available only when not pre-defined
4646
sil! com -nargs=0 DInrml call DrawIt#SetMode('N')
@@ -54,11 +54,11 @@ sil! com -nargs=0 DIdbl call DrawIt#SetMode('D')
5454
if !hasmapto('<Plug>DrawItStart')
5555
map <unique> <Leader>di <Plug>DrawItStart
5656
endif
57-
noremap <silent> <Plug>DrawItStart :set lz<cr>:call DrawIt#DrawItStart()<cr>:set nolz<cr>
57+
noremap <silent> <Plug>DrawItStart :call DrawIt#DrawItStart()<cr>
5858
if !hasmapto('<Plug>DrawItStop')
5959
map <unique> <Leader>ds <Plug>DrawItStop
6060
endif
61-
noremap <silent> <Plug>DrawItStop :set lz<cr>:call DrawIt#DrawItStop()<cr>:set nolz<cr>
61+
noremap <silent> <Plug>DrawItStop :call DrawIt#DrawItStop()<cr>
6262
6363
" ---------------------------------------------------------------------
6464
" DrChip Menu Support: {{{1

0 commit comments

Comments
 (0)