bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#21333: 25.0.50; window-size-change-functions not called after mini-w


From: martin rudalics
Subject: bug#21333: 25.0.50; window-size-change-functions not called after mini-window resize
Date: Wed, 26 Aug 2015 09:08:45 +0200

> I do think it would be best not to use set-window-configuration in
> restoring state after exiting the minibuffer at all.

I profoundly dislike window configurations but in this particular case
they are needed.  If the minibuffer gets enlarged, a window above it
shrinks and as a consequence that window's start position changes to
keep point on screen, it's important to restore the previous start
position of that window.  Everything else would be disconcerting.

>> Alternatively, Fset_window_configuration could run a modified version of
>> ‘compare-window-configurations’ to compare the current configuration
>> with the one to be restored and restore the old configuration iff these
>> differ.  I'm not sure whether this would be any cheaper, especially when
>> the configuration does change frequently.
>
> I think it would be better to do this explicitly, even if we have to
> compare all properties.

You mean to compare the properties one can get by walking all windows on
the frame with those of the configuration that shall be restored?
Note that looking into a window configuration is not entirely trivial.

> +          if (!FRAME_WINDOW_SIZES_CHANGED (f)) {

For consistency, please don't use hanging braces.

> +            if (w->pixel_left != XFASTINT (p->pixel_left) ||
> +                w->pixel_top != XFASTINT (p->pixel_top) ||

Why do you think we need to check these?

martin






reply via email to

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