! Please note that this is a snapshot of our old Bugzilla server, which is read only since May 29, 2020. Please go to gitlab.xfce.org for our new server !
HiDPI monitor, GDK_SCALE=2, icons offscreen and blurred background
Status:
RESOLVED: MOVED
Product:
Xfdesktop
Component:
General

Comments

Description pezcurrel 2019-04-13 18:25:54 CEST
Created attachment 8401 
The desktop when GDK_SCALE=2 is set

On my laptop I have an HiDPI monitor, I have GDK_SCALE=2 set in my environment because that's the only way many applications' icons get displayed at a good size. Everything used to work fine with this setup, but since some 4.13 release many icons on the desktop are "rendered offscreen". It's like the algorithm that places them is considering a double-sized desktop. Please see the attachments.
Comment 1 pezcurrel 2019-04-13 18:28:09 CEST
Created attachment 8402 
The same desktop when GDK_SCALE=2 is not set
Comment 2 pezcurrel 2019-04-13 18:33:10 CEST
Comment on attachment 8401 
The desktop when GDK_SCALE=2 is set

In the first attachment you can see that the "filename numbers sequence" is broken, since some icons are "rendered offscreen"
Comment 3 pezcurrel 2019-04-14 21:57:34 CEST
As a workaround I created a .desktop file in /etc/xdg/autostart

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Workaround for xfdesktop seeing double when GDK_SCALE=2 is set
Exec=sh -c "xfdesktop -Q && sleep 1 && GDK_SCALE=1 GDK_DPI_SCALE=1 xfdesktop &"
OnlyShowIn=XFCE;
StartupNotify=false
Terminal=false
Hidden=false
Comment 4 Theo Linkspfeifer editbugs 2019-04-16 14:47:27 CEST
I can confirm this issue.
Comment 5 Olivier Duclos 2019-05-30 14:44:48 CEST
I had the same issue. Thanks for the workaround pezcurrel.

This scaling issue does not only affect the icons, but also the background picture. When I use a background picture at my screen native resolution, xfdesktop first upscales the images (because of GDK_SCALE=2) and then downscales it back to my screen resolution, resulting in a slightly blurred picture. I noticed this because at startup, LightDM displays the picture clearly and then when xfdesktop starts, the picture become blurry.
Comment 6 Theo Linkspfeifer editbugs 2019-06-07 20:08:24 CEST
There appear to be some smaller glitches also:

- incomplete text shadows
- moving big icons/thumbnails may leave traces
- bottom and right part of selection rectangle "jumping"
Comment 7 Andre Miranda editbugs 2019-10-09 05:00:59 CEST
I think we are dealing with multiple bugs here:

1. Icons offscreen: if you scale the icon size less icons will fit the screen. I think that if you use GDK_SCALE=1 on a monitor half of your resolution the same amount of icons would be displayed. Try a smaller icon size under Desktop Settings -> Icons.

2. Blurred background: what kind of wallpaper style are you using (scaled, stretched, zoomed...)? What happens when a different style is used?

3. Incomplete text shadows: I can reproduce (maybe a problem with the fallback css)

4. Moving big icons/thumbnails may leave traces: I can't reproduce

5. Bottom and right part of selection rectangle "jumping": I don't understand/can't reproduce

Unfortunately it's complicated to use xfdesktop scaled in a 1366x768 screen :)
Comment 8 pezcurrel 2019-10-13 17:49:20 CEST
(In reply to Andre Miranda from comment #7)

> 1. Icons offscreen: if you scale the icon size less icons will fit the
> screen. I think that if you use GDK_SCALE=1 on a monitor half of your
> resolution the same amount of icons would be displayed. Try a smaller icon
> size under Desktop Settings -> Icons.

It doesn't work, icons are still missing.
Comment 9 pezcurrel 2019-10-13 18:09:25 CEST
(In reply to Andre Miranda from comment #7)

> 1. Icons offscreen: if you scale the icon size less icons will fit the
> screen. I think that if you use GDK_SCALE=1 on a monitor half of your
> resolution the same amount of icons would be displayed. Try a smaller icon
> size under Desktop Settings -> Icons.

I have understand now there is a misunderstanding :)
The problem is not related to a screen full of icons, but... let's say you have a screen with no icons yet and have "icons orientation" set to "top left vertical" (the default)... now you create some files on the desktop... file "1", "2", "3", and so on, until these files' icons fill the vertical size of your screen, let's say, with file "8". Now you create file "9". Its icon doesn't show on the desktop, it "gets rendered" below its bottom, and the same happens with new file "10", "11" and so on, until you reach file "17": its icon gets rendered on top of screen as first icon of a new column, while icons for files from "9" to "17" stay offscreen and there's no way to reach them.
It's like the algorithm that places the icons is considering a double-sized desktop.
 
> Unfortunately it's complicated to use xfdesktop scaled in a 1366x768 screen
> :)

