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

631Re: clear_next don't work correctly.

Expand Messages
  • Bram Moolenaar
    Apr 17, 2002
      Yasuhiro Matsumoto wrote:

      > clear_next_cell don't work correctly.
      > on some case, following text will be erased.
      > this happend with text included underline.
      > old text:
      > [][][]
      > new text:(override)
      > [][][]
      > |
      > v
      > []
      > ~~ <= underline
      > following patch will be fix this.
      > this patch made by AIDA Shinra.

      I don't see how this can go wrong, unless the mb_off2cells() call gives
      a wrong result. I guess that might happen when it's called with an
      offset that points to the right halve of a double-wide character. At
      least for DBCS characters this does not appear to be checked and an
      invalid result might be returned.

      I think we should attempt to fix the cause of the problem and not work
      around it. mb_off2cells() appears to be used in several places where we
      don't know if we are looking at a single-byte character, the head byte
      or the tail byte of a double-byte character. Can this be fixed?

      hundred-and-one symptoms of being an internet addict:
      220. Your wife asks for sex and you tell her where to find you on IRC.

      /// Bram Moolenaar -- Bram@... -- http://www.moolenaar.net \\\
      /// Creator of Vim -- http://vim.sf.net -- ftp://ftp.vim.org/pub/vim \\\
      \\\ Project leader for A-A-P -- http://www.a-a-p.org ///
      \\\ Help me helping AIDS orphans in Uganda - http://iccf-holland.org ///
    • Show all 10 messages in this topic