mirror of
https://github.com/Green-Sky/crdt_tests.git
synced 2024-11-13 01:33:03 +01:00
vim notes
This commit is contained in:
parent
808583873a
commit
cf91dfb61e
26
vim_research/notes.txt
Normal file
26
vim_research/notes.txt
Normal file
@ -0,0 +1,26 @@
|
||||
|
||||
adding an event listener to local buffer:
|
||||
:au CursorHold <buffer> echo 'hold'
|
||||
|
||||
event groups:
|
||||
:augroup uncompress
|
||||
: au!
|
||||
: au BufEnter *.gz %!gunzip
|
||||
:augroup END
|
||||
|
||||
|
||||
:au TextChanged <buffer> call ch_sendexpr(channel, 'changed')
|
||||
:au TextChangedI <buffer> call ch_sendexpr(channel, 'changed_i')
|
||||
|
||||
":au TextChanged <buffer> call ch_sendexpr(channel, ['changed', 'x': col('.'), 'y': line('.')])
|
||||
:au TextChanged <buffer> call ch_sendexpr(channel, ['changed', getpos('.')])
|
||||
:au TextChangedI <buffer> call ch_sendexpr(channel, 'changed_i')
|
||||
|
||||
|
||||
pseudocode for TextChanged diffing:
|
||||
|
||||
" not enough, maybe marks?
|
||||
start_pos = min(last_pos, now_pos)
|
||||
end_pos = max(last_pos, now_pos)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user