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

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

bug#60585: 30.0.50; global-text-scale-adjust shrinks window (was not bef


From: Po Lu
Subject: bug#60585: 30.0.50; global-text-scale-adjust shrinks window (was not before), was: Re: bug#52493: 29.0.50; Setting Inconsolata up in init.el makes default face rendered wrong
Date: Sun, 12 Feb 2023 09:45:03 +0800
User-agent: Gnus/5.13 (Gnus v5.13)

Dmitry Gutov <dgutov@yandex.ru> writes:

> On 11/02/2023 12:22, Po Lu via Bug reports for GNU Emacs, the Swiss
> army knife of text editors wrote:
>> Dmitry Gutov <dgutov@yandex.ru> writes:
>> 
>>> On 11/02/2023 03:36, Po Lu via Bug reports for GNU Emacs, the Swiss
>>> army knife of text editors wrote:
>>>> Whenever you see an inconsistency between what Emacs thinks its WM hints
>>>> are, and what you think the window manager sees, try to actually read
>>>> the window manager hints property with `xprop'.
>>>> It should print several lines describing the window manager hints.
>>>> WM_NORMAL_HINTS(WM_SIZE_HINTS):
>>>>            program specified minimum size: 34 by 55
>>>>            program specified resize increment: 8 by 17 <------
>>>>            program specified base size: 34 by 55
>>>>            window gravity: NorthWest
>>>> Check there to see if the increment is really 17x37.
>>>> Xt sometimes refuses to set hints, which can be very confusing.
>>>
>>> Thanks!
>>>
>>> Lucid's hints with InconsolataLGC:
>>>
>>> WM_NORMAL_HINTS(WM_SIZE_HINTS):
>>>             user specified size: 1714 by 1723
>>>             program specified minimum size: 51 by 140
>>>             program specified resize increment: 17 by 37
>>>             program specified base size: 51 by 140
>>>             window gravity: NorthWest
>> I guess the Lucid build is working correctly.
>> 
>>> GTK's hints with InconsolataLGC:
>>>
>>> WM_NORMAL_HINTS(WM_SIZE_HINTS):
>>>             program specified minimum size: 64 by 324
>>>             program specified resize increment: 16 by 36
>>>             program specified base size: 64 by 168
>>>             window gravity: NorthWest
>>>
>>> GTK's hints with "Inconsolata LGC" are the same, though:
>>>
>>> WM_NORMAL_HINTS(WM_SIZE_HINTS):
>>>             program specified minimum size: 64 by 324
>>>             program specified resize increment: 16 by 36
>>>             program specified base size: 64 by 168
>>>             window gravity: NorthWest
>> Thanks.
>> Would you please instrument emacsgtkfixed.c like such:
>> diff --git a/src/emacsgtkfixed.c b/src/emacsgtkfixed.c
>> index 2b6ebee65fd..24aaf134dd2 100644
>> --- a/src/emacsgtkfixed.c
>> +++ b/src/emacsgtkfixed.c
>> @@ -178,6 +178,9 @@ XSetWMSizeHints (Display *d,
>>       data[5] = w;
>>       data[6] = h; */
>>   +      fprintf (stderr, "XSetWMSizeHints: %d, %d\n",
>> hints->width_inc,
>> +           hints->height_inc);
>> +
>>         /* Make sure min_width and min_height are multiples of width_inc
>>       and height_inc.  */
>>   and tell me what is printed when Emacs begins to shrink?
>
> Apply it on top of the already patched Emacs, correct? The one I've
> been running most of the tests lately.
>
> During startup, it prints:
>
> XSetWMSizeHints: 2, 2
> XSetWMSizeHints: 18, 36
> XSetWMSizeHints: 18, 36
> XSetWMSizeHints: 18, 36
>
> After I evaluate (set-face-attribute ...), it adds:
>
> XSetWMSizeHints: 20, 44
> XSetWMSizeHints: 16, 36
> XSetWMSizeHints: 16, 36
>
> After that, whenever the same evaluation results in frame shrinking
> (after I resized it with a mouse), it also prints
>
> XSetWMSizeHints: 16, 36
>
> That's it.

Right... thanks.

I'm interested in why XSetWMSizeHints might be called with 20, 44.
Would you please put a breakpoint there and make it conditional on
those values of hints->width_inc and hints->height_inc?




reply via email to

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