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

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

bug#19482: Changing to big font cause display problem


From: martin rudalics
Subject: bug#19482: Changing to big font cause display problem
Date: Fri, 27 Feb 2015 20:49:59 +0100

>> (1) `x-frame-geometry' reports an external border width of zero for a
>>     normal, non-maximized frame.  That's clearly wrong, the width is 5
>>     pixels.  I have no idea how to track down what XGetWindowAttributes
>>     retrieves here.
>
> As I said in another mail, this is probably the window manager decorations, 
not a window border.  5 pixels is a large window border, but a reasonable window 
manager decoration.
> However, I added the window manager window border to the calculations, but I 
suspect it is 0 all the time.
> In theory it could be something else.

In my book the border is that thing I have to drag in order to resize a
window with the mouse.  Is that wrong?  Does that mean that the border
reported by XGetWindowAttributes is not the same as the border reported
by XGetGeometry?  In this case we should probably not ignore the eight
argument of the latter.

>> (2) `x-frame-geometry' reports a title height of 5.  This is wrong - the
>>     title height is 20 pixels.  I don't yet understand how
>>     x_real_pos_and_offsets works but I strongly suppose that
>>
>>       if (top_offset_y) *top_offset_y = -outer_x;
>>
>>     should be
>>
>>       if (top_offset_y) *top_offset_y = -outer_y;
>>
>>     at least.
>>
>
> Typo, fixed now.

Thanks.

>> Also, these two assignments
>>
>>   outer_width = FRAME_PIXEL_WIDTH (f) + 2 * border + right_off + left_off;
>>   outer_height = FRAME_PIXEL_HEIGHT (f) + 2 * border + top_off + bottom_off;
>>
>> should _not_ use FRAME_PIXEL_HEIGHT and FRAME_PIXEL_WIDTH because that
>> would mean that I counter-check our calculations of frame sizes from
>> these calculations.  What we should use here are the 'width' and 'height'
>> attributes as returned by XWindowAttributes.
>
> Indeed.
>
>>
>> I haven't checked yet but do we conceptually assume that
>>
>> FRAME_PIXEL_WIDTH (f) == atts.width
>> FRAME_PIXEL_HEIGHT (f) == atts.height
>>
>> Or does something additionally come into play here?
>
> attts.height contains the external menu bar and tool bar, but PIXEL_HEIGHT 
does not.  I did not think that one through.

OK.  I'll try to play around with these.

martin





reply via email to

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