Yggdroot / LeaderF

An efficient fuzzy finder that helps to locate files, buffers, mrus, gtags, etc. on the fly for both vim and neovim.
Apache License 2.0
2.14k stars 180 forks source link

`<C-Up>` and `<C-Down>` Keybindings Not Working in Popup Preview Window #1081

Closed Elite-zx closed 2 months ago

Elite-zx commented 2 months ago

Description:

I am experiencing an issue with the LeaderF plugin where the <C-Up> and <C-Down> keybindings do not function as expected in the popup preview window. These keybindings are intended to scroll up and down within the popup preview window, but they do not seem to have any effect.

Steps to Reproduce:

  1. Open Vim with the LeaderF plugin installed.
  2. Trigger a LeaderF command that opens a popup preview window.
  3. Attempt to use <C-Up> to scroll up in the popup preview window.
  4. Attempt to use <C-Down> to scroll down in the popup preview window.

Expected Behavior:

Actual Behavior:

cmd-up will scroll up the entire terminal cmd-Down will scroll down the entire terminal

Environment:

vimrc

"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" LeaderF
"""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""""
" popup mode
let g:Lf_PreviewInPopup = 1
let g:Lf_PreviewHorizontalPosition = 'right'
let g:Lf_WindowPosition = 'popup'
let g:Lf_StlSeparator = { 'left': "\ueb0", 'right': "\ue0b2", 'font': "Monaco Nerd Font Mono" }
let g:Lf_PreviewResult = {'File':1,'Rg':1,'Function': 0, 'BufTag': 0 }
let g:Lf_ShortcutF ='<leader>f'
let g:Lf_ShowDevIcons = 1
let g:Lf_GtagsAutoGenerate = 1
let g:Lf_Gtagslabel = 'native-pygments'
let g:Lf_MaxCount=6000000
" let g:Lf_ReverseOrder = 1

nmap <Leader>r  :Leaderf rg<CR>
nmap <Leader>g :Leaderf gtags<CR>
nmap <C-]> :Leaderf gtags --by-context --auto-jump<CR>
Yggdroot commented 2 months ago

Are these two keys occupied by your terminal? You can set them to other keybindings. let g:Lf_CommandMap = {'<C-Down>': ['<C-D>']}

You can give it a try.