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

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

bug#23144: shrinking windows with gtk 3.20


From: Matthias Clasen
Subject: bug#23144: shrinking windows with gtk 3.20
Date: Sat, 2 Apr 2016 13:27:25 -0400

On Sat, Apr 2, 2016 at 12:28 PM, Eli Zaretskii <address@hidden> wrote:
>> Date: Sat, 02 Apr 2016 18:06:16 +0200
>> From: martin rudalics <address@hidden>
>> CC: address@hidden, address@hidden
>>
>> In emacs-25 either use something like
>>
>> #if !GTK_CHECK_VERSION (3, 20, 0))
>>            xg_frame_resized (f, -1, -1);
>> #endif
>
> I hope we do that on master.  If not, we should.  There's no reason
> not to continue calling xg_frame_resized with older versions of GTK,
> as it works there.
>
> I'm wary of doing this in Emacs 25.1.
>
>> or, as Matthias proposed, in xg_frame_resized write
>>
>>    if (pixelwidth == -1 && pixelheight == -1)
>>      {
>>        if (FRAME_GTK_WIDGET (f) && gtk_widget_get_mapped (FRAME_GTK_WIDGET 
>> (f)))
>>       {
>>         gdk_window_get_geometry (gtk_widget_get_window (FRAME_GTK_WIDGET 
>> (f)),
>>                                  0, 0, &pixelwidth, &pixelheight);
>>         if (pixelwidth <= 1 || pixelheight <= 1)
>>           return;
>>       }
>>        else
>>       return;
>>      }
>
> Do we understand the effect of this?  It effectively makes the
> xg_frame_resized call a no-op, but I very much doubt that this call
> was added there with no good reason.  Does the history of this
> addition, including any related discussions, teach us something about
> the reason?

Yes, this is what I would have suggested as alternative patch for
emacs 25. It only disregards the return value of
gdk_window_get_geometry if it is still the initial value of 1,1 -
thats clearly not a useful size for an emacs window...





reply via email to

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