It's a hidpi, "4k", 3840x2160 screen :)
Comment 10 pezcurrel 2019-10-13 18:11:21 CEST
«while icons for files from "9" to "17" stay offscreen and there's no way to reach them» ---> «while icons for files from "9" to "16" stay offscreen and there's no way to reach them»
Comment 11 pezcurrel 2019-10-14 12:23:26 CEST
(In reply to pezcurrel from comment #9)
> (In reply to Andre Miranda from comment #7)
> 
> > 1. Icons offscreen: if you scale the icon size less icons will fit the
> > screen. I think that if you use GDK_SCALE=1 on a monitor half of your
> > resolution the same amount of icons would be displayed. Try a smaller icon
> > size under Desktop Settings -> Icons.
> 
> I have understand now there is a misunderstanding :)
> The problem is not related to a screen full of icons, but... let's say you
> have a screen with no icons yet and have "icons orientation" set to "top
> left vertical" (the default)... now you create some files on the desktop...
> file "1", "2", "3", and so on, until these files' icons fill the vertical
> size of your screen, let's say, with file "8". Now you create file "9". Its
> icon doesn't show on the desktop, it "gets rendered" below its bottom, and
> the same happens with new file "10", "11" and so on, until you reach file
> "17": its icon gets rendered on top of screen as first icon of a new column,
> while icons for files from "9" to "16" stay offscreen and there's no way to
> reach them.
> It's like the algorithm that places the icons is considering a double-sized
> desktop.

Also notice that exactly the same issue shows up if one set "window scaling" to "2x" under "settings" -> "appearence" -> "settings", without setting any GDK_SCALE in the environment.

> > Unfortunately it's complicated to use xfdesktop scaled in a 1366x768 screen
> > :)
> 
> It's a hidpi, "4k", 3840x2160 screen :)

Sorry, I didn't understand you were referring to your own screen :)
Comment 12 Theo Linkspfeifer editbugs 2019-10-16 02:17:11 CEST
*** Bug 16047 has been marked as a duplicate of this bug. ***
Comment 13 Tobi 2019-12-30 01:17:01 CET
My background is also blurred when using the 2x scaling in the appearance settings.

The style does not matter.
- on zoomed: Looks like the resolution is halved
- on centered: The picture is scaled 2x

all of it results in each px of the image being 2x2px large.
as if the background is running in a 960x540 resolution when the rest of the screen is running at 1920x1080
Comment 14 Theo Linkspfeifer editbugs 2020-01-06 18:02:27 CET
Created attachment 9352 
experimental diff

This patch prevents icons from being placed offscreen and eliminates the blurred background picture. Also, moving big icons/thumbnails should no longer leave traces (1px line at the top).

The selection rectangle issue seems to be gone, so no fix needed. Incomplete text shadows are specific to the text alignment:
PANGO_ALIGN_CENTER -> bug
PANGO_ALIGN_LEFT -> no bug
Comment 15 Git Bot editbugs 2020-05-26 00:32:25 CEST
-- GitLab Migration Automatic Message --

This bug has been migrated to xfce.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.xfce.org/xfce/xfdesktop/-/issues/45.

Please create an account or use an existing account on one of our supported OAuth providers. 

If you want to fork to submit patches and merge requests please continue reading here: https://docs.xfce.org/contribute/dev/git/start#gitlab_forks_and_merge_requests

Also feel free to reach out to us on the mailing list https://mail.xfce.org/mailman/listinfo/xfce4-dev

Bug #15285

Reported by:
pezcurrel
Reported on: 2019-04-13
Last modified on: 2020-05-26
Duplicates (1):
  • 16047 Icons get "rendered offscreen" when "Window scaling" is set to "2x"

People

Assignee:
Xfce Bug Triage
CC List:
5 users

Version

Version:
4.13.3

Attachments

The desktop when GDK_SCALE=2 is set (442.90 KB, image/png)
2019-04-13 18:25 CEST , pezcurrel
no flags
The same desktop when GDK_SCALE=2 is not set (343.89 KB, image/png)
2019-04-13 18:28 CEST , pezcurrel
no flags
experimental diff (3.48 KB, patch)
2020-01-06 18:02 CET , Theo Linkspfeifer
no flags

Additional information