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

68424Re: Bug with matchadd() highlighting?

Expand Messages
  • Christian Brabandt
    Feb 22, 2013
    • 0 Attachment
      Hi John!

      On Fr, 22 Feb 2013, John Szakmeister wrote:

      > I've been using Syntastic lately, and I noticed an interesting quirk.
      > Syntastic will highlight the location of the error in your buffer by
      > calling matchadd() providing the line and column number to highlight
      > in the pattern. What I noticed is that if I start editing the file
      > above the error location, then hit enter a couple of times, then Vim
      > would not only highlight the new location of the line, but the old one
      > as well.
      >
      > After spending some time chasing it down, I believe it may be a Vim
      > bug. Here are the steps to reproduce it:
      >
      > cat > file.txt <<HERE
      > line a
      > line b
      > line c
      > line d
      > HERE
      >
      > # set colorscheme however you like, just as long as there
      > # is an 'Error' highlight group.
      > vim -u NONE -U NONE -c 'set nocp' -c 'colorscheme elflord' file.txt \
      > -c "call matchadd('Error', '\%3l\%1c')"

      Looks like a redrawing problem. I think, the screen is not correctly
      updated, but when doing Ctrl-L it does instead update correctly.


      Mit freundlichen Grüßen
      Christian
      --
      In jedem großen Problem steckt ein kleines, das gerne raus möchte.
      In jedem kleinen Problem steckt ein großes, das gerne raus möchte.

      --
      --
      You received this message from the "vim_dev" 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

      ---
      You received this message because you are subscribed to the Google Groups "vim_dev" group.
      To unsubscribe from this group and stop receiving emails from it, send an email to vim_dev+unsubscribe@....
      For more options, visit https://groups.google.com/groups/opt_out.
    • Show all 6 messages in this topic