GNU bug report logs - #37689
Fringe pixmaps, widgets, etc. look ridiculously tiny in hidpi screen

Previous Next

Package: emacs;

Reported by: Carlos Pita <carlosjosepita <at> gmail.com>

Date: Thu, 10 Oct 2019 06:30:02 UTC

Severity: normal

Tags: patch

Done: Carlos Pita <carlosjosepita <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Carlos Pita <carlosjosepita <at> gmail.com>
Cc: rpluim <at> gmail.com, 37689 <at> debbugs.gnu.org
Subject: bug#37689: Fringe pixmaps, widgets, etc. look ridiculously tiny in hidpi screen
Date: Mon, 14 Oct 2019 11:33:02 +0300
> From: Carlos Pita <carlosjosepita <at> gmail.com>
> Date: Sun, 13 Oct 2019 21:40:14 -0300
> Cc: Robert Pluim <rpluim <at> gmail.com>, 37689 <at> debbugs.gnu.org
> 
> 1.a. Do the scaling as downstream as possible. The problem with this
> approach is that I will be fixing the problem only for one backend
> (for example, Cairo). Also, I would have to "hack" some assumptions
> done upstream (for example, to adjust x, y and scale of a rectangle
> that is assumed to be of a different geometry by the caller). The
> advantage of the approach is that not only fringe icons but any other
> image that is rendered by the lowest level routine will be properly
> scaled; but, that said, I noticed that in emacs 26.3 widgets are not
> using x_cr_draw_image.
> 
> 1.b. Do the scaling upstream (for example, in get_fringe_bitmap_data
> as proposed above). One problem with this approach is that some
> backend could already be scaling output itself (for example, by using
> a toolkit that automatically scales according to the device
> resolution... do you know if this is the case for windows, for
> macos?). Also, it won't fix the widgets issue (anyway, as I said,
> neither the "downstream" approach will do it in 26.3).

Granted, I prefer the second approach.  We should do as little code
duplication as possible.

I don't think individual backends do any scaling, but if some do, it
should be easy to disable the scaling in our code for those backends.

> 2. I'm clueless regarding were widgets (I mean checkboxes and things
> like that) are rendered. With Cairo backend enabled, x_cr_draw_image
> is never reached in 26.3, its only user is the fringe module, I've
> checked this in the debugger and by inspecting the code. Not sure
> about 27, since tweaking x_cr_draw_image did have a (weird) effect, as
> the screenshots in my previous post show.

I'm not sure I understand how this is related to the issue at hand.
Can you elaborate?

Also, what exactly do you mean by "rendered"?  In Emacs, there are
generally 2 stages of displaying any "display element" (a character,
an image, etc.): first, a backend-independent step of loading the
display element, determining its metrics, and performing the display
layout calculations derived from that; and then backend-dependent step
of actually delivering the display element to the glass.  Which one of
those did you have in mind?

Thanks.




This bug report was last modified 5 years and 207 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.