Saturday, March 18, 2017

Re: Weird window resizing behavior when creating a vertical split window

Kay Z wrote:

> I noticed a strange behavior while creating vertical windows.
>
> Sometimes when a vertical window is created between two other vertical windows, all three windows are improperly resized to a height of only one row.
>
> I managed to 100% reproduce this behavior in 8.0.0342 and 8.0.0473 (the most recent version from GitHub master when I'm writing this post), with this script:
>
> https://gist.github.com/l04m33/f7fef348143785c2bb6e119b212a4bc5
>
> Just run Vim with '-u NONE' and source wrong_window_size.vim. You'll see what I mean.
>
> The wired thing is, the window sizes became correct after I removed the setbufvar() calls in SpawnBufferWindow().
>
> I also tried it with 8.0.0324 (the default version came with Fedora 24), but the problem didn't appear.
>
> Maybe some code between 8.0.0324 and 8.0.0342 messed it up?

Thanks for the reproducible example. The problem is in restoring the
window layout after temporarily creating a window to set the option.
I can fix it.

--
hundred-and-one symptoms of being an internet addict:
156. You forget your friend's name but not her e-mail address.

/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language -- http://www.Zimbu.org ///
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///

--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment