Re: Blurry tray icons with hidpi GTK3

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

 



Using GTK3 via GNOME 3.x and HiDPi screen for years now, never seen that issue before if not with outdated software.

There are various hints in here for HiDPi:
https://wiki.archlinux.org/index.php/HiDPI

Have a look, maybe it's just a matter of configuration.

P.S. I know, I'm telling nothing new here but if your software doesn't use SVG images for icons it might result blurry regardless if the resolution isn't 2X or higher.


On Fri, Oct 14, 2016 at 9:25 PM, Daniel Anderson <me@xxxxxxxxxxx> wrote:
Thanks for the reply Emmanuele. If I'm understanding correctly what you're saying, I don't think the blurriness is from pixelation, e.g. turning a 16px icon into a 2x scaled and pixelated 32px icon. If you take a look at the two screenshots, most noticeably the the NetworkManager Wifi icon, you'll see that the blurriness isn't from pixelation that would be caused be 2x scaling an icon. It was properly scaled before I set the GDK_SCALE and GDK_DPI_SCALE environment variables. It looks to me that GDK_SCALE and GDK_DPI_SCALE are causing the tray icons to double in size again, then they get smashed and blurred. I'm not sure if the tray applications I've tested this on are to blame or if GTK3 is to blame. Like I said, the tray looks fine, as seen in the screenshot, without the environment variables. But I need the environment variables to make the GTK applications themselves, such as nautilus or evince, to scale correctly for HiDPI.

Best Regards,
Daniel Anderson


-------- Original Message --------
Subject: Re: Blurry tray icons with hidpi GTK3
Local Time: October 14, 2016 3:56 PM
UTC Time: October 14, 2016 7:56 PM
To: Dankles <me@xxxxxxxxxxx>

Hi;

The tray icon specification was written long before HiDPI was ever a twinkle in some engineer's eye, and has never supported scale factor negotiation. Additionally, icon sizes are pretty much hard coded by applications, so even if there were a way to specify multiple icons for different tray sizes or scaling factors, you would very likely still get blurry icons anyway.

Those are, incidentally, a few of the reasons why GTK deprecated GtkStatusIcon in the 3.0 API series - the other, major one being that Wayland does not have any additional protocol to define tray icons with menus and actions attached to them.

Ciao,
 Emmanuele.

On Friday, 14 October 2016, Dankles <me@xxxxxxxxxxx> wrote:
Team,
I'm having an issue with blurry tray icons using HiDPI GTK3. I've read to set GDK_SCALE=2 and GDK_DPI_SCALE=0.5 to get proper hidpi in GTK3 applications. This works and makes the GTK3 applications scale correctly, except for the tray icons. The tray icons actually scale fine without those environment variables set. One other HiDPI tweak I have set is "xrandr --dpi 192", otherwise programs like Xterm, dmenu and the WM won't scale.

Here are some screenshots:
- Without GDK_SCALE=2 and GDK_DPI_SCALE=0.5: https://i.imgur.com/e9xEQTe.png
I get good tray icons with some unscaled menu text. GTK3 applications themselves don't scale properly as expected.
- With GDK_SCALE=2 and GDK_DPI_SCALE=0.5: https://i.imgur.com/Qizd5cp.png
You can see blurry tray icons, but with properly scaled menu text. GTK3 applications scale as expected.

It seems to me like GDK_SCALE=2 and GDK_DPI_SCALE=0.5 is causing the already scaled tray icons to scale again. Is there something I can do to fix this? Is it a bug?

I'm running gtk 3.22.1 on arch linux. I'm using i3-wm, but I've seen this same issue on xmonad with trayer and on budgie desktop too for non-indicator tray icons. I'll also note that everything scales fine in gnome desktop on my hardware which is a Dell XPS 13 9350.

Best Regards,
Daniel A.




--
[@] ebassi [@gmail.com]


_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
https://mail.gnome.org/mailman/listinfo/gtk-list


_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
https://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux