View previous topic :: View next topic |
Author |
Message |
rzdndr Tux's lil' helper
Joined: 26 Jul 2024 Posts: 112
|
Posted: Tue Aug 06, 2024 10:46 am Post subject: Vim default configuration not loaded |
|
|
Hello
In /etc/vim/vimrc there is a section of code that is like this
Code: |
" We don't want VIM to load their own built-in defaults, preferring ours here
" instead. This option cannot apply to minimal builds, so it is guarded by a
" test that's guaranteed to fail for those, owing to the lack of +eval.
if 1
let g:skip_defaults_vim = 1
endif
|
Does anybody know why?
I have been using vim via xterm, and I could move to a position with the mouse, and use the mouse scroll button to scroll text. Currently I can not. Is there a way to use mouse scroll in vim (in xterm)?
Regards |
|
Back to top |
|
|
logrusx Advocate
Joined: 22 Feb 2018 Posts: 2464
|
Posted: Tue Aug 06, 2024 11:05 am Post subject: Re: Vim default configuration not loaded |
|
|
rzdndr wrote: |
I have been using vim via xterm, and I could move to a position with the mouse, and use the mouse scroll button to scroll text. Currently I can not. Is there a way to use mouse scroll in vim (in xterm)?
|
Strange, I can. Are you sure it's not a problem with your terminal?
Actually the scroll moves the cursor up and down for me. I'm using gnome-terminal.
Best Regards,
Georgi |
|
Back to top |
|
|
rzdndr Tux's lil' helper
Joined: 26 Jul 2024 Posts: 112
|
Posted: Tue Aug 06, 2024 11:22 am Post subject: Re: Vim default configuration not loaded |
|
|
logrusx wrote: | rzdndr wrote: |
I have been using vim via xterm, and I could move to a position with the mouse, and use the mouse scroll button to scroll text. Currently I can not. Is there a way to use mouse scroll in vim (in xterm)?
|
Strange, I can. Are you sure it's not a problem with your terminal?
Best Regards,
Georgi |
I was not sure about my terminal.
It turns out that setting termName in ~/.Xresources to xterm-256Color will set the environment variable TERM. No need to change .bashrc and put checks if you are using on the console, or in X11.
~/.Xresources: |
...
XTerm*termName: xterm-256color
...
|
And setting mouse=a in your ~/.vimrc resolves the issue.
~/.vimrc: |
...
set mouse=a
...
|
This let's you use the mouse to position the cursor, use the scroll button to scroll in the document, and select text.
Edit: Edited for a better solution
Thanks
Regards
Last edited by rzdndr on Tue Aug 06, 2024 12:06 pm; edited 2 times in total |
|
Back to top |
|
|
rzdndr Tux's lil' helper
Joined: 26 Jul 2024 Posts: 112
|
Posted: Tue Aug 06, 2024 12:03 pm Post subject: Re: Vim default configuration not loaded |
|
|
logrusx wrote: | rzdndr wrote: |
I have been using vim via xterm, and I could move to a position with the mouse, and use the mouse scroll button to scroll text. Currently I can not. Is there a way to use mouse scroll in vim (in xterm)?
|
Strange, I can. Are you sure it's not a problem with your terminal?
Actually the scroll moves the cursor up and down for me. I'm using gnome-terminal.
Best Regards,
Georgi |
I am using good old xterm. For me the document is scrolled, not the cursor. But if you scroll more than one screen the cursor does move to stay on the screen.
Regards |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|