]> git.pld-linux.org Git - packages/vim.git/blob - 7.0.122
- new
[packages/vim.git] / 7.0.122
1 To: vim-dev@vim.org
2 Subject: Patch 7.0.122
3 Fcc: outbox
4 From: Bram Moolenaar <Bram@moolenaar.net>
5 Mime-Version: 1.0
6 Content-Type: text/plain; charset=ISO-8859-1
7 Content-Transfer-Encoding: 8bit
8 ------------
9
10 Patch 7.0.122
11 Problem:    GUI: When clearing after a bold, double-wide character half a
12             character may be drawn.
13 Solution:   Check for double-wide character and redraw it. (Yukihiro Nakadaira)
14 Files:      src/screen.c
15
16
17 *** ../vim-7.0.121/src/screen.c Thu Sep 14 21:04:09 2006
18 --- src/screen.c        Sat Oct  7 15:13:43 2006
19 ***************
20 *** 5079,5093 ****
21              * character too.  If we didn't skip any blanks above, then we
22              * only redraw if the character wasn't already redrawn anyway.
23              */
24 !           if (gui.in_use && (col > startCol || !redraw_this)
25 ! # ifdef FEAT_MBYTE
26 !                   && enc_dbcs == 0
27 ! # endif
28 !              )
29             {
30                 hl = ScreenAttrs[off_to];
31                 if (hl > HL_ALL || (hl & HL_BOLD))
32 !                   screen_char(off_to - 1, row, col + coloff - 1);
33             }
34   #endif
35             screen_fill(row, row + 1, col + coloff, clear_width + coloff,
36 --- 5079,5116 ----
37              * character too.  If we didn't skip any blanks above, then we
38              * only redraw if the character wasn't already redrawn anyway.
39              */
40 !           if (gui.in_use && (col > startCol || !redraw_this))
41             {
42                 hl = ScreenAttrs[off_to];
43                 if (hl > HL_ALL || (hl & HL_BOLD))
44 !               {
45 !                   int prev_cells = 1;
46 ! # ifdef FEAT_MBYTE
47 !                   if (enc_utf8)
48 !                       /* for utf-8, ScreenLines[char_offset + 1] == 0 means
49 !                        * that its width is 2. */
50 !                       prev_cells = ScreenLines[off_to - 1] == 0 ? 2 : 1;
51 !                   else if (enc_dbcs != 0)
52 !                   {
53 !                       /* find previous character by counting from first
54 !                        * column and get its width. */
55 !                       unsigned off = LineOffset[row];
56
57 !                       while (off < off_to)
58 !                       {
59 !                           prev_cells = (*mb_off2cells)(off);
60 !                           off += prev_cells;
61 !                       }
62 !                   }
63
64 !                   if (enc_dbcs != 0 && prev_cells > 1)
65 !                       screen_char_2(off_to - prev_cells, row,
66 !                                                  col + coloff - prev_cells);
67 !                   else
68 ! # endif
69 !                       screen_char(off_to - prev_cells, row,
70 !                                                  col + coloff - prev_cells);
71 !               }
72             }
73   #endif
74             screen_fill(row, row + 1, col + coloff, clear_width + coloff,
75 *** ../vim-7.0.121/src/version.c        Sun Oct  8 13:56:53 2006
76 --- src/version.c       Mon Oct  9 22:10:17 2006
77 ***************
78 *** 668,669 ****
79 --- 668,671 ----
80   {   /* Add new patch number below this line */
81 + /**/
82 +     122,
83   /**/
84
85 -- 
86 How To Keep A Healthy Level Of Insanity:
87 7. Finish all your sentences with "in accordance with the prophecy".
88
89  /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net   \\\
90 ///        sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
91 \\\        download, build and distribute -- http://www.A-A-P.org        ///
92  \\\            help me help AIDS victims -- http://ICCF-Holland.org    ///
This page took 0.03328 seconds and 3 git commands to generate.