Mercurial > vim
comparison src/edit.c @ 25818:37bc83bbda91 v8.2.3444
patch 8.2.3444: concealed text not revealed when leaving insert mode
Commit: https://github.com/vim/vim/commit/644b49fa0fb90143e8dbe90a7c14c9498d17b266
Author: Bram Moolenaar <Bram@vim.org>
Date: Thu Sep 16 22:32:15 2021 +0200
patch 8.2.3444: concealed text not revealed when leaving insert mode
Problem: concealed text not revealed when leaving insert mode. (Michael
Soyka)
Solution: Check if concealing changed when leaving insert mode.
(closes #8880)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Thu, 16 Sep 2021 22:45:03 +0200 |
parents | 16a7d1154be8 |
children | 45a8b2b2f652 |
comparison
equal
deleted
inserted
replaced
25817:bac65c7d2d22 | 25818:37bc83bbda91 |
---|---|
3580 int cmdchar, | 3580 int cmdchar, |
3581 int nomove) // don't move cursor | 3581 int nomove) // don't move cursor |
3582 { | 3582 { |
3583 int temp; | 3583 int temp; |
3584 static int disabled_redraw = FALSE; | 3584 static int disabled_redraw = FALSE; |
3585 #ifdef FEAT_CONCEAL | |
3586 // Remember if the cursor line was concealed before changing State. | |
3587 int cursor_line_was_concealed = curwin->w_p_cole > 0 | |
3588 && conceal_cursor_line(curwin); | |
3589 #endif | |
3585 | 3590 |
3586 #ifdef FEAT_SPELL | 3591 #ifdef FEAT_SPELL |
3587 check_spell_redraw(); | 3592 check_spell_redraw(); |
3588 #endif | 3593 #endif |
3589 | 3594 |
3699 out_str(T_BE); | 3704 out_str(T_BE); |
3700 | 3705 |
3701 // Re-enable modifyOtherKeys. | 3706 // Re-enable modifyOtherKeys. |
3702 out_str(T_CTI); | 3707 out_str(T_CTI); |
3703 } | 3708 } |
3709 #ifdef FEAT_CONCEAL | |
3710 // Check if the cursor line needs redrawing after changing State. If | |
3711 // 'concealcursor' is "i" it needs to be redrawn without concealing. | |
3712 conceal_check_cursor_line(cursor_line_was_concealed); | |
3713 #endif | |
3704 | 3714 |
3705 // When recording or for CTRL-O, need to display the new mode. | 3715 // When recording or for CTRL-O, need to display the new mode. |
3706 // Otherwise remove the mode message. | 3716 // Otherwise remove the mode message. |
3707 if (reg_recording != 0 || restart_edit != NUL) | 3717 if (reg_recording != 0 || restart_edit != NUL) |
3708 showmode(); | 3718 showmode(); |