1

Thumbnails of pictures and PDF files on desktop do not keep aspect ratio. If I open the desktop folder in the default gnome file manager, the icons aren't stretched. The problem is only with what is shown on the desktop. See screenshot. What would you suggest for solving this?

screenshot

1

With Ubuntu 20.04.1, with the most recent gnome-shell update (gnome-shell-extension-desktop-icons 20.04.0-3~ubuntu20.04.1), the bug still exists.

A possible fix is, in /usr/share/gnome-shell/extensions/desktop-icons@csoriano/fileItem.js, replace: let containerWidth = (this._icon.allocation.x2 - this._icon.allocation.x1) * scaleFactor; with: let containerWidth = (this._icon.allocation.x2 - this._icon.allocation.x1);, then re-login/reboot the system.

Basically, the scaleFactor multiplier here is unnecessary. Tested on Ubuntu 20.04.1, with display scale 200%. Desktop thumbnails work fine after removing the scaleFactor multiplier as above.

You can also see the bug report here.

1
  • This worked perfectly for me in ubuntu 20.04. I believe this is the correct answer! – gannex Apr 21 at 20:17
0

This is a bug

Bug #1868529 “Stretched image previews on desktop” : Bugs : gnome-shell-extension-desktop-icons package : Ubuntu

The fix is already available via updates, but it is not perfect. The aspect ratio is still wrong for images that have aspect ratio less than that of the container.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.