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

syntax highlighting for ASCII docs ?

Expand Messages
  • RAMMING Thomas
    Hi, 1) Syntax match for underlined headlines I m trying to define a syntax color definition file for ASCII text files. I managed to tell VIM to match strings
    Message 1 of 5 , Apr 18, 2001
      Hi,

      1) Syntax match for underlined headlines
      I'm trying to define a syntax color definition file for ASCII text files. I
      managed to tell VIM
      to match strings in single, double quotes and in single or double angles
      ('<','>') and display them
      in default String format.

      How can I tell VIM to recognize an underlined headline
      and display both lines in another color or font ?

      e.g.:
      "
      Sample underlined headline level1 < headline_format_L1
      ================================= < headline_format_L1
      some text < no formatting
      Sample underlined headline level2 < headline_format_L2
      --------------------------------- < headline_format_L2
      some more text < no formatting
      "

      2) syntax match for keywords starting with '@'
      Another problem still pending is to tell vim to recognize special keywords
      (in comments of C/C++ files)
      starting with '@' and display them in a special format.
      e.g.
      /*@PROC procname*/
      ^^^^^

      3) magic in path is not expanded
      For include and file search ('find xy.h') I extended the internal path
      variable with '../*'
      to tell VIM to search xy.h in all parallel directories. Well, VIM ignores
      it, I had to give him each directory by explicit name, but that's not really
      a big help for actualization has to be made in each directory i invoke VIM.
      Is there no way to use magic in path variable ?

      Thanks for any helpful suggestions !

      Besides, I'm using GVIM on Windows NT (nag, nag, nag) and I'm really happy
      with GVIM.

      Thomas
      ----------------------------------------------------------------------------
      --
      Grundig AG
      HiFi-Software Development

      Thomas Ramming
      Beuthener Straße 41
      D-90471 Nürnberg
      Germany

      Phone: +49 (0) 911 / 703-7577
      FAX: +49 (0) 911 / 703-965-7577
      Abteilungs-FAX : +49 (0) 911 / 703-8806
      Email: Thomas.Ramming@...
      --------------------------------------------------------------------
    • Douglas L Potts
      ... Hello! ... They re not exactly the format you are talking about, but Sven Guckes has a syntax file that hightlights *bold* and _underline_ and some others.
      Message 2 of 5 , Apr 18, 2001
        On Wed, Apr 18, 2001 at 04:46:44PM +0200 RAMMING Thomas wrote:
        > Hi,
        Hello!

        > 1) Syntax match for underlined headlines
        > I'm trying to define a syntax color definition file for ASCII text
        > files. I managed to tell VIM to match strings in single, double quotes
        > and in single or double angles ('<','>') and display them in default
        > String format.
        >
        > How can I tell VIM to recognize an underlined headline and display
        > both lines in another color or font ?
        They're not exactly the format you are talking about, but Sven Guckes
        has a syntax file that hightlights *bold* and _underline_ and some
        others. It's at:
        http://www.math.fu-berlin.de/~guckes/vim/syntax/sven.vim

        > e.g.:
        > "
        > Sample underlined headline level1 < headline_format_L1
        > ================================= < headline_format_L1
        > some text < no formatting
        > Sample underlined headline level2 < headline_format_L2
        > --------------------------------- < headline_format_L2
        > some more text < no formatting
        > "
        >
        > 2) syntax match for keywords starting with '@'
        > Another problem still pending is to tell vim to recognize special keywords
        > (in comments of C/C++ files)
        > starting with '@' and display them in a special format.
        > e.g.
        > /*@PROC procname*/
        > ^^^^^
        Ralf Schandl has a set of vim c syntax additions, and macros for doxygen
        which uses the /*@ style comments for embedding documentation. There is
        a link to his site from the doxygen home page,
        http://www.stack.nl/~dmimitri/doxygen/index.html

        > 3) magic in path is not expanded
        > For include and file search ('find xy.h') I extended the internal path
        > variable with '../*' to tell VIM to search xy.h in all parallel
        > directories. Well, VIM ignores it, I had to give him each directory by
        > explicit name, but that's not really a big help for actualization has
        > to be made in each directory i invoke VIM. Is there no way to use
        > magic in path variable ?
        Take a look at :h file-searching
        It should provide some help for this question.

        > Thanks for any helpful suggestions !
        >
        > Besides, I'm using GVIM on Windows NT (nag, nag, nag) and I'm really happy
        > with GVIM.

        HTH,
        -Doug

        --
        *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*
        Douglas L. Potts Url: http://www.bigfoot.com/~pottsdl
        "If Microsoft can change and compete on quality, I've won." -- L. Torvalds
        (L. Torvalds is the author of the famed Linux operating system)
        *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*
      • Douglas L Potts
        ... Funny, it used to be there. Well, if you would like a slightly outdated copy, I have one. Otherwise, I believe that Sven still lurks these parts ;),
        Message 3 of 5 , Apr 20, 2001
          On Fri, Apr 20, 2001 at 07:40:15AM +0200 RAMMING Thomas wrote:
          >
          >
          > > -----Ursprüngliche Nachricht-----
          > > Von: Douglas L Potts [mailto:potts.13@...]
          > > Gesendet am: Mittwoch, 18. April 2001 19:55
          > > An: 'vim@...'
          > > Betreff: Re: syntax highlighting for ASCII docs ?
          > >
          > > > How can I tell VIM to recognize an underlined headline and display
          > > > both lines in another color or font ?
          > > They're not exactly the format you are talking about, but Sven Guckes
          > > has a syntax file that hightlights *bold* and _underline_ and some
          > > others. It's at:
          > > http://www.math.fu-berlin.de/~guckes/vim/syntax/sven.vim
          >
          > Sorry, there are a lot of vim-scripts, but no sven.vim.
          Funny, it used to be there. Well, if you would like a slightly outdated
          copy, I have one. Otherwise, I believe that Sven still lurks these
          parts ;), maybe he'll shed some light.

          > > > 3) magic in path is not expanded
          > > > Is there no way to use magic in path variable ?
          > > Take a look at :h file-searching
          My boo-boo. I had Vim 6.0 open at the time I looked up help, :h path
          is the correct reference for Vim 5.7

          > Sorry, :h file-searching gives an error.
          > :h path
          > leads to information about the search path, but adding '../*'
          > does definitely not expand the '*'.
          Look a little further down, I believe that what you are looking for is
          there.

          > Thanks for your infos
          Always happy to be of service.

          -Doug

          --
          *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*
          Douglas L. Potts Url: http://www.bigfoot.com/~pottsdl
          "Those who would give up essential Liberty, to purchase a little temporary
          Safety, deserve neither Liberty nor Safety." -Benjamin Franklin
          *=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*=*
        • Erich Hoffmann
          Hello Douglas, On Wed, 18 Apr 2001, Douglas L Potts wrote ... I tried to find the file, but i didn t find it in ~guckes/vim/syntax/. Could You give me a link
          Message 4 of 5 , May 1, 2001
            Hello Douglas,

            On Wed, 18 Apr 2001, Douglas L Potts wrote

            >> How can I tell VIM to recognize an underlined headline and display

            >others. It's at:
            >http://www.math.fu-berlin.de/~guckes/vim/syntax/sven.vim
            >


            I tried to find the file, but i didn't find it in ~guckes/vim/syntax/.

            Could You give me a link to a copy of it?

            thanks,

            erich
          • Dan Sharp
            ... It looks like you can get a copy from http://www.vim.org/syntax/sven.vim instead. Dan Sharp
            Message 5 of 5 , May 1, 2001
              At 08:54 PM 5/1/2001 +0200, Erich Hoffmann wrote:
              > >> How can I tell VIM to recognize an underlined headline and display
              > >others. It's at:
              > >http://www.math.fu-berlin.de/~guckes/vim/syntax/sven.vim
              > >
              >I tried to find the file, but i didn't find it in ~guckes/vim/syntax/.
              >Could You give me a link to a copy of it?
              >thanks,
              >
              >erich

              It looks like you can get a copy from http://www.vim.org/syntax/sven.vim
              instead.

              Dan Sharp
            Your message has been successfully submitted and would be delivered to recipients shortly.