On 04/11/09 00:33, steve wrote:
>
> Hi - a relatively noob de vim utters ...
>
> I have a conundrum, it's only mildly annoying but I can't solve it:
>
> scenario (A) open vim without giving a filename - type some tex markup -
> save as poot.tex - my colorscheme is applied.
>
> scenario (B) open a new file ... vim moot.tex - some weird colorscheme
> applied - wq - open again - it's in my colorscheme.
>
> I've tried set_Co=256, set background=dark in my .vimrc ... same result
>
> .html files show the same colours in (A) and (B) - I haven't tried other
> filetypes.
>
> Any ideas?
>
> Steve

I don't know TeX, but I know there are several flavours of it. Maybe 
some (or all) of them are discriminated by (part of) the file contents, 
so when you create a new file (there's nothing in it yet) you get Vim's 
"default TeX flavour", which is perhaps not the one you normally use?

Try the following, from a running Vim:

        :view moot.tex
                with a file you created before; then
        :verbose setlocal ft?

and then, with a nonexistent filename:

        :view foobar.tex
        :verbose setlocal ft?

I expect the 'filetype' value to be different, and set either by 
$VIMRUNTIME/filetype.vim or by $VIMRUNTIME/scripts.vim.

Maybe
        :help ft-tex-plugin

can help you more than I can.


Best regards,
Tony.
-- 
Quick, sing me the BUDAPEST NATIONAL ANTHEM!!

--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to