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

unmatch the syntax

Expand Messages
  • cyboman
    i m writing code that which syntax is very similar to vhdl however the code is case sensitive. i would like to be able to made some modifications to the syntax
    Message 1 of 2 , Jun 2, 2011
    • 0 Attachment
      i'm writing code that which syntax is very similar to vhdl however the
      code is case sensitive. i would like to be able to made some
      modifications to the syntax highlighting without modifying the actual
      vhdl.vim. i understood that i need to put my syntax file into .vim/
      after/syntax/vhdl.vim. however here is the issue:

      original vhdl is not case sensitive but i need to make it case
      sensitive, i.e

      syn keyword vhdlStatement register

      but i need it to be able to highlight only the lower case i.e
      something like

      syn case match
      syn keyword vhdlStatement register
      syn case ignore

      the problem is that even i use the proposed solution my vhdl still
      highlights Register because of the original vhdl definition. does
      anybody know of a way to reset the definitions in syntax files?

      any help is appreciated

      --
      You received this message from the "vim_use" maillist.
      Do not top-post! Type your reply below the text you are replying to.
      For more information, visit http://www.vim.org/maillist.php
    • Ben Fritz
      ... You cannot override the syntax rules with the after directory if you want to modify the case-sensitivity of all the matches. The easiest solution is
      Message 2 of 2 , Jun 2, 2011
      • 0 Attachment
        On Jun 2, 2:36 am, cyboman <rail.shafigu...@...> wrote:
        > i'm writing code that which syntax is very similar to vhdl however the
        > code is case sensitive. i would like to be able to made some
        > modifications to the syntax highlighting without modifying the actual
        > vhdl.vim. i understood that i need to put my syntax file into .vim/
        > after/syntax/vhdl.vim. however here is the issue:
        >
        > original vhdl is not case sensitive but i need to make it case
        > sensitive, i.e
        >
        > syn keyword vhdlStatement register
        >
        > but i need it to be able to highlight only the lower case i.e
        > something like
        >
        > syn case match
        > syn keyword vhdlStatement register
        > syn case ignore
        >
        > the problem is that even i use the proposed solution my vhdl still
        > highlights Register because of the original vhdl definition. does
        > anybody know of a way to reset the definitions in syntax files?
        >
        > any help is appreciated

        You cannot override the syntax rules with the after directory if you
        want to modify the case-sensitivity of all the matches. The easiest
        solution is probably to simply copy $VIMRUNTIME/syntax/vhdl.vim into
        $HOME/.vim/syntax/vhdl.vim and modify it there.

        --
        You received this message from the "vim_use" maillist.
        Do not top-post! Type your reply below the text you are replying to.
        For more information, visit http://www.vim.org/maillist.php
      Your message has been successfully submitted and would be delivered to recipients shortly.