chrisbra / NrrwRgn

A Narrow Region Plugin for vim (like Emacs Narrow Region)
http://www.vim.org/scripts/script.php?script_id=3075
675 stars 25 forks source link

After `:wq`, the cusor didn't go back the origin window #70

Closed weaming closed 5 years ago

weaming commented 5 years ago

It go into the first window which is not expected.

chrisbra commented 5 years ago

So were did it go?

Am 16.04.2019 um 04:46 schrieb garden.yuen notifications@github.com:

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.

chrisbra commented 5 years ago

please provide a complete example and mention exactly what you expect and what happened instead. Thanks.

weaming commented 5 years ago

Steps:

  1. select text
  2. call NRV
  3. edit selected text in new split window
  4. :wq
  5. origin text replace and cursor go into the first window instead of the origin window, if exist multiple windows, cursor will go into another window, this behavior is not expected. What I expect is it go back into the window contains the origin text.
chrisbra commented 5 years ago

Well, Works for me. I cannot reproduce and you didn't say where the temp windows come from. Might be another plugin interfering. So please try to come up with a reproducible example.

weaming commented 5 years ago

There are 2 windows, one opened by the NERDTree plugin on the left, another one is the normal buffer window on the right.

Select text in buffer window, then edit in new window opened by :NRV on the top. After :wq, cursor jump into the NERDTree window...