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

RE: c comment formatting

Expand Messages
  • Pritesh Mistry
    ... besides: 1. hope you aren t sourcing a session that overrides your settings. 2. your syntax is c/cpp 3. you have turned your syntax on. 4. or, you source
    Message 1 of 3 , Dec 29, 2000
    • 0 Attachment
      see if this helps:
      :se fo=tcqrl
      :se comments=s1:/*,mb:*,exl:*/,://,b:#,:%,:XCOMM,n:>,fb:-

      besides:
      1. hope you aren't sourcing a session that overrides your settings.
      2. your syntax is c/cpp
      3. you have turned your syntax on.
      4. or, you source your settings after you have turned on the syntax. (i
      added the comments & fo string to cpp.vim!)

      > -----Original Message-----
      > From: Yegappan Lakshmanan [mailto:yega@...]
      > Sent: Thursday, December 28, 2000 9:56 pm
      > To: J. David Boyd
      > Cc: vim@...
      > Subject: Re: c comment formatting
      >
      >
      > Hi,
      >
      > I have
      >
      > formatoptions=croq
      >
      > It is working for me. I have not changed the default value for the
      > "comments" options.
      >
      > - Yegappan
      >
      > "J. David Boyd" wrote:
      > >
      > > I've read the :help comments, and other pertinent sections,
      > and here is my
      > > quandary.
      > >
      > > It seems, from the reading the docs, that I should be able
      > to type a comment
      > > starter '/*', and then VIM will create
      > > the rest of the comment lines for me.
      > >
      > > I mean, if I type
      > >
      > > /* this
      > > * is
      > > * a comment
      > > */
      > >
      > > then VIM should automagically create the second and
      > subsequent comment
      > > markers, and fill in the last I believe, if I hit enter on
      > a blank line.
      > >
      > > I can in no way shape or form get this to work.
      > >
      > > Any ideas?
      > >
      > > I have my comments set to "sr:/*,mb:*,ex:*/", and my
      > formatoptions set to
      > > "tcqr".
      > >
      > > Dave
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.