| To: vim_dev@googlegroups.com |
| Subject: Patch 7.4.187 |
| Fcc: outbox |
| From: Bram Moolenaar <Bram@moolenaar.net> |
| Mime-Version: 1.0 |
| Content-Type: text/plain; charset=UTF-8 |
| Content-Transfer-Encoding: 8bit |
| |
| |
| Patch 7.4.187 |
| Problem: Delete that crosses line break splits multi-byte character. |
| Solution: Advance a character instead of a byte. (Cade Foster) |
| Files: src/normal.c, src/testdir/test69.in, src/testdir/test69.ok |
| |
| |
| |
| |
| |
| *** 21,27 **** |
| static int resel_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ |
| static linenr_T resel_VIsual_line_count; /* number of lines */ |
| static colnr_T resel_VIsual_vcol; /* nr of cols or end col */ |
| ! static int VIsual_mode_orig = NUL; /* type of Visual mode, that user entered */ |
| |
| static int restart_VIsual_select = 0; |
| #endif |
| --- 21,27 ---- |
| static int resel_VIsual_mode = NUL; /* 'v', 'V', or Ctrl-V */ |
| static linenr_T resel_VIsual_line_count; /* number of lines */ |
| static colnr_T resel_VIsual_vcol; /* nr of cols or end col */ |
| ! static int VIsual_mode_orig = NUL; /* saved Visual mode */ |
| |
| static int restart_VIsual_select = 0; |
| #endif |
| |
| *** 6202,6209 **** |
| || cap->oap->op_type == OP_CHANGE) |
| && !lineempty(curwin->w_cursor.lnum)) |
| { |
| ! if (*ml_get_cursor() != NUL) |
| ! ++curwin->w_cursor.col; |
| cap->retval |= CA_NO_ADJ_OP_END; |
| } |
| continue; |
| --- 6202,6218 ---- |
| || cap->oap->op_type == OP_CHANGE) |
| && !lineempty(curwin->w_cursor.lnum)) |
| { |
| ! char_u *cp = ml_get_cursor(); |
| ! |
| ! if (*cp != NUL) |
| ! { |
| ! #ifdef FEAT_MBYTE |
| ! if (has_mbyte) |
| ! curwin->w_cursor.col += (*mb_ptr2len)(cp); |
| ! else |
| ! #endif |
| ! ++curwin->w_cursor.col; |
| ! } |
| cap->retval |= CA_NO_ADJ_OP_END; |
| } |
| continue; |
| |
| *** 9482,9488 **** |
| # ifdef FEAT_CLIPBOARD |
| adjust_clip_reg(®name); |
| # endif |
| ! if (regname == 0 || regname == '"' |
| || VIM_ISDIGIT(regname) || regname == '-' |
| # ifdef FEAT_CLIPBOARD |
| || (clip_unnamed && (regname == '*' || regname == '+')) |
| --- 9491,9497 ---- |
| # ifdef FEAT_CLIPBOARD |
| adjust_clip_reg(®name); |
| # endif |
| ! if (regname == 0 || regname == '"' |
| || VIM_ISDIGIT(regname) || regname == '-' |
| # ifdef FEAT_CLIPBOARD |
| || (clip_unnamed && (regname == '*' || regname == '+')) |
| |
| |
| |
| *** 155,160 **** |
| --- 155,170 ---- |
| aab |
| |
| STARTTEST |
| + :set whichwrap+=h |
| + /^x |
| + dh |
| + :set whichwrap-=h |
| + ENDTEST |
| + |
| + á |
| + x |
| + |
| + STARTTEST |
| :let a = '.é.' " one char of two bytes |
| :let b = '.é.' " normal e with composing char |
| /^byteidx |
| |
| |
| |
| *** 150,155 **** |
| --- 150,158 ---- |
| aaa |
| |
| |
| + áx |
| + |
| + |
| byteidx |
| [0, 1, 3, 4, -1] |
| [0, 1, 4, 5, -1] |
| |
| |
| |
| *** 740,741 **** |
| --- 740,743 ---- |
| { /* Add new patch number below this line */ |
| + /**/ |
| + 187, |
| /**/ |
| |
| -- |
| ARTHUR: Then who is your lord? |
| WOMAN: We don't have a lord. |
| ARTHUR: What? |
| DENNIS: I told you. We're an anarcho-syndicalist commune. We take it in |
| turns to act as a sort of executive officer for the week. |
| The Quest for the Holy Grail (Monty Python) |
| |
| /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ |
| /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ |
| \\\ an exciting new programming language -- http://www.Zimbu.org /// |
| \\\ help me help AIDS victims -- http://ICCF-Holland.org /// |