On 25/03/10 17:37, Jean Johner wrote:
Hello,
1) When you work with multiple windows and you go from one to the
other with CTRL-W w, you keep the cursor position (Nice!)

2) When you work with multiple tabs and you go from one to the other
with CTRL-PageUp, you keep the cursor position (Nice!)

3) When you work with multiple buffers (with set hidden) and go from
one to the other with :bp, you just keep the cursor line

4) When you launch gvim with multiple arguments and go from one file
to the other with :next or :prev, you just keep the cursor line

Of course you can keep the cursor postion in cases 3) and 4) with "set
nosol" but it results in keeping the column also for gg, CTRL-F, CTRL-
B ... which is not natural in my opinion.

It would be nice to keep the cursor position in cases 3) and 4) while
still going to column 1 with gg.

Best regards
Jean


Here, :next or :prev keep the latest cursor position, if known (otherwise they go to the start of the file); and I have 'startofline' set. I don't use 'hidden'.

Here are my nondefault options (the local ones are for a Vim script):

--- Global option values ---
autoindent cursorline iminsert=0 list scroll=0 syntax=help bomb foldmethod=syntax imsearch=-1 nrformats= smartindent tags=tags,./tags cursorcolumn formatoptions=tq infercase path=~/**,.,, synmaxcol=0
  fileencoding=utf-8
  keywordprg=MANPAGER=more man -a
statusline=%<%f %h%m%r%=%k[%{(&fenc == ""?&enc:&fenc).(&bomb?",BOM":"")}][U+%04B] %-12.(%l,%c%V%) %P

--- Options ---
autoindent display=lastline hlsearch list scrolloff=3 tags=tags,./tags winheight=99999 autowriteall noequalalways ignorecase maxcombine=4 showcmd textwidth=78 winminheight=0 cmdheight=2 errorbells iminsert=0 mouse=a showtabline=2 timeoutlen=5000 t_vb=^G^[|50f commentstring="%s filetype=vim imsearch=-1 mousemodel=popup smartcase ttimeoutlen=100 cscopetag foldmethod=syntax incsearch nrformats= smartindent verbose=1 cscopeverbose guiheadroom=0 infercase path=~/**,.,, splitbelow visualbell cursorcolumn helpheight=99999 nojoinspaces report=0 splitright wildcharm=^T cursorline helplang=en keymodel=startsel ruler synmaxcol=0 wildmenu delcombine history=500 laststatus=2 scroll=8 syntax=vim window=48
  backspace=indent,eol,start
  clipboard=exclude:cons\|linux
  cmdwinheight=99999
  comments=sO:" -,mO:"  ,eO:"",:"
  completeopt=menuone,preview
  cscopequickfix=s-,c-,d-,i-,t-,e-
  diffopt=filler,context:0
  fileencoding=utf-8
  fileencodings=ucs-bom,utf-8,latin1
  formatoptions=croql

guicursor=n-v-c:block-Cursor/lCursor,ve:ver35-Cursor,o:hor50-Cursor,i-ci:ver25-Cursor/lCursor,r-cr:hor20-Cursor/lCursor,sm:block-Cursor,a:blinkwait750-blinkoff750-blinkon750
  guifont=Bitstream Vera Sans Mono 8
  guioptions=gimrLTtc
  isfname=@,48-57,/,.,-,_,+,,,#,$,%,~,=,@-@
  iskeyword=@,48-57,_,192-255,#
  keywordprg=MANPAGER=more man -a
  listchars=eol:ś,tab:|_,nbsp:~
  omnifunc=syntaxcomplete#Complete
  printfont=Bitstream\ Vera Sans Mono
  printoptions=duplex:off,formfeed:y
  selectmode=key,mouse

sessionoptions=blank,buffers,folds,help,options,tabpages,winsize,sesdir,globals,localoptions
statusline=%<%f %h%m%r%=%k[%{(&fenc == ""?&enc:&fenc).(&bomb?",BOM":"")}][U+%04B] %-12.(%l,%c%V%) %P
  tabline=%!MyTabLine()
  termencoding=utf-8
  viminfo='100,<50,s10,!,%,r/media/dvdrecorder,r/mnt/floppy
  whichwrap=<,>,[,],~,b,s
  wildmode=longest:full,full
  wildoptions=tagfile

And here is the output of :version

VIM - Vi IMproved 7.2 (2008 Aug 9, compiled Mar 23 2010 18:31:42)
Included patches: 1-411
Extra patches: Extra float functions (Bill McCarthy)
Compiled by [email protected]
Huge version with GTK2-GNOME GUI.  Features included (+) or not (-):
+arabic +autocmd +balloon_eval +browse ++builtin_terms +byte_offset +cindent +clientserver +clipboard +cmdline_compl +cmdline_hist +cmdline_info +comments +cryptv +cscope +cursorshape +dialog_con_gui +diff +digraphs +dnd -ebcdic +emacs_tags +eval +ex_extra +extra_search +farsi +file_in_path +find_in_path +float +folding -footer +fork() +gettext -hangul_input +iconv +insert_expand +jumplist +keymap +langmap +libcall +linebreak +lispindent +listcmds +localmap +menu +mksession +modify_fname +mouse +mouseshape +mouse_dec +mouse_gpm -mouse_jsbterm +mouse_netterm -mouse_sysmouse +mouse_xterm +multi_byte +multi_lang -mzscheme +netbeans_intg -osfiletype +path_extra +perl +postscript +printer +profile +python +quickfix +reltime +rightleft +ruby +scrollbind +signs +smartindent -sniff +startuptime +statusline -sun_workshop +syntax +tag_binary -tag_old_static -tag_any_white +tcl +terminfo +termresponse +textobjects +title +toolbar +user_commands +vertsplit +virtualedit +visual +visualextra +viminfo +vreplace +wildignore +wildmenu +windows +writebackup +X11 -xfontset +xim +xsmp_interact
+xterm_clipboard +xterm_save
   system vimrc file: "$VIM/vimrc"
     user vimrc file: "$HOME/.vimrc"
      user exrc file: "$HOME/.exrc"
  system gvimrc file: "$VIM/gvimrc"
    user gvimrc file: "$HOME/.gvimrc"
    system menu file: "$VIMRUNTIME/menu.vim"
  fall-back for $VIM: "/usr/local/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H -DFEAT_GUI_GTK -I/usr/include/gtk-2.0 -I/usr/lib/gtk-2.0/include -I/usr/include/atk-1.0 -I/usr/include/cairo -I/usr/include/pango-1.0 -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/pixman-1 -I/usr/include/freetype2 -I/usr/include/libpng12 -DORBIT2=1 -pthread -I/usr/include/libgnomeui-2.0 -I/usr/include/libart-2.0 -I/usr/include/gconf/2 -I/usr/include/gnome-keyring-1 -I/usr/include/libgnome-2.0 -I/usr/include/libbonoboui-2.0 -I/usr/include/libgnomecanvas-2.0 -I/usr/include/gtk-2.0 -I/usr/include/gnome-vfs-2.0 -I/usr/lib/gnome-vfs-2.0/include -I/usr/include/orbit-2.0 -I/usr/include/dbus-1.0 -I/usr/lib/dbus-1.0/include -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include -I/usr/include/libbonobo-2.0 -I/usr/include/bonobo-activation-2.0 -I/usr/include/libxml2 -I/usr/include/pango-1.0 -I/usr/include/gail-1.0 -I/usr/include/freetype2 -I/usr/include/atk-1.0 -I/usr/lib/gtk-2.0/include -I/usr/include/cairo -I/usr/include/pixman-1 -I/usr/include/libpng12 -O2 -fno-strength-reduce -Wall -D_FORTIFY_SOURCE=1 -D_REENTRANT -D_GNU_SOURCE -DPERL_USE_SAFE_PUTENV -DDEBUGGING -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/lib/perl5/5.10.0/i586-linux-thread-multi/CORE -I/usr/include/python2.6 -pthread -I/usr/include -D_LARGEFILE64_SOURCE=1 -I/usr/lib/ruby/1.8/i586-linux -DRUBY_VERSION=18 Linking: gcc -L. -rdynamic -Wl,-export-dynamic -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.10.0/i586-linux-thread-multi/CORE -L. -rdynamic -Wl,-export-dynamic -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.10.0/i586-linux-thread-multi/CORE -L/usr/local/lib -o vim -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 -lgnomeui-2 -lbonoboui-2 -lgnomevfs-2 -lgnomecanvas-2 -lgnome-2 -lpopt -lbonobo-2 -lbonobo-activation -lORBit-2 -lart_lgpl_2 -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lcairo -lpango-1.0 -lfreetype -lfontconfig -lgconf-2 -lgthread-2.0 -lrt -lgmodule-2.0 -lgobject-2.0 -lglib-2.0 -lXt -lncurses -lacl -lgpm -Wl,-E -Wl,-rpath,/usr/lib/perl5/5.10.0/i586-linux-thread-multi/CORE -L/usr/lib/perl5/5.10.0/i586-linux-thread-multi/CORE -lperl -lutil -lc -L/usr/lib/python2.6/config -lpython2.6 -lutil -Xlinker -export-dynamic -L/usr/lib -ltcl8.5 -lieee -Wl,-R -Wl,/usr/lib -L/usr/lib -lruby -lm

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

To unsubscribe from this group, send email to vim_use+unsubscribegooglegroups.com or 
reply to this email with the words "REMOVE ME" as the subject.

Reply via email to