Johannes Schwarz wrote:
I just realized the :sba   or even better the  :vert sba   command.

Is it possible to hide all windows again except the active one, which
the cursor is in?

Method 1: To close all windows except the current one:

        :only

Method 2: To squash all non-current windows to their status line and nothing else:

        :set noequalalways winminheight=0 winheight=9999


And another question:
When I set the all windows to "scrollbind" and make jump to a special
line, I want each window to show that line and not the offset to the
original line.

'scrollbind' is to have several windows, which may or may not show the same file, to move up and down by the same amount. You would normally set 'scrollbind' once the windows are synchronised to corresponding lines, which may or may not be at the same position in their respective files.

One solution is to do  :windo normal gg  and then  :windo set
scrollbind   but is there an easier way?





If there is some particular data for which you can search all files to synchronise them, you can do

        :silent windo normal /pattern/
        :windo normal z.
        :windo setlocal scrollbind

or on a single line

:exe "silent windo normal /pattern/" | exe "windo normal z." | windo setlocal scrollbind

(in this last example, disregard any line breaks added by my mailer or by yours.)



Best regards,
Tony.

Reply via email to