comparison src/edit.c @ 18763:49b78d6465e5 v8.1.2371

patch 8.1.2371: FEAT_TEXT_PROP is a confusing name Commit: https://github.com/vim/vim/commit/05ad5ff0ab34ed9a5296dedd420ca81698b8ce22 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Nov 30 22:48:27 2019 +0100 patch 8.1.2371: FEAT_TEXT_PROP is a confusing name Problem: FEAT_TEXT_PROP is a confusing name. Solution: Use FEAT_PROP_POPUP. (Naruhiko Nishino, closes https://github.com/vim/vim/issues/5291)
author Bram Moolenaar <Bram@vim.org>
date Sat, 30 Nov 2019 23:00:05 +0100
parents 14d2a210fab1
children 3a68dc2a1bc1
comparison
equal deleted inserted replaced
18762:19582783e5ad 18763:49b78d6465e5
1415 return; 1415 return;
1416 1416
1417 /* Trigger CursorMoved if the cursor moved. Not when the popup menu is 1417 /* Trigger CursorMoved if the cursor moved. Not when the popup menu is
1418 * visible, the command might delete it. */ 1418 * visible, the command might delete it. */
1419 if (ready && (has_cursormovedI() 1419 if (ready && (has_cursormovedI()
1420 # ifdef FEAT_TEXT_PROP 1420 # ifdef FEAT_PROP_POPUP
1421 || popup_visible 1421 || popup_visible
1422 # endif 1422 # endif
1423 # if defined(FEAT_CONCEAL) 1423 # if defined(FEAT_CONCEAL)
1424 || curwin->w_p_cole > 0 1424 || curwin->w_p_cole > 0
1425 # endif 1425 # endif
1440 /* Make sure curswant is correct, an autocommand may call 1440 /* Make sure curswant is correct, an autocommand may call
1441 * getcurpos(). */ 1441 * getcurpos(). */
1442 update_curswant(); 1442 update_curswant();
1443 ins_apply_autocmds(EVENT_CURSORMOVEDI); 1443 ins_apply_autocmds(EVENT_CURSORMOVEDI);
1444 } 1444 }
1445 #ifdef FEAT_TEXT_PROP 1445 #ifdef FEAT_PROP_POPUP
1446 if (popup_visible) 1446 if (popup_visible)
1447 popup_check_cursor_pos(); 1447 popup_check_cursor_pos();
1448 #endif 1448 #endif
1449 # ifdef FEAT_CONCEAL 1449 # ifdef FEAT_CONCEAL
1450 if (curwin->w_p_cole > 0) 1450 if (curwin->w_p_cole > 0)
3773 int vcol; 3773 int vcol;
3774 3774
3775 cc = replace_pop(); 3775 cc = replace_pop();
3776 if (cc > 0) 3776 if (cc > 0)
3777 { 3777 {
3778 #ifdef FEAT_TEXT_PROP 3778 #ifdef FEAT_PROP_POPUP
3779 size_t len_before = 0; // init to shut up GCC 3779 size_t len_before = 0; // init to shut up GCC
3780 3780
3781 if (curbuf->b_has_textprop) 3781 if (curbuf->b_has_textprop)
3782 { 3782 {
3783 // Do not adjust text properties for individual delete and insert 3783 // Do not adjust text properties for individual delete and insert
3833 } 3833 }
3834 3834
3835 // mark the buffer as changed and prepare for displaying 3835 // mark the buffer as changed and prepare for displaying
3836 changed_bytes(curwin->w_cursor.lnum, curwin->w_cursor.col); 3836 changed_bytes(curwin->w_cursor.lnum, curwin->w_cursor.col);
3837 3837
3838 #ifdef FEAT_TEXT_PROP 3838 #ifdef FEAT_PROP_POPUP
3839 if (curbuf->b_has_textprop) 3839 if (curbuf->b_has_textprop)
3840 { 3840 {
3841 size_t len_now = STRLEN(ml_get_curline()); 3841 size_t len_now = STRLEN(ml_get_curline());
3842 3842
3843 --text_prop_frozen; 3843 --text_prop_frozen;
4805 if (vcol >= start_vcol) 4805 if (vcol >= start_vcol)
4806 ins_bs_one(&vcol); 4806 ins_bs_one(&vcol);
4807 } 4807 }
4808 4808
4809 /* 4809 /*
4810 * Delete upto starting point, start of line or previous word. 4810 * Delete up to starting point, start of line or previous word.
4811 */ 4811 */
4812 else 4812 else
4813 { 4813 {
4814 int cclass = 0, prev_cclass = 0; 4814 int cclass = 0, prev_cclass = 0;
4815 4815
5607 STRMOVE(ptr, ptr + i); 5607 STRMOVE(ptr, ptr + i);
5608 /* correct replace stack. */ 5608 /* correct replace stack. */
5609 if ((State & REPLACE_FLAG) && !(State & VREPLACE_FLAG)) 5609 if ((State & REPLACE_FLAG) && !(State & VREPLACE_FLAG))
5610 for (temp = i; --temp >= 0; ) 5610 for (temp = i; --temp >= 0; )
5611 replace_join(repl_off); 5611 replace_join(repl_off);
5612 #ifdef FEAT_TEXT_PROP 5612 #ifdef FEAT_PROP_POPUP
5613 curbuf->b_ml.ml_line_len -= i; 5613 curbuf->b_ml.ml_line_len -= i;
5614 #endif 5614 #endif
5615 } 5615 }
5616 #ifdef FEAT_NETBEANS_INTG 5616 #ifdef FEAT_NETBEANS_INTG
5617 if (netbeans_active()) 5617 if (netbeans_active())