aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/textformat.c
diff options
context:
space:
mode:
authorSean Dewar <seandewar@users.noreply.github.com>2024-01-28 13:03:56 +0000
committerGitHub <noreply@github.com>2024-01-28 13:03:56 +0000
commita757195a602bf502fcdb702887bf72f50d6e1717 (patch)
tree41f77c24ddfb88b82eaf1c6a5748036276eea2f9 /src/nvim/textformat.c
parent74e695d22715e52f5561a185583b8c23d4fa0dd6 (diff)
parentd85f180f26c0570c2510c899a0bf0023ec55a692 (diff)
downloadrneovim-a757195a602bf502fcdb702887bf72f50d6e1717.tar.gz
rneovim-a757195a602bf502fcdb702887bf72f50d6e1717.tar.bz2
rneovim-a757195a602bf502fcdb702887bf72f50d6e1717.zip
Merge pull request #24704 from seandewar/cmdwin-madness
vim-patch:9.1.{0047,0048,0049}: fun cmdwin fixes
Diffstat (limited to 'src/nvim/textformat.c')
-rw-r--r--src/nvim/textformat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/nvim/textformat.c b/src/nvim/textformat.c
index 64cccf5f3f..bfe3ed5972 100644
--- a/src/nvim/textformat.c
+++ b/src/nvim/textformat.c
@@ -763,7 +763,7 @@ int comp_textwidth(bool ff)
// The width is the window width minus 'wrapmargin' minus all the
// things that add to the margin.
textwidth = curwin->w_width_inner - (int)curbuf->b_p_wm;
- if (cmdwin_type != 0) {
+ if (curbuf == cmdwin_buf) {
textwidth -= 1;
}
textwidth -= win_fdccol_count(curwin);