Subject: Customizable window resizing

From: Juri Linkov <[email-masked]>
Date: Wed, 06 Oct 2021 20:31:36 +0300

There are two ways how window resizing is currently hard-coded:

1. As discussed in
   https://lists.gnu.org/archive/html/emacs-devel/2021-09/msg01627.html
   when temp-buffer-resize-mode is enabled, it's impossible
   to disable automatic window resizing of the Help buffer.

   Thanks to Martin, the patch in
   https://lists.gnu.org/archive/html/emacs-devel/2021-09/msg01873.html
   allows customization when display-buffer-alist contains
   (window-height . nil)

2. As discussed in bug#45688, such commands as vc-log, vc-diff
   automatically resize the window, and the problem is that currently
   shrink-window-if-larger-than-buffer is used in these commands by default,
   but this behavior is hard-coded and can't be disabled by customization.
   A solution is to create a new hook like 'after-display-buffer-function'
   that by default will contain 'shrink-window-if-larger-than-buffer'.