vim-patch:8.1.1076: file for Insert mode is much too big

Problem:    File for Insert mode is much too big.
Solution:   Split off the code for Insert completion. (Yegappan Lakshmanan,
            closes vim/vim#4044)
7591bb39d5

Cherry-pick ins_compl_len() -> get_compl_len() from patch 8.2.4001.

Revert a71c5e9eb9: ctrl_x_mode is no
longer a global variable, so l_ctrl_x_mode is no longer needed.
This commit is contained in:
zeertzjq
2022-07-18 08:54:53 +08:00
parent 8620dfc5bd
commit f357c9bca5
20 changed files with 3909 additions and 3783 deletions

View File

@@ -1,27 +1,9 @@
#ifndef NVIM_EDIT_H
#define NVIM_EDIT_H
#include "nvim/autocmd.h"
#include "nvim/vim.h"
/*
* Array indexes used for cptext argument of ins_compl_add().
*/
#define CPT_ABBR 0 // "abbr"
#define CPT_MENU 1 // "menu"
#define CPT_KIND 2 // "kind"
#define CPT_INFO 3 // "info"
#define CPT_COUNT 4 // Number of entries
// values for cp_flags
typedef enum {
CP_ORIGINAL_TEXT = 1, // the original text when the expansion begun
CP_FREE_FNAME = 2, // cp_fname is allocated
CP_CONT_S_IPOS = 4, // use CONT_S_IPOS for compl_cont_status
CP_EQUAL = 8, // ins_compl_equal() always returns true
CP_ICASE = 16, // ins_compl_equal ignores case
CP_FAST = 32, // use fast_breakcheck instead of os_breakcheck
} cp_flags_T;
typedef int (*IndentGetter)(void);
// Values for in_cinkeys()