machakann / vim-highlightedyank

Make the yanked region apparent!
844 stars 22 forks source link

Highlight does not draw correctly in 8.0.1453 #33

Closed comradesmith closed 6 years ago

comradesmith commented 6 years ago

Hi, thanks for this plugin, it's one of my most liked plugins.

On upgrading to Vim 8.0.1453 the yanked region no longer appeared to highlight when using vim from the terminal (Terminator and tty tested), but was working as expected in gvim. Eventually I noticed the highlight would draw if I did the following:

I have tried rolling vim-highlightedyank back to before the refactor (775326f9 and 44a1ea49) without success.

What has worked is downgrading to vim 8.0.550 . I wasn't sure if this issue belongs in this repo or in vim/vim, please let me know if I should post it there.

Thanks

machakann commented 6 years ago

Hi, thank you for the report. I hasten to check vim 8.0.1453, it seems it is working correctly on my computer (windows 10, cmd.exe). Could you check whether the highlight appears with pressing CTRL-L instead of any cursor movement? I think this problem related to the difference of display update trigger, it may depend on those terminal emulators.

markonm commented 6 years ago

That's a Vim issue. Reported here: https://github.com/vim/vim/issues/2612 Introduced by this patch: https://github.com/vim/vim/commit/a338adcf222b6a24e26ea5ae6a2ad27f914acb38 Fixed by this patch: https://github.com/vim/vim/commit/acda04f5c641330cd589ca52eb61d1ab0d62385f

markonm commented 6 years ago

A possible workaround is not using https://github.com/machakann/vim-highlightedyank/commit/44a1ea49b1f58d3c701834a4b7656d95036f1a78 on Vim versions 8.0.1449 - 8.0.1476 on linux cui.

Or dummy keys via feedkeys, but that approach has a consequence of producing ugly register strings when recording macros.

machakann commented 6 years ago

@markonm Thank you!

The problem is the current Vim on Ubuntu 18.04 is 8.0.1453...

I tried to reproduce on a virtual machine but I failed. I might miss something.

machakann commented 6 years ago

I pushed a patch for this issue. Please tell me if there are any problems.

comradesmith commented 6 years ago

That seems to fix the issue perfectly thank you. Sorry I wasn't able to be more helpful.

machakann commented 6 years ago

That's good. Thank you both.