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
Fix issue with tagbar changing the global scrolloff value. #694
Conversation
Tagbar is overwriting the global scrolloff value which can affect other windows. Change the behavior so it does a setlocal instead when needed so this only impacts the tagbar window
Co-authored-by: Caleb Maclennan <caleb@alerque.com>
looks this change did not work well, e.g |
@Shane-XB-Qian can you please elaborate? This change was to update tagbar to use |
sorry, i have no time to dig detail, but for now obviously not correct: |
@Shane-XB-Qian I think you must have not pulled in this fix. This fix specifically fixes the issue you are referring to. The |
// I got upt 13hours ago, your latest pr was 23hours ago. |
That sets the buffer local scroll off value to the previously saved value.
This is a second instance of the problem we were fixing. This PR fixed one instance, that is a different one.
The original code was saving a value, setting it to something else, doing the action, then restoring the value. The problem was the set it was doing was a global set instead of a local one, then restored it also by doing a global set instead of local. @raven42 The instance you fixed is in |
Honestly I'm not sure the purpose of this little block of code. I found this while looking at another issue and thought I'd fix it so we aren't changing the global scrolloff value. |
I've pushed up another PR (#697) that will address the other instance of this bug. I've also looked for any other instances where the scrolloff is being adjusted, and this looks like the only other place. |
…#694) Co-authored-by: Caleb Maclennan <caleb@alerque.com>
Closes #693
Tagbar is overwriting the global scrolloff value which can affect other windows. Change the behavior so it does a setlocal instead when needed so this only impacts the tagbar window