nvim: Add longer yank highlight, standard toc map
Made yank highlight last 0.5s instead of 0.15s. Moved mapping to display toc for markdown and pandoc files to the vim standard mapping of gO (by default only enabled for :Man and :help). Uses :WikiFzfToc, so will only work with wiki.vim
This commit is contained in:
parent
f8371f0e73
commit
5640194504
2 changed files with 11 additions and 4 deletions
|
@ -194,7 +194,11 @@ nnoremap <leader>wF :execute(":call SearchNotes()")<cr>
|
||||||
" localleader is used when it is specific to the local file
|
" localleader is used when it is specific to the local file
|
||||||
nnoremap <leader>wf :WikiFzfPages<cr>
|
nnoremap <leader>wf :WikiFzfPages<cr>
|
||||||
nnoremap <leader>l :WikiFzfTags<cr>
|
nnoremap <leader>l :WikiFzfTags<cr>
|
||||||
nnoremap <localleader>l :WikiFzfToc<cr>
|
" use default TOC shortcut for viewing wikitoc if in correct filetype
|
||||||
|
augroup wikitoc
|
||||||
|
autocmd!
|
||||||
|
autocmd Filetype markdown,pandoc nnoremap <buffer> gO :WikiFzfToc<cr>
|
||||||
|
augroup END
|
||||||
|
|
||||||
" overwrites some default mappings I don't use, or that interfere with my own
|
" overwrites some default mappings I don't use, or that interfere with my own
|
||||||
" mappings TODO: currently this just assigns bogus shortcuts, since the plugin grumbles
|
" mappings TODO: currently this just assigns bogus shortcuts, since the plugin grumbles
|
||||||
|
@ -210,7 +214,10 @@ let g:wiki_mappings_local = {
|
||||||
\ '<plug>(wiki-graph-out)' : '<leader>wG',
|
\ '<plug>(wiki-graph-out)' : '<leader>wG',
|
||||||
\}
|
\}
|
||||||
" additional zettelkasten mapping
|
" additional zettelkasten mapping
|
||||||
au Filetype markdown,pandoc nnoremap <cr> :ZettelOpenAtCursor<cr>
|
augroup zettelkasten
|
||||||
|
autocmd!
|
||||||
|
autocmd Filetype markdown,pandoc nnoremap <cr> :ZettelOpenAtCursor<cr>
|
||||||
|
augroup END
|
||||||
|
|
||||||
" Mostly dealing with Prose writing from here on out
|
" Mostly dealing with Prose writing from here on out
|
||||||
" Format current Paragraph (esp useful in prose writing)
|
" Format current Paragraph (esp useful in prose writing)
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
" will highlight any text which has been yanked
|
" will highlight any text which has been yanked
|
||||||
augroup LuaHighlight
|
augroup LuaHighlightYank
|
||||||
autocmd!
|
autocmd!
|
||||||
autocmd TextYankPost * silent! lua require'vim.highlight'.on_yank()
|
autocmd TextYankPost * silent! lua require'vim.highlight'.on_yank{timeout=500}
|
||||||
augroup END
|
augroup END
|
||||||
|
|
Loading…
Reference in a new issue