Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scrolloff in terminal #171

Closed
archy-co opened this issue May 19, 2021 · 4 comments
Closed

Scrolloff in terminal #171

archy-co opened this issue May 19, 2021 · 4 comments

Comments

@archy-co
Copy link

If scrolloff is set to terminal buffer, exiting Terminal mode and switching to Normal mode, displays extra top line. Switching back to Terminal mode hides that line. It is quite useless and may bother.
Furthermore, it brakes neovim terminal: first line is shaking (displaying last line before clear) as you type

Steps to reproduce:

  1. Create a split terminal window and run a command with long output (so that output is longer that terminal split height). Then clear screen
  2. Continue typing to see top line shaking in neovim. Exit Terminal mode to show useless last line. Re-enter Terminal mode to continue typing from the first line without that extra top line (still shakes in neovim).
@tpope
Copy link
Owner

tpope commented Dec 26, 2022

Neovim 0.5.0, the oldest version I have convenient access to, does not appear to have the line shaking issue. Guessing it was fixed upstream? Neovim 0.4 is basically a historical artifact at this point so I think I'm okay to write that off.

As for the rest, it is an unexpected consequence of setting 'scrolloff', but I'm not sure that makes it wrong? Vim itself sets scrolloff=5 in defautls.vim, and has done so for years. And I can't find the slightest bit of pushback in the Vim issue tracker, I think I am okay to leave this be.

@mentalisttraceur
Copy link

mentalisttraceur commented Mar 27, 2023

For what it's worth:

Neovim 0.4 is basically a historical artifact at this point

Currently Debian Stable has Neovim 0.4.4.

I can't find the slightest bit of pushback in the Vim issue tracker

Why would most people bother pushing back?

I started on BusyBox' vi which doesn't have this scrolloff default, and every time I tried vim the scrolloff default annoyed me.

But I just tried to get used to it, or changed it, or went back to my more minimal vi. (And when I started using Neovim instead, I was happy that it didn't have this default.)

When I see a default that I don't like, I usually suppose enough people like it or that it's been there for a while - I'm usually not going to go "your defaults are bad (according to my tastes/expectations/uses/ideas) so you should change them for everyone" unless there's good reason that's not too subjective or relative.

@tpope
Copy link
Owner

tpope commented Mar 27, 2023

For what it's worth:

Neovim 0.4 is basically a historical artifact at this point

Currently Debian Stable has Neovim 0.4.4.

I do have a Debian machine, which actually gives me a way to test this. And I can't reproduce. I do see a bit of jankiness around the top line, but nothing so severe as the first line shaking while typing. If anything this reassures me I made the right call.

@tpope tpope closed this as completed Mar 27, 2023
@mentalisttraceur
Copy link

Since I don't see the connection you've been leaving unsaid in both your comments between Neovim v0.4 and this bug, I have no idea what call you're talking about, let alone if it's the right call, but 👍 , I'm sure you're right.

I was just noting that it's not just a historical artifact yet, but might actually be in use by people, with Debian Stable being the most readily available example.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants