Ben Fritz schrieb:
> 
[snip]
>> Something like that. Opening vim with N files results in N-1 correctly
>> displayed tabs plus one always ends up completely blank. I'd blame my
>> own ignorance if it weren't for the fact that if I comment out the
>> tabdo-line, open the files and then manually run "tabdo call Test()"
>> from within vim, it all works as expected.
>>
> 
> Since it works if you load each file manually then call the tabdo, I
> suspect Vim doesn't like doing all this during startup (though I don't
> know the reason).
> 
> Try this minor modification and see if it works better:
> 
>         tab all
>         map <Tab> :tabn<cr>
>         map <S-Tab> :tabp<cr>
> 
>         set autochdir
> 
>         function Test()
>                 30 vsplit
>                 set nonu
>                 VTreeExplore
>         endfunction
> 
>         autocmd VimEnter * tabdo call Test()
> 
> This way you don't try to run your function until after Vim is all
> done with initialization. In addition, you don't need to source the
> plugin in your .vimrc, Vim can just do it normally.
> --~--~---------~--~----~------------~-------~--~----~

Thanks a bunch, Ben! Worked like a charm :)

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to