[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: shrink-window-if-larger-than-buffer in VC-diff

From: martin rudalics
Subject: Re: shrink-window-if-larger-than-buffer in VC-diff
Date: Sat, 27 Oct 2012 15:45:41 +0200

> Maybe we should change `pop-to-buffer' so that it accepts
> an option to both shrink *and* grow windows.  Then people who want their
> windows to resize automagically can use this option, and have it work
> more reliably than it does now.

This is now possible using the `window-height' and `window-width' alist
entries.  There are currently two major problems with this:

(1) `temp-buffer-resize-mode' overrides it.  This is no problem for
`with-output-to-temp-buffer' since that macro encapsulates the
`display-buffer' call.  But `with-temp-buffer-window' has an ACTION
argument which can be now overridden and manually activating
`temp-buffer-resize-mode' in a buffer will accomplish the same.

(2) I'm not sure what to do with `fit-window-to-buffer' and
`shrink-window-if-larger-than-buffer' calls that happen after
`display-buffer' like in `vc-root-diff'.  In principle, I could have
`display-buffer' add a window parameter or a buffer-local variable to
handle such cases.  But neither of them look very attractive to me.

Any suggestions?

> (The default should be to avoid
> resizing at all.)

I disagree here.  We should try to preserve the previous behavior.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]