summaryrefslogtreecommitdiff
path: root/src/misc1.c
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2017-09-22 15:20:32 +0200
committerBram Moolenaar <Bram@vim.org>2017-09-22 15:20:32 +0200
commit0263146b5dbbb6c120ce2e7720256503b864425d (patch)
treeb6f18fde8fd4bbc29c322b414ac584106e512d7a /src/misc1.c
parent53f8174eaeb93b381cf74c58863f8fe82748a22a (diff)
downloadvim-git-0263146b5dbbb6c120ce2e7720256503b864425d.tar.gz
patch 8.0.1136: W_WIDTH() is always the samev8.0.1136
Problem: W_WIDTH() is always the same. Solution: Expand the macro.
Diffstat (limited to 'src/misc1.c')
-rw-r--r--src/misc1.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/misc1.c b/src/misc1.c
index 369b716ad..f7789ff79 100644
--- a/src/misc1.c
+++ b/src/misc1.c
@@ -495,7 +495,7 @@ get_breakindent_win(
static varnumber_T prev_tick = 0; /* changedtick of cached value */
int bri = 0;
/* window width minus window margin space, i.e. what rests for text */
- const int eff_wwidth = W_WIDTH(wp)
+ const int eff_wwidth = wp->w_width
- ((wp->w_p_nu || wp->w_p_rnu)
&& (vim_strchr(p_cpo, CPO_NUMCOL) == NULL)
? number_width(wp) + 1 : 0);
@@ -2026,7 +2026,7 @@ plines_win_nofold(win_T *wp, linenr_T lnum)
/*
* Add column offset for 'number', 'relativenumber' and 'foldcolumn'.
*/
- width = W_WIDTH(wp) - win_col_off(wp);
+ width = wp->w_width - win_col_off(wp);
if (width <= 0)
return 32000;
if (col <= width)
@@ -2083,7 +2083,7 @@ plines_win_col(win_T *wp, linenr_T lnum, long column)
/*
* Add column offset for 'number', 'relativenumber', 'foldcolumn', etc.
*/
- width = W_WIDTH(wp) - win_col_off(wp);
+ width = wp->w_width - win_col_off(wp);
if (width <= 0)
return 9999;