diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-11-30 22:48:27 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-11-30 22:48:27 +0100 |
commit | 05ad5ff0ab34ed9a5296dedd420ca81698b8ce22 (patch) | |
tree | 7354d352e37ab28988ce26e4f88efd9a9b9f71ec /src | |
parent | 0c5c3faef2d54151a8c144539e3e5a3350fb18c7 (diff) |
patch 8.1.2371: FEAT_TEXT_PROP is a confusing namev8.1.2371
Problem: FEAT_TEXT_PROP is a confusing name.
Solution: Use FEAT_PROP_POPUP. (Naruhiko Nishino, closes #5291)
Diffstat (limited to 'src')
47 files changed, 190 insertions, 178 deletions
diff --git a/src/beval.c b/src/beval.c index 1bc31a17a9..63aaf1376c 100644 --- a/src/beval.c +++ b/src/beval.c @@ -10,7 +10,7 @@ #include "vim.h" -#if defined(FEAT_BEVAL) || defined(FEAT_TEXT_PROP) || defined(PROTO) +#if defined(FEAT_BEVAL) || defined(FEAT_PROP_POPUP) || defined(PROTO) /* * Find text under the mouse position "row" / "col". * If "getword" is TRUE the returned text in "*textp" is not the whole line but diff --git a/src/buffer.c b/src/buffer.c index 4868428f52..4f38f918f0 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -861,7 +861,7 @@ buf_freeall(buf_T *buf, int flags) #ifdef FEAT_SYN_HL syntax_clear(&buf->b_s); // reset syntax info #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP clear_buf_prop_types(buf); #endif buf->b_flags &= ~BF_READERR; // a read error is no longer relevant @@ -5522,7 +5522,7 @@ buf_spname(buf_T *buf) if (bt_prompt(buf)) return (char_u *)_("[Prompt]"); #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (bt_popup(buf)) return (char_u *)_("[Popup]"); #endif diff --git a/src/change.c b/src/change.c index d0462dbe1c..f2dfc9371e 100644 --- a/src/change.c +++ b/src/change.c @@ -698,7 +698,7 @@ changed_bytes(linenr_T lnum, colnr_T col) static void inserted_bytes(linenr_T lnum, colnr_T col, int added UNUSED) { -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (curbuf->b_has_textprop && added != 0) adjust_prop_columns(lnum, col, added, 0); #endif @@ -1289,7 +1289,7 @@ del_bytes( mch_memmove(newp + col, oldp + col + count, (size_t)movelen); if (alloc_newp) ml_replace(lnum, newp, FALSE); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP else { // Also move any following text properties. @@ -2075,7 +2075,7 @@ open_line( ) mark_adjust(curwin->w_cursor.lnum + 1, (linenr_T)MAXLNUM, 1L, 0L); did_append = TRUE; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if ((State & INSERT) && !(State & VREPLACE_FLAG)) // properties after the split move to the next line adjust_props_for_split(curwin->w_cursor.lnum, curwin->w_cursor.lnum, diff --git a/src/drawline.c b/src/drawline.c index 189ed80acc..95ade68b26 100644 --- a/src/drawline.c +++ b/src/drawline.c @@ -182,7 +182,7 @@ get_sign_display_info( } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP static textprop_T *current_text_props = NULL; static buf_T *current_buf = NULL; @@ -297,7 +297,7 @@ win_line( int *color_cols = NULL; // pointer to according columns array #endif int eol_hl_off = 0; // 1 if highlighted char after EOL -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP int text_prop_count; int text_prop_next = 0; // next text property to use textprop_T *text_props = NULL; @@ -752,7 +752,7 @@ win_line( area_highlighting = TRUE; } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (WIN_IS_POPUP(wp)) screen_line_flags |= SLF_POPUP; #endif @@ -924,7 +924,7 @@ win_line( } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP { char_u *prop_start; @@ -1347,7 +1347,7 @@ win_line( } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (text_props != NULL) { int pi; @@ -1472,7 +1472,7 @@ win_line( # endif } } -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP // Combine text property highlight into syntax highlight. if (text_prop_type != NULL) { @@ -3124,7 +3124,7 @@ win_line( cap_col = 0; } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP vim_free(text_props); vim_free(text_prop_idxs); #endif diff --git a/src/drawscreen.c b/src/drawscreen.c index de0fc6b974..3a88ee9794 100644 --- a/src/drawscreen.c +++ b/src/drawscreen.c @@ -149,7 +149,7 @@ update_screen(int type_arg) } updating_screen = TRUE; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Update popup_mask if needed. This may set w_redraw_top and w_redraw_bot // in some windows. may_update_popup_mask(type); @@ -335,7 +335,7 @@ update_screen(int type_arg) FOR_ALL_WINDOWS(wp) wp->w_buffer->b_mod_set = FALSE; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Display popup windows on top of the windows and command line. update_popups(win_update); #endif @@ -2476,7 +2476,7 @@ win_update(win_T *wp) wp->w_filler_rows = wp->w_height - srow; } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP else if (WIN_IS_POPUP(wp)) { // popup line that doesn't fit is left as-is @@ -2585,7 +2585,7 @@ win_update(win_T *wp) != (VALID_WCOL|VALID_WROW)) { // A win_line() call applied a fix to screen cursor column to - // accomodate concealment of cursor line, but in this call to + // accommodate concealment of cursor line, but in this call to // update_topline() the cursor's row or column got invalidated. // If they are left invalid, setcursor() will recompute them // but there won't be any further win_line() call to re-fix the @@ -2647,7 +2647,7 @@ update_prepare(void) #ifdef FEAT_SEARCH_EXTRA start_search_hl(); #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Update popup_mask if needed. may_update_popup_mask(must_redraw); #endif @@ -2763,7 +2763,7 @@ updateWindow(win_T *wp) ) win_redr_status(wp, FALSE); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Display popup windows on top of everything. update_popups(win_update); #endif diff --git a/src/edit.c b/src/edit.c index e1bf63db93..4f53333cde 100644 --- a/src/edit.c +++ b/src/edit.c @@ -1417,7 +1417,7 @@ ins_redraw(int ready) // not busy with something /* Trigger CursorMoved if the cursor moved. Not when the popup menu is * visible, the command might delete it. */ if (ready && (has_cursormovedI() -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP || popup_visible # endif # if defined(FEAT_CONCEAL) @@ -1442,7 +1442,7 @@ ins_redraw(int ready) // not busy with something update_curswant(); ins_apply_autocmds(EVENT_CURSORMOVEDI); } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (popup_visible) popup_check_cursor_pos(); #endif @@ -3775,7 +3775,7 @@ replace_do_bs(int limit_col) cc = replace_pop(); if (cc > 0) { -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP size_t len_before = 0; // init to shut up GCC if (curbuf->b_has_textprop) @@ -3835,7 +3835,7 @@ replace_do_bs(int limit_col) // mark the buffer as changed and prepare for displaying changed_bytes(curwin->w_cursor.lnum, curwin->w_cursor.col); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (curbuf->b_has_textprop) { size_t len_now = STRLEN(ml_get_curline()); @@ -4807,7 +4807,7 @@ ins_bs( } /* - * Delete upto starting point, start of line or previous word. + * Delete up to starting point, start of line or previous word. */ else { @@ -5609,7 +5609,7 @@ ins_tab(void) if ((State & REPLACE_FLAG) && !(State & VREPLACE_FLAG)) for (temp = i; --temp >= 0; ) replace_join(repl_off); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP curbuf->b_ml.ml_line_len -= i; #endif } diff --git a/src/eval.c b/src/eval.c index b65f29efca..c37d6fdc20 100644 --- a/src/eval.c +++ b/src/eval.c @@ -3890,7 +3890,7 @@ garbage_collect(int testing) if (aucmd_win != NULL) abort = abort || set_ref_in_item(&aucmd_win->w_winvar.di_tv, copyID, NULL, NULL); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP for (wp = first_popupwin; wp != NULL; wp = wp->w_next) abort = abort || set_ref_in_item(&wp->w_winvar.di_tv, copyID, NULL, NULL); @@ -3954,7 +3954,7 @@ garbage_collect(int testing) abort = abort || set_ref_in_term(copyID); #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP abort = abort || set_ref_in_popups(copyID); #endif diff --git a/src/evalbuffer.c b/src/evalbuffer.c index a82b89727e..00185b108a 100644 --- a/src/evalbuffer.c +++ b/src/evalbuffer.c @@ -565,7 +565,7 @@ get_buffer_info(buf_T *buf) dict_add_list(dict, "windows", windows); } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // List of popup windows displaying this buffer windows = list_alloc(); if (windows != NULL) diff --git a/src/evalfunc.c b/src/evalfunc.c index a071ad8b65..f6ea57c630 100644 --- a/src/evalfunc.c +++ b/src/evalfunc.c @@ -584,7 +584,7 @@ static funcentry_T global_functions[] = #ifdef FEAT_PERL {"perleval", 1, 1, FEARG_1, f_perleval}, #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP {"popup_atcursor", 2, 2, FEARG_1, f_popup_atcursor}, {"popup_beval", 2, 2, FEARG_1, f_popup_beval}, {"popup_clear", 0, 0, 0, f_popup_clear}, @@ -616,7 +616,7 @@ static funcentry_T global_functions[] = {"prompt_setinterrupt", 2, 2, FEARG_1, f_prompt_setinterrupt}, {"prompt_setprompt", 2, 2, FEARG_1, f_prompt_setprompt}, #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP {"prop_add", 3, 3, FEARG_1, f_prop_add}, {"prop_clear", 1, 3, FEARG_1, f_prop_clear}, {"prop_list", 1, 2, FEARG_1, f_prop_list}, @@ -3532,6 +3532,9 @@ f_has(typval_T *argvars, typval_T *rettv) "pythonx", # endif #endif +#ifdef FEAT_PROP_POPUP + "popupwin", +#endif #ifdef FEAT_POSTSCRIPT "postscript", #endif @@ -3608,7 +3611,7 @@ f_has(typval_T *argvars, typval_T *rettv) #ifdef FEAT_TEXTOBJ "textobjects", #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP "textprop", #endif #ifdef HAVE_TGETENT diff --git a/src/evalwindow.c b/src/evalwindow.c index 76916936dc..34d202e0ad 100644 --- a/src/evalwindow.c +++ b/src/evalwindow.c @@ -103,7 +103,7 @@ win_id2wp_tp(int id, tabpage_T **tpp) *tpp = tp; return wp; } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // popup windows are in separate lists FOR_ALL_TABPAGES(tp) for (wp = tp->tp_first_popupwin; wp != NULL; wp = wp->w_next) @@ -181,7 +181,7 @@ find_win_by_nr( } if (nr >= LOWEST_WIN_ID) { -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // check tab-local popup windows for (wp = tp->tp_first_popupwin; wp != NULL; wp = wp->w_next) if (wp->w_id == nr) @@ -199,6 +199,7 @@ find_win_by_nr( /* * Find a window: When using a Window ID in any tab page, when using a number * in the current tab page. + * Returns NULL when not found. */ win_T * find_win_by_nr_or_id(typval_T *vp) @@ -1137,7 +1138,7 @@ restore_win_noblock( curwin = save_curwin; curbuf = curwin->w_buffer; } -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP else if (WIN_IS_POPUP(curwin)) // original window was closed and now we're in a popup window: Go // to the first valid window. diff --git a/src/ex_cmds.c b/src/ex_cmds.c index 95766683c8..78f2bcc6b2 100644 --- a/src/ex_cmds.c +++ b/src/ex_cmds.c @@ -2953,7 +2953,7 @@ do_ecmd( topline = curwin->w_topline; if (!oldbuf) /* need to read the file */ { -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Don't use the swap-exists dialog for a popup window, can't edit // the buffer. if (WIN_IS_POPUP(curwin)) @@ -2972,7 +2972,7 @@ do_ecmd( (void)open_buffer(FALSE, eap, readfile_flags); #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP curbuf->b_flags &= ~BF_NO_SEA; #endif if (swap_exists_action == SEA_QUIT) @@ -3016,7 +3016,7 @@ do_ecmd( #ifdef FEAT_TITLE maketitle(); #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (WIN_IS_POPUP(curwin) && curwin->w_p_pvw && retval != FAIL) popup_set_title(curwin); #endif @@ -3900,7 +3900,7 @@ do_sub(exarg_T *eap) int do_again; /* do it again after joining lines */ int skip_match = FALSE; linenr_T sub_firstlnum; /* nr of first sub line */ -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP int apc_flags = APC_SAVE_FOR_UNDO | APC_SUBSTITUTE; colnr_T total_added = 0; #endif @@ -4317,7 +4317,7 @@ do_sub(exarg_T *eap) if (nmatch == 1) { p1 = sub_firstline; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (curbuf->b_has_textprop) { int bytes_added = sublen - 1 - (regmatch.endpos[0].col @@ -4435,7 +4435,7 @@ do_sub(exarg_T *eap) if (p1[0] == '\\' && p1[1] != NUL) /* remove backslash */ { STRMOVE(p1, p1 + 1); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (curbuf->b_has_textprop) { // When text properties are changed, need to save @@ -4464,7 +4464,7 @@ do_sub(exarg_T *eap) first_line = lnum; last_line = lnum + 1; } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP adjust_props_for_split(lnum + 1, lnum, plen, 1); #endif // all line numbers increase @@ -4993,7 +4993,7 @@ prepare_tagpreview( */ if (!curwin->w_p_pvw) { -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP if (use_previewpopup && *p_pvp != NUL) { wp = popup_find_preview_window(); @@ -5028,7 +5028,7 @@ prepare_tagpreview( /* * There is no preview window open yet. Create one. */ -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP if ((use_previewpopup && *p_pvp != NUL) || use_popup != USEPOPUP_NONE) return popup_create_preview_window(use_popup != USEPOPUP_NONE); diff --git a/src/ex_docmd.c b/src/ex_docmd.c index ed7512f769..677387f93b 100644 --- a/src/ex_docmd.c +++ b/src/ex_docmd.c @@ -368,7 +368,7 @@ static void ex_folddo(exarg_T *eap); #if !defined(FEAT_X11) || !defined(FEAT_XCLIPBOARD) # define ex_xrestore ex_ni #endif -#if !defined(FEAT_TEXT_PROP) +#if !defined(FEAT_PROP_POPUP) # define ex_popupclear ex_ni #endif @@ -5013,7 +5013,7 @@ ex_pclose(exarg_T *eap) ex_win_close(eap->forceit, win, NULL); return; } -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP // Also when 'previewpopup' is empty, it might have been cleared. popup_close_preview(); # endif @@ -7812,7 +7812,7 @@ ex_pedit(exarg_T *eap) redraw_later(VALID); win_enter(curwin_save, TRUE); } -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP else if (WIN_IS_POPUP(curwin)) { // can't keep focus in popup window diff --git a/src/feature.h b/src/feature.h index c4c276c678..d0bb78fc9f 100644 --- a/src/feature.h +++ b/src/feature.h @@ -1151,10 +1151,10 @@ #endif /* - * +textprop Text properties and popup windows + * +textprop and +popupwin Text PROPerties and POPUP windows */ #if defined(FEAT_EVAL) && defined(FEAT_SYN_HL) -# define FEAT_TEXT_PROP +# define FEAT_PROP_POPUP #endif #if defined(FEAT_SYN_HL) && defined(FEAT_RELTIME) @@ -1167,7 +1167,7 @@ * +signs Allow signs to be displayed to the left of text lines. * Adds the ":sign" command. */ -#if defined(FEAT_BIG) || defined(FEAT_NETBEANS_INTG) || defined(FEAT_TEXT_PROP) +#if defined(FEAT_BIG) || defined(FEAT_NETBEANS_INTG) || defined(FEAT_PROP_POPUP) # define FEAT_SIGNS # if ((defined(FEAT_GUI_MOTIF) || defined(FEAT_GUI_ATHENA)) \ && defined(HAVE_X11_XPM_H)) \ diff --git a/src/fileio.c b/src/fileio.c index 6f8c8f991d..802b997ac5 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -1078,7 +1078,7 @@ retry: * We allocate as much space for the file as we can get, plus * space for the old line plus room for one terminating NUL. * The amount is limited by the fact that read() only can read - * upto max_unsigned characters (and other things). + * up to max_unsigned characters (and other things). */ if (!skip_read) { @@ -3366,7 +3366,7 @@ shorten_fnames(int force) } status_redraw_all(); redraw_tabline = TRUE; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP popup_update_preview_title(); #endif } diff --git a/src/getchar.c b/src/getchar.c index a3af879991..d8d498e7d9 100644 --- a/src/getchar.c +++ b/src/getchar.c @@ -1604,7 +1604,7 @@ vgetc(void) #if defined(FEAT_XIM) && defined(FEAT_GUI_GTK) || im_is_preediting() #endif -#if defined(FEAT_TEXT_PROP) +#if defined(FEAT_PROP_POPUP) || popup_no_mapping() #endif ) @@ -1822,7 +1822,7 @@ vgetc(void) ui_remove_balloon(); } #endif -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (popup_do_filter(c)) { if (c == Ctrl_C) @@ -2038,7 +2038,7 @@ f_getchar(typval_T *argvars, typval_T *rettv) if (win == NULL) return; (void)mouse_comp_pos(win, &row, &col, &lnum, NULL); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (WIN_IS_POPUP(win)) winnr = 0; else @@ -2851,7 +2851,7 @@ vgetorpeek(int advance) /* * get a character: 2. from the typeahead buffer */ - c = typebuf.tb_buf[typebuf.tb_off] & 255; + c = typebuf.tb_buf[typebuf.tb_off]; if (advance) /* remove chars from tb_buf */ { cmd_silent = (typebuf.tb_silent > 0); diff --git a/src/globals.h b/src/globals.h index e96800db09..77a42d8ef6 100644 --- a/src/globals.h +++ b/src/globals.h @@ -95,7 +95,7 @@ EXTERN int redrawing_for_callback INIT(= 0); */ EXTERN short *TabPageIdxs INIT(= NULL); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Array with size Rows x Columns containing zindex of popups. EXTERN short *popup_mask INIT(= NULL); EXTERN short *popup_mask_next INIT(= NULL); @@ -640,7 +640,7 @@ EXTERN win_T *curwin; // currently active window EXTERN win_T *aucmd_win; // window used in aucmd_prepbuf() EXTERN int aucmd_win_used INIT(= FALSE); // aucmd_win is being used -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP EXTERN win_T *first_popupwin; // first global popup window EXTERN win_T *popup_dragwin INIT(= NULL); // popup window being dragged @@ -4898,7 +4898,7 @@ gui_mouse_moved(int x, int y) // apply 'mousefocus' and pointer shape gui_mouse_focus(x, y); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (popup_visible) // Generate a mouse-moved event, so that the popup can perhaps be // closed, just like in the terminal. @@ -5152,7 +5152,7 @@ gui_update_screen(void) /* Trigger CursorMoved if the cursor moved. */ if (!finish_op && (has_cursormoved() -# ifdef FEAT_TEXT_PROP +# ifdef FEAT_PROP_POPUP || popup_visible # endif # ifdef FEAT_CONCEAL @@ -5162,7 +5162,7 @@ gui_update_screen(void) { if (has_cursormoved()) apply_autocmds(EVENT_CURSORMOVED, NULL, NULL, FALSE, curbuf); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (popup_visible) popup_check_cursor_pos(); #endif diff --git a/src/gui_w32.c b/src/gui_w32.c index d5dfeff685..d094be6be3 100644 --- a/src/gui_w32.c +++ b/src/gui_w32.c @@ -4255,7 +4255,7 @@ _OnMouseWheel( wp = gui_mouse_window(FIND_POPUP); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (wp != NULL && popup_is_popup(wp)) { cmdarg_T cap; diff --git a/src/indent.c b/src/indent.c index 70bb81b0db..32f1e12248 100644 --- a/src/indent.c +++ b/src/indent.c @@ -773,7 +773,7 @@ set_indent( // at the start of the indent (replacing spaces with TAB) saved_cursor.col = (colnr_T)(s - newline); } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP { int added = ind_len - (colnr_T)(p - oldline); diff --git a/src/insexpand.c b/src/insexpand.c index 121e6ec52d..4f961744a5 100644 --- a/src/insexpand.c +++ b/src/insexpand.c @@ -1811,7 +1811,7 @@ ins_compl_prep(int c) || c == K_MOUSELEFT || c == K_MOUSERIGHT) return retval; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP // Ignore mouse events in a popup window if (is_mouse_key(c)) { diff --git a/src/macros.h b/src/macros.h index 72fc26af0e..ca7e4b5d0b 100644 --- a/src/macros.h +++ b/src/macros.h @@ -339,7 +339,7 @@ #define IS_USER_CMDIDX(idx) ((int)(idx) < 0) // Give an error in curwin is a popup window and evaluate to TRUE. -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP # define ERROR_IF_POPUP_WINDOW error_if_popup_window() #else # define ERROR_IF_POPUP_WINDOW 0 diff --git a/src/main.c b/src/main.c index 103c53c363..387f8370fa 100644 --- a/src/main.c +++ b/src/main.c @@ -1283,7 +1283,7 @@ main_loop( /* Trigger CursorMoved if the cursor moved. */ if (!finish_op && ( has_cursormoved() -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP || popup_visible #endif #ifdef FEAT_CONCEAL @@ -1295,7 +1295,7 @@ main_loop( if (has_cursormoved()) apply_autocmds(EVENT_CURSORMOVED, NULL, NULL, FALSE, curbuf); -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (popup_visible) popup_check_cursor_pos(); #endif diff --git a/src/memline.c b/src/memline.c index 32cbb7e526..1c24b59af7 100644 --- a/src/memline.c +++ b/src/memline.c @@ -2705,7 +2705,7 @@ ml_line_alloced(void) return (curbuf->b_ml.ml_flags & ML_LINE_DIRTY); } -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP static void add_text_props_for_append( buf_T *buf, @@ -2789,7 +2789,7 @@ ml_append_int( DATA_BL *dp; PTR_BL *pp; infoptr_T *ip; -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP char_u *tofree = NULL; #endif int ret = FAIL; @@ -2803,7 +2803,7 @@ ml_append_int( if (len == 0) len = (colnr_T)STRLEN(line) + 1; // space needed for the text -#ifdef FEAT_TEXT_PROP +#ifdef FEAT_PROP_POPUP if (curbuf->b_has_textprop && lnum & |