Skip to content

Commit

Permalink
binding (f10) to check treesitter highlight group
Browse files Browse the repository at this point in the history
  • Loading branch information
theniceboy committed Dec 1, 2022
1 parent 862be33 commit d3fc151
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions init.vim
Original file line number Diff line number Diff line change
Expand Up @@ -249,11 +249,11 @@ noremap \s :%s//g<left><left>
" set wrap
noremap <LEADER>sw :set wrap<CR>
" press f10 to show hlgroup
function! SynGroup()
let l:s = synID(line('.'), col('.'), 1)
echo synIDattr(l:s, 'name') . ' -> ' . synIDattr(synIDtrans(l:s), 'name')
endfun
map <F10> :call SynGroup()<CR>
" function! SynGroup()
" let l:s = synID(line('.'), col('.'), 1)
" echo synIDattr(l:s, 'name') . ' -> ' . synIDattr(synIDtrans(l:s), 'name')
" endfun
map <F10> :TSHighlightCapturesUnderCursor<CR>
" Compile function
noremap r :call CompileRunGcc()<CR>
Expand Down

0 comments on commit d3fc151

Please sign in to comment.