On 5/24/06, Yakov Lerner <[EMAIL PROTECTED]> wrote:
On 5/24/06, Eric Arnold <[EMAIL PROTECTED]> wrote:
> I think 'readonly' does not belong in the .vimrc since it is a
> buffer-local-only option.

If you try to set any other buffer-local option in .vimrc,
you'll see that it works just fine.

I tried 'set tw=22' in file opened as 'vim -u file file' and
it works just fine.


True.  Don't know for sure exactly what's going on.  However, if you use:

set nocp
echomsg '1 bufnr ' . bufnr("%") . ', bufname ' . bufname( bufnr("%") )
echomsg '1 bufloaded ' . bufloaded( bufnr("%") )
edit somefile
echomsg '2 bufnr ' . bufnr("%") . ', bufname ' . bufname( bufnr("%") )
echomsg '2 bufloaded ' . bufloaded( bufnr("%") )
set tw=71
set ro


The first echomsg shows that it does indeed think that the file from
the command line is in a buffer, however,   bufloaded()  shows that it
isn't loaded.  For all I can tell, the first buffer was created by
:badd  and doesn't become loaded until .vimrc is finished (and maybe
even later).

So, there must be some difference about which options can be applied
to a buffer before it is loaded.

Reply via email to