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

Patch 7.0.089

Expand Messages
  • Bram Moolenaar
    Patch 7.0.089 Problem: ga does not work properly for a non-Unicode multi-byte encoding. Solution: Only check for composing chars for utf-8. (Taro
    Message 1 of 3 , Sep 5, 2006
    • 0 Attachment
      Patch 7.0.089
      Problem: "ga" does not work properly for a non-Unicode multi-byte encoding.
      Solution: Only check for composing chars for utf-8. (Taro Muraoka)
      Files: src/ex_cmds.c


      *** ../vim-7.0.088/src/ex_cmds.c Tue Sep 5 16:29:38 2006
      --- src/ex_cmds.c Tue Sep 5 18:12:41 2006
      ***************
      *** 95,101 ****
      _("<%s>%s%s %d, Hex %02x, Octal %03o"),
      transchar(c), buf1, buf2, c, c, c);
      #ifdef FEAT_MBYTE
      ! c = cc[ci++];
      #endif
      }

      --- 95,104 ----
      _("<%s>%s%s %d, Hex %02x, Octal %03o"),
      transchar(c), buf1, buf2, c, c, c);
      #ifdef FEAT_MBYTE
      ! if (enc_utf8)
      ! c = cc[ci++];
      ! else
      ! c = 0;
      #endif
      }

      ***************
      *** 108,114 ****
      if (len > 0)
      IObuff[len++] = ' ';
      IObuff[len++] = '<';
      ! if (utf_iscomposing(c)
      # ifdef USE_GUI
      && !gui.in_use
      # endif
      --- 111,117 ----
      if (len > 0)
      IObuff[len++] = ' ';
      IObuff[len++] = '<';
      ! if (enc_utf8 && utf_iscomposing(c)
      # ifdef USE_GUI
      && !gui.in_use
      # endif
      ***************
      *** 120,126 ****
      : _("> %d, Hex %08x, Octal %o"), c, c, c);
      if (ci == MAX_MCO)
      break;
      ! c = cc[ci++];
      }
      #endif

      --- 123,132 ----
      : _("> %d, Hex %08x, Octal %o"), c, c, c);
      if (ci == MAX_MCO)
      break;
      ! if (enc_utf8)
      ! c = cc[ci++];
      ! else
      ! c = 0;
      }
      #endif

      *** ../vim-7.0.088/src/version.c Tue Sep 5 17:30:25 2006
      --- src/version.c Tue Sep 5 18:19:42 2006
      ***************
      *** 668,669 ****
      --- 668,671 ----
      { /* Add new patch number below this line */
      + /**/
      + 89,
      /**/

      --
      [clop clop]
      GUARD #1: Halt! Who goes there?
      ARTHUR: It is I, Arthur, son of Uther Pendragon, from the castle of
      Camelot. King of the Britons, defeator of the Saxons, sovereign of
      all England!
      GUARD #1: Pull the other one!
      The Quest for the Holy Grail (Monty Python)

      /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
      /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
      \\\ download, build and distribute -- http://www.A-A-P.org ///
      \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
    • A.J.Mechelynck
      ... Will this still work for non-Unicode charsets with composing chars, such as Arabic and Hebrew? And maybe Devanagari, but I m less sure about that (I don t
      Message 2 of 3 , Sep 5, 2006
      • 0 Attachment
        Bram Moolenaar wrote:
        > Patch 7.0.089
        > Problem: "ga" does not work properly for a non-Unicode multi-byte encoding.
        > Solution: Only check for composing chars for utf-8. (Taro Muraoka)
        > Files: src/ex_cmds.c


        Will this still work for non-Unicode charsets with composing chars, such
        as Arabic and Hebrew? And maybe Devanagari, but I'm less sure about that
        (I don't even know if Vim supports it)?

        BTW, even in CJK a few composing chars are defined (e.g.
        hiragana/katakana voiced and semivoiced modifiers, or ideographic tone
        marks); I don't know which non-Unicode charsets support them though.


        Best regards,
        Tony.
      • Bram Moolenaar
        ... Vim has never supported composing characters on anything but Unicode. And it s very unlikely that the support will be added, now that switching to Unicode
        Message 3 of 3 , Sep 5, 2006
        • 0 Attachment
          Tony Mechelynck wrote:

          > Bram Moolenaar wrote:
          > > Patch 7.0.089
          > > Problem: "ga" does not work properly for a non-Unicode multi-byte encoding.
          > > Solution: Only check for composing chars for utf-8. (Taro Muraoka)
          > > Files: src/ex_cmds.c
          >
          >
          > Will this still work for non-Unicode charsets with composing chars, such
          > as Arabic and Hebrew? And maybe Devanagari, but I'm less sure about that
          > (I don't even know if Vim supports it)?
          >
          > BTW, even in CJK a few composing chars are defined (e.g.
          > hiragana/katakana voiced and semivoiced modifiers, or ideographic tone
          > marks); I don't know which non-Unicode charsets support them though.

          Vim has never supported composing characters on anything but Unicode.
          And it's very unlikely that the support will be added, now that
          switching to Unicode is the best solution.

          --
          Nothing is impossible for the man who doesn't have to do it.

          /// Bram Moolenaar -- Bram@... -- http://www.Moolenaar.net \\\
          /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
          \\\ download, build and distribute -- http://www.A-A-P.org ///
          \\\ help me help AIDS victims -- http://ICCF-Holland.org ///
        Your message has been successfully submitted and would be delivered to recipients shortly.