aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/option.c
diff options
context:
space:
mode:
authorShougo Matsushita <Shougo.Matsu@gmail.com>2020-07-11 13:13:49 +0900
committerShougo Matsushita <Shougo.Matsu@gmail.com>2020-07-23 10:29:36 +0900
commitd3eddcf630f29da72409934eb14fb7a534f6497e (patch)
tree858fe91c4a88964f3ae57d3c5afc6bba96453460 /src/nvim/option.c
parent326b87feb6179d1b36375844eab493e0bb4dbf7f (diff)
downloadrneovim-d3eddcf630f29da72409934eb14fb7a534f6497e.tar.gz
rneovim-d3eddcf630f29da72409934eb14fb7a534f6497e.tar.bz2
rneovim-d3eddcf630f29da72409934eb14fb7a534f6497e.zip
vim-patch:8.1.1564: sign column takes up space
Problem: Sign column takes up space. (Adam Stankiewicz) Solution: Optionally put signs in the number column. (Yegappan Lakshmanan, closes vim/vim#4555, closes vim/vim#4515) https://github.com/vim/vim/commit/394c5d8870b15150fc91a4c058dc571fd5eaa97e
Diffstat (limited to 'src/nvim/option.c')
-rw-r--r--src/nvim/option.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/nvim/option.c b/src/nvim/option.c
index d789ad3587..4157d28894 100644
--- a/src/nvim/option.c
+++ b/src/nvim/option.c
@@ -314,7 +314,7 @@ static char *(p_icm_values[]) = { "nosplit", "split", NULL };
static char *(p_scl_values[]) = { "yes", "no", "auto", "auto:1", "auto:2",
"auto:3", "auto:4", "auto:5", "auto:6", "auto:7", "auto:8", "auto:9",
"yes:1", "yes:2", "yes:3", "yes:4", "yes:5", "yes:6", "yes:7", "yes:8",
- "yes:9", NULL };
+ "yes:9", "number", NULL };
static char *(p_fdc_values[]) = { "auto:1", "auto:2",
"auto:3", "auto:4", "auto:5", "auto:6", "auto:7", "auto:8", "auto:9",
"0", "1", "2", "3", "4", "5", "6", "7", "8", "9", NULL };
@@ -7397,7 +7397,9 @@ int win_signcol_count(win_T *wp)
int maximum = 1, needed_signcols;
const char *scl = (const char *)wp->w_p_scl;
- if (*scl == 'n') {
+ if (*scl == 'n'
+ && (*(scl + 1) == 'o' || (*(scl + 1) == 'u'
+ && (wp->w_p_nu || wp->w_p_rnu)))) {
return 0;
}
needed_signcols = buf_signcols(wp->w_buffer);