Mercurial > vim
view runtime/doc/howto.txt @ 34548:db67c09ccd53 v9.1.0175
patch 9.1.0175: wrong window positions with 'winfix{width,height}'
Commit: https://github.com/vim/vim/commit/5866bc3a0f54115d5982fdc09bdbe4c45069265a
Author: Sean Dewar <6256228+seandewar@users.noreply.github.com>
Date: Wed Mar 13 20:17:24 2024 +0100
patch 9.1.0175: wrong window positions with 'winfix{width,height}'
Problem: winframe functions incorrectly recompute window positions if
the altframe wasn't adjacent to the closed frame, which is
possible if adjacent windows had 'winfix{width,height}' set.
Solution: recompute for windows within the parent of the altframe and
closed frame. Skip this (as before) if the altframe was
top/left, but only if adjacent to the closed frame, as
positions won't change in that case. Also correct the return
value documentation for win_screenpos. (Sean Dewar)
The issue revealed itself after removing the win_comp_pos call below
winframe_restore in win_splitmove. Similarly, wrong positions could result from
windows closed in other tabpages, as win_free_mem uses winframe_remove (at least
until it is entered later, where enter_tabpage calls win_comp_pos).
NOTE: As win_comp_pos handles only curtab, it's possible via other means for
positions in non-current tabpages to be wrong (e.g: after changing 'laststatus',
'showtabline', etc.). Given enter_tabpage recomputes it, maybe it's intentional
as an optimization? Should probably be documented in win_screenpos then, but I
won't address that here.
closes: #14191
Signed-off-by: Sean Dewar <6256228+seandewar@users.noreply.github.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Wed, 13 Mar 2024 20:30:03 +0100 |
parents | 4635e43f2c6f |
children |
line wrap: on
line source
*howto.txt* For Vim version 9.1. Last change: 2006 Apr 02 VIM REFERENCE MANUAL by Bram Moolenaar How to ... *howdoi* *how-do-i* *howto* *how-to* |tutor| get started |:quit| exit? I'm trapped, help me! |initialization| initialize Vim |vimrc-intro| write a Vim script file (vimrc) |suspend| suspend Vim |usr_11.txt| recover after a crash |07.4| keep a backup of my file when writing over it |usr_07.txt| edit files |23.4| edit binary files |usr_24.txt| insert text |deleting| delete text |usr_04.txt| change text |04.5| copy and move text |usr_25.txt| format text |30.6| format comments |30.2| indent C programs |25.3| automatically set indent |usr_26.txt| repeat commands |02.5| undo and redo |usr_03.txt| move around |word-motions| word motions |left-right-motions| left-right motions |up-down-motions| up-down motions |object-motions| text-object motions |various-motions| various motions |object-select| text-object selection |'whichwrap'| move over line breaks |'virtualedit'| move to where there is no text |usr_27.txt| specify pattern for searches |tags-and-searches| do tags and special searches |29.4| search in include'd files used to find variables, functions, or macros |K| look up manual for the keyword under cursor |03.7| scroll |'sidescroll'| scroll horizontally/sideways |'scrolloff'| set visible context lines |mode-switching| change modes |04.4| use Visual mode |'insertmode'| start Vim in Insert mode |40.1| map keys |24.7| create abbreviations |ins-expandtab| expand a tab to spaces in Insert mode |i_CTRL-R| insert contents of a register in Insert mode |24.3| complete words in Insert mode |25.1| break a line before it gets too long |20.1| do command-line editing |20.3| do command-line completion |'cmdheight'| increase the height of command-line |10.3| specify command-line ranges |40.3| specify commands to be executed automatically before/after reading/writing entering/leaving a buffer/window |'autowrite'| write automatically |30.1| speedup edit-compile-edit cycle or compile and fix errors within Vim |options| set options |auto-setting| set options automatically |term-dependent-settings| set options depending on terminal name |save-settings| save settings |:quote| comment my .vim files |'helpheight'| change the default help height |'highlight'| set various highlighting modes |'title'| set the window title |'icon'| set window icon title |'report'| avoid seeing the change messages on every line |'shortmess'| avoid |hit-enter| prompts |mouse-using| use mouse with Vim |usr_08.txt| manage multiple windows and buffers |gui.txt| use the gui |You can't! (yet)| do dishes using Vim |usr_06.txt| switch on syntax highlighting |2html.vim| convert a colored file to HTML |less| use Vim like less or more with syntax highlighting vim:tw=78:ts=8:noet:ft=help:norl: