Re: different fold markers for different file types?

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: different fold markers for different file types?

Tony Mechelynck

Felix Kater wrote:

> Hi,
>
> I've
>
> set foldmethod=marker
> set foldmarker=#if,#endif
>
> in my .vimrc file. Can I make these markers valid for c-files only and
> somewhere set other markers for txt-files?
>
> Felix

Remove these statements from your vimrc and create a file named (in Vim
terminology)

(on Linux) ~/.vim/after/ftplugin/c.vim
(on Windows) ~/vimfiles/after/ftplugin/c.vim

(create the directories too if they don't exist) with the following
single-line contents:

setlocal fdm=marker fmr=#if,#endif



See ":help after-directory"


Best regards,
Tony.
--
Save the whales.  Collect the whole set.

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