国产av日韩一区二区三区精品,成人性爱视频在线观看,国产,欧美,日韩,一区,www.成色av久久成人,2222eeee成人天堂

gvim - How to keep the cursor position fixed on the screen when vim turns pages (scrolls)?
給我你的懷抱
給我你的懷抱 2017-05-16 16:36:15
0
5
1358

When turning pages (scrolling) in vim, the default cursor moves up to the top of the screen or down to the bottom of the screen. I hope to keep the position on the screen unchanged, that is, only move the text, but not the cursor (relative to screen) position.

How to achieve this? Please advise, thanks in advance!

給我你的懷抱
給我你的懷抱

reply all(5)
漂亮男人

You mean these?

ctrl + y goes up one line
ctrl + e goes down one line
ctrl + u goes up half the screen
ctrl + d goes down half the screen
ctrl + b goes up one screen
ctrl + f goes down the screen


You can check out this stackoverflow answer

http://stackoverflow.com/questions/3458689/how-to-move-screen-without-moving-cursor-in-vim

The ToggleScrollMode function below is good, I guess it should meet your needs

Ty80

If you cannot install the plug-in, you can try to turn on the relative line number display of vim, and jump quickly based on the relative line number after turning the page.

大家講道理

Added to

.vimrc

" 在上下移動(dòng)光標(biāo)時(shí),光標(biāo)的上方或下方至少會(huì)保留顯示的行數(shù)
set scrolloff=7

This 7 you set yourself

淡淡煙草味

You can zz to align the line to the center after scrolling, similar to emacs' <C-l>

迷茫

ctrl-d scrolls down half the screen, the cursor will not move

ctrl-f Scroll down one screen and the monogram will move.

shift-m moves the cursor to the middle of the screen and can be used after ctrl-f to flip the screen

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template