markonm / traces.vim

Range, pattern and substitute preview for Vim
MIT License
742 stars 13 forks source link

Traces.vim breaks backspace in second column in commandline mode #22

Closed bstaletic closed 6 years ago

bstaletic commented 6 years ago

Hello,

I've found an odd behaviour which seems to be related to traces.vim.

Steps to reproduce:

Expected behaviour (<CURSOR> denotes cursor position): :<CURSOR>/foo. Actual behaviour: :/<CURSOR>foo.

The reason I believe this is caused by traces.vim is because removing it made the unexpected cursor movement go away.

markonm commented 6 years ago

That's caused by https://github.com/markonm/traces.vim/blob/master/autoload/traces.vim#L1078-L1081. Could you try removing it? If I remember correctly it was attempt to fix https://github.com/vim/vim/issues/2612 which caused faulty highlight or invisible cursor.

bstaletic commented 6 years ago

Commenting out the whole if block solved the wrong cursor move, but it did cause my cursor to get invisible, just like you mentioned.

markonm commented 6 years ago

I'll push a commit to flip movement when cursor is at the start of command line. Sadly, I cannot think of another workaround.

bstaletic commented 6 years ago

Another workaround would be just doing <Left> when at the beginning of the line. <Down> works if the user didn't attempt to scroll through commandline history.

Workarounds are annoying...

bstaletic commented 6 years ago

Thanks!

markonm commented 6 years ago

You're welcome. Thanks for reporting the issue..