Loading ...
Sorry, an error occurred while loading the content.

71077Re: set textwidth=80 and c mode

Expand Messages
  • Charles E Campbell Jr
    Jul 6, 2006
      Paul Drynoff wrote:

      >On Thu, 6 Jul 2006 09:37:55 -0400
      >
      >
      >>:help filetype-plugin
      >>
      >>
      >>
      >This doesn't help.
      >I try this:
      >$ cat .vim/ftplugin/c.vim
      >set textwidth=30
      >
      >but nothing changes when I open "C file".
      >
      >Only such black magic helps:
      >vim +'set formatoptions=vt'
      >
      >I don't know why?
      >
      >

      Do you have something like
      filetype plugin indent on
      in your <.vimrc>?

      When I put
      set tw=80
      into my .vim/ftplugin/c/c.vim file, and then edited something.c,
      the textwidth was then 80 instead of 0 as it normally is.

      You can try editing something.c yourself, and then trying
      :verbose set tw?
      to find out where it was set last.

      Regards,
      Chip Campbell
    • Show all 9 messages in this topic