Mercurial > vim
comparison src/gui.c @ 26771:fc859aea8cec v8.2.3914
patch 8.2.3914: various spelling mistakes in comments
Commit: https://github.com/vim/vim/commit/af4a61a85d6e8cacc35324f266934bc463a21673
Author: Dominique Pelle <dominique.pelle@gmail.com>
Date: Mon Dec 27 17:21:41 2021 +0000
patch 8.2.3914: various spelling mistakes in comments
Problem: Various spelling mistakes in comments.
Solution: Fix the mistakes. (Dominique Pell?, closes https://github.com/vim/vim/issues/9416)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Mon, 27 Dec 2021 18:30:05 +0100 |
parents | a2e6da79274d |
children | df2de1e63de0 |
comparison
equal
deleted
inserted
replaced
26770:15ff3f2e0d58 | 26771:fc859aea8cec |
---|---|
488 { | 488 { |
489 win_T *wp; | 489 win_T *wp; |
490 static int recursive = 0; | 490 static int recursive = 0; |
491 | 491 |
492 /* | 492 /* |
493 * It's possible to use ":gui" in a .gvimrc file. The first halve of this | 493 * It's possible to use ":gui" in a .gvimrc file. The first half of this |
494 * function will then be executed at the first call, the rest by the | 494 * function will then be executed at the first call, the rest by the |
495 * recursive call. This allow the shell to be opened halfway reading a | 495 * recursive call. This allow the shell to be opened halfway reading a |
496 * gvimrc file. | 496 * gvimrc file. |
497 */ | 497 */ |
498 if (!recursive) | 498 if (!recursive) |
1369 if (shape->shape != SHAPE_VER) | 1369 if (shape->shape != SHAPE_VER) |
1370 cur_width += gui.char_width; | 1370 cur_width += gui.char_width; |
1371 #ifdef FEAT_RIGHTLEFT | 1371 #ifdef FEAT_RIGHTLEFT |
1372 if (CURSOR_BAR_RIGHT) | 1372 if (CURSOR_BAR_RIGHT) |
1373 { | 1373 { |
1374 // gui.col points to the left halve of the character but | 1374 // gui.col points to the left half of the character but |
1375 // the vertical line needs to be on the right halve. | 1375 // the vertical line needs to be on the right half. |
1376 // A double-wide horizontal line is also drawn from the | 1376 // A double-wide horizontal line is also drawn from the |
1377 // right halve in gui_mch_draw_part_cursor(). | 1377 // right half in gui_mch_draw_part_cursor(). |
1378 col_off = TRUE; | 1378 col_off = TRUE; |
1379 ++gui.col; | 1379 ++gui.col; |
1380 } | 1380 } |
1381 #endif | 1381 #endif |
1382 } | 1382 } |
2186 guicolor_T bg, // colors for cursor | 2186 guicolor_T bg, // colors for cursor |
2187 int back) // backup this many chars when using bold trick | 2187 int back) // backup this many chars when using bold trick |
2188 { | 2188 { |
2189 char_u buf[MB_MAXBYTES + 1]; | 2189 char_u buf[MB_MAXBYTES + 1]; |
2190 | 2190 |
2191 // Don't draw right halve of a double-width UTF-8 char. "cannot happen" | 2191 // Don't draw right half of a double-width UTF-8 char. "cannot happen" |
2192 if (enc_utf8 && ScreenLines[off] == 0) | 2192 if (enc_utf8 && ScreenLines[off] == 0) |
2193 return OK; | 2193 return OK; |
2194 | 2194 |
2195 if (enc_utf8 && ScreenLinesUC[off] != 0) | 2195 if (enc_utf8 && ScreenLinesUC[off] != 0) |
2196 // Draw UTF-8 multi-byte character. | 2196 // Draw UTF-8 multi-byte character. |
3072 */ | 3072 */ |
3073 int | 3073 int |
3074 gui_inchar( | 3074 gui_inchar( |
3075 char_u *buf, | 3075 char_u *buf, |
3076 int maxlen, | 3076 int maxlen, |
3077 long wtime, // milli seconds | 3077 long wtime, // milliseconds |
3078 int tb_change_cnt) | 3078 int tb_change_cnt) |
3079 { | 3079 { |
3080 return gui_wait_for_chars_buf(buf, maxlen, wtime, tb_change_cnt); | 3080 return gui_wait_for_chars_buf(buf, maxlen, wtime, tb_change_cnt); |
3081 } | 3081 } |
3082 | 3082 |
3275 /* | 3275 /* |
3276 * If the mouse settings say to not use the mouse, use the modeless | 3276 * If the mouse settings say to not use the mouse, use the modeless |
3277 * selection. But if Visual is active, assume that only the Visual area | 3277 * selection. But if Visual is active, assume that only the Visual area |
3278 * will be selected. | 3278 * will be selected. |
3279 * Exception: On the command line, both the selection is used and a mouse | 3279 * Exception: On the command line, both the selection is used and a mouse |
3280 * key is send. | 3280 * key is sent. |
3281 */ | 3281 */ |
3282 if (!mouse_has(checkfor) || checkfor == MOUSE_COMMAND) | 3282 if (!mouse_has(checkfor) || checkfor == MOUSE_COMMAND) |
3283 { | 3283 { |
3284 // Don't do modeless selection in Visual mode. | 3284 // Don't do modeless selection in Visual mode. |
3285 if (checkfor != MOUSE_NONEF && VIsual_active && (State & NORMAL)) | 3285 if (checkfor != MOUSE_NONEF && VIsual_active && (State & NORMAL)) |
5374 int save_did_emsg = did_emsg; | 5374 int save_did_emsg = did_emsg; |
5375 static int busy = FALSE; | 5375 static int busy = FALSE; |
5376 | 5376 |
5377 // When the screen is being updated we should not change buffers and | 5377 // When the screen is being updated we should not change buffers and |
5378 // windows structures, it may cause freed memory to be used. Also don't | 5378 // windows structures, it may cause freed memory to be used. Also don't |
5379 // do this recursively (pressing "Find" quickly several times. | 5379 // do this recursively (pressing "Find" quickly several times). |
5380 if (updating_screen || busy) | 5380 if (updating_screen || busy) |
5381 return FALSE; | 5381 return FALSE; |
5382 | 5382 |
5383 // refuse replace when text cannot be changed | 5383 // refuse replace when text cannot be changed |
5384 if ((type == FRD_REPLACE || type == FRD_REPLACEALL) && text_locked()) | 5384 if ((type == FRD_REPLACE || type == FRD_REPLACEALL) && text_locked()) |