all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Joost Kremers <joostkremers@fastmail.fm>
Cc: 44483@debbugs.gnu.org
Subject: bug#44483: 27.1.50; Window parameter `min-margins' doesn't split window in half
Date: Fri, 06 Nov 2020 16:41:05 +0200	[thread overview]
Message-ID: <83ft5m8s5a.fsf@gnu.org> (raw)
In-Reply-To: <87tuu2inkv.fsf@fastmail.fm> (message from Joost Kremers on Fri,  06 Nov 2020 15:09:36 +0100)

> From: Joost Kremers <joostkremers@fastmail.fm>
> Date: Fri, 06 Nov 2020 15:09:36 +0100
> 
> 
> 1. Open any text file, preferably with long lines (to better see the effect).
> 
> 2. `M-x visual-line-mode RET`
> 
> 3. `M-: (set-window-margins (selected-window) 0 150) RET`
> 
> The number 150 is arbitrary. It's appropriate for my case (with a frame width of
> about 238 characters).
> 
> 4. `M-: (set-window-parameter (selected-window) 'min-margins '(0 . 0)) RET`
> 
> 5. `C-x 3`
> 
> At this point, I expect the window to be split into two equally-sized
> side-by-side windows, but the split is at about one third of the original window
> width.

That expectation is incorrect by default.  To have the windows
equally-sized, you need to set window-combination-resize to t, AFAIU,
otherwise Emacs makes no promise that your expectation will be heeded.

> Note that in this recipe, the margins of the two windows aren't adjusted after
> the split, so in the left window the text is not visible at all and in the right
> window, the text area is two characters wide. (In my case, YMMV.)

You expected Emacs to adjust the margins?  The min-margins parameters
is consulted only when determining whether the window can be split, it
has no effect whatsoever on the window dimensions after the split.
And the manual specifically says that it is up to the application to
adjust the margins after the split.





  reply	other threads:[~2020-11-06 14:41 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-06 14:09 bug#44483: 27.1.50; Window parameter `min-margins' doesn't split window in half Joost Kremers
2020-11-06 14:41 ` Eli Zaretskii [this message]
2020-11-06 16:25   ` Joost Kremers
2020-11-06 18:29     ` Eli Zaretskii
2020-11-06 18:12 ` martin rudalics
2020-11-06 20:36   ` Joost Kremers
2020-11-07  9:00     ` martin rudalics
2020-11-08 15:00       ` Joost Kremers
2020-11-09  8:31         ` martin rudalics
2021-10-11 12:35           ` Stefan Kangas
2021-10-11 17:18             ` martin rudalics

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83ft5m8s5a.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=44483@debbugs.gnu.org \
    --cc=joostkremers@fastmail.fm \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.