Mercurial > vim
comparison src/change.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 | c469e1930456 |
children | d72b30bf3a80 |
comparison
equal
deleted
inserted
replaced
18762:19582783e5ad | 18763:49b78d6465e5 |
---|---|
696 * When "added" is negative text was deleted. | 696 * When "added" is negative text was deleted. |
697 */ | 697 */ |
698 static void | 698 static void |
699 inserted_bytes(linenr_T lnum, colnr_T col, int added UNUSED) | 699 inserted_bytes(linenr_T lnum, colnr_T col, int added UNUSED) |
700 { | 700 { |
701 #ifdef FEAT_TEXT_PROP | 701 #ifdef FEAT_PROP_POPUP |
702 if (curbuf->b_has_textprop && added != 0) | 702 if (curbuf->b_has_textprop && added != 0) |
703 adjust_prop_columns(lnum, col, added, 0); | 703 adjust_prop_columns(lnum, col, added, 0); |
704 #endif | 704 #endif |
705 | 705 |
706 changed_bytes(lnum, col); | 706 changed_bytes(lnum, col); |
1287 mch_memmove(newp, oldp, (size_t)col); | 1287 mch_memmove(newp, oldp, (size_t)col); |
1288 } | 1288 } |
1289 mch_memmove(newp + col, oldp + col + count, (size_t)movelen); | 1289 mch_memmove(newp + col, oldp + col + count, (size_t)movelen); |
1290 if (alloc_newp) | 1290 if (alloc_newp) |
1291 ml_replace(lnum, newp, FALSE); | 1291 ml_replace(lnum, newp, FALSE); |
1292 #ifdef FEAT_TEXT_PROP | 1292 #ifdef FEAT_PROP_POPUP |
1293 else | 1293 else |
1294 { | 1294 { |
1295 // Also move any following text properties. | 1295 // Also move any following text properties. |
1296 if (oldlen + 1 < curbuf->b_ml.ml_line_len) | 1296 if (oldlen + 1 < curbuf->b_ml.ml_line_len) |
1297 mch_memmove(newp + newlen + 1, oldp + oldlen + 1, | 1297 mch_memmove(newp + newlen + 1, oldp + oldlen + 1, |
2073 || curwin->w_p_diff | 2073 || curwin->w_p_diff |
2074 #endif | 2074 #endif |
2075 ) | 2075 ) |
2076 mark_adjust(curwin->w_cursor.lnum + 1, (linenr_T)MAXLNUM, 1L, 0L); | 2076 mark_adjust(curwin->w_cursor.lnum + 1, (linenr_T)MAXLNUM, 1L, 0L); |
2077 did_append = TRUE; | 2077 did_append = TRUE; |
2078 #ifdef FEAT_TEXT_PROP | 2078 #ifdef FEAT_PROP_POPUP |
2079 if ((State & INSERT) && !(State & VREPLACE_FLAG)) | 2079 if ((State & INSERT) && !(State & VREPLACE_FLAG)) |
2080 // properties after the split move to the next line | 2080 // properties after the split move to the next line |
2081 adjust_props_for_split(curwin->w_cursor.lnum, curwin->w_cursor.lnum, | 2081 adjust_props_for_split(curwin->w_cursor.lnum, curwin->w_cursor.lnum, |
2082 curwin->w_cursor.col + 1, 0); | 2082 curwin->w_cursor.col + 1, 0); |
2083 #endif | 2083 #endif |