all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Joost Kremers <joostkremers@fastmail.fm>
To: martin rudalics <rudalics@gmx.at>
Cc: Eli Zaretskii <eliz@gnu.org>, emacs-devel@gnu.org
Subject: Re: Window splitting issues with margins
Date: Tue, 24 Nov 2015 13:59:07 +0100	[thread overview]
Message-ID: <87610rlfj8.fsf@fastmail.fm> (raw)
In-Reply-To: <87si4214q5.fsf@fastmail.fm>


On Do, Nov 19 2015, Joost Kremers <joostkremers@fastmail.fm> wrote:
> On Di, Nov 17 2015, martin rudalics <rudalics@gmx.at> wrote:
>> The only thing we can do is to say in the documentation that when two
>> packages contend for the same margin, the one that tries to do that
>> later in the redisplay cycle will succeed.
>
> Perhaps it could also be added that in order to reduce (though not
> eliminate) the risk of interoperability problems, packages (1) should
> examine the width of the margins before changing them (e.g., in
> `window-configuration-change-hook'); (2) should not set the margins to a
> width lower than the existing width; and (3) should restore the original
> width when they are disabled (or rather, restore the width that existed
> before the last time they changed the margins).

[These comments are mainly for future reference, in case anyone
revisits this discussion.]

Well, I tried implementing this policy in `visual-fill-column-mode', but
it didn't work, because it's not clear at all where margins come from.
E.g., suppose `nlinum-mode' and `visual-fill-column-mode' are both
active in a buffer. Now, `nlinum-mode' only sets the left margin, so
when `visual-fill-column-mode' needs to reset the margins, the existing
width of the right margin has been set by `visual-fill-column-mode'
during the previous margin update. The problem is that
`visual-fill-column-mode' has no way of knowing this and therefore
assumes it cannot reduce the right margin, even though it can.

So, summarising, the situation as it is doesn't really provide a way to
allow multiple packages to use the margins safely. Making that possible
would require some big changes to the way margins are handled.


-- 
Joost Kremers
Life has its moments



  parent reply	other threads:[~2015-11-24 12:59 UTC|newest]

Thread overview: 39+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-12 13:04 Window splitting issues with margins Joost Kremers
2015-11-12 14:31 ` martin rudalics
2015-11-12 16:28   ` Eli Zaretskii
2015-11-12 21:38     ` Joost Kremers
2015-11-13  8:04       ` martin rudalics
2015-11-13  8:40       ` Eli Zaretskii
2015-11-13 10:01         ` martin rudalics
2015-11-13 13:54           ` Eli Zaretskii
2015-11-13 14:53             ` martin rudalics
2015-11-13 18:34               ` Eli Zaretskii
2015-11-12 22:14   ` Joost Kremers
2015-11-13  8:04     ` martin rudalics
2015-11-13  8:43       ` Eli Zaretskii
2015-11-13 10:02         ` martin rudalics
2015-11-14 20:34         ` Joost Kremers
2015-11-16 15:53           ` Eli Zaretskii
2015-11-16 16:56             ` Joost Kremers
2015-11-16 18:56               ` martin rudalics
2015-11-16 20:11                 ` Joost Kremers
2015-11-17  8:35                   ` martin rudalics
2015-11-19 13:46                     ` Joost Kremers
2015-11-20  8:21                       ` martin rudalics
2015-11-25 13:10                         ` Joost Kremers
2015-11-24 12:59                       ` Joost Kremers [this message]
2015-11-24 19:26                         ` martin rudalics
2015-11-25 19:53                           ` Joost Kremers
2015-11-26  8:23                             ` martin rudalics
2015-11-26 15:46                               ` Eli Zaretskii
2015-11-26 16:58                                 ` martin rudalics
2015-11-26 17:13                                   ` Eli Zaretskii
2015-11-26 18:04                                     ` martin rudalics
2015-11-26 18:32                                       ` Eli Zaretskii
2015-11-27  8:26                                         ` martin rudalics
2015-11-27  9:00                                           ` Eli Zaretskii
2015-11-28 10:22                                             ` martin rudalics
2015-11-28 11:13                                               ` Eli Zaretskii
2015-11-14 20:47       ` Joost Kremers
2015-11-16 17:02         ` John Wiegley
2015-11-16 10:51       ` Yuri Khan

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=87610rlfj8.fsf@fastmail.fm \
    --to=joostkremers@fastmail.fm \
    --cc=eliz@gnu.org \
    --cc=emacs-devel@gnu.org \
    --cc=rudalics@gmx.at \
    /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.