Scaling work around for Snaps breaks after an update

Solved!
Reply

Scaling work around for Snaps breaks after an update

Andy1633
Casual Listener

Plan

Premium

Country

United Kingdom

Device

Dell XPS 9350

Operating System

Ubuntu 18.04 LTS

 

My Question or Issue

As observed in this post, there is a workaround to fix the scaling setting for spotify installed using snaps by adding `--force-device-scale-factor=1.5` to the `.desktop` file. There is one problem with this however as whenever the snap is updated it looks like the setting gets removed. Is there any way to fix this?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Solution!

Re: Scaling work around for Snaps breaks after an update

Spotify
Spotify

Sorry about that.

 

Try to copy the desktop file to $HOME/.local/share/applications/ but replace the snapshot revision in the path (for instance 28) with the word current, which is a symlink to the currently active revision.

 

2 Replies
Highlighted
Solution!

Re: Scaling work around for Snaps breaks after an update

Spotify
Spotify

Sorry about that.

 

Try to copy the desktop file to $HOME/.local/share/applications/ but replace the snapshot revision in the path (for instance 28) with the word current, which is a symlink to the currently active revision.

 

Re: Scaling work around for Snaps breaks after an update

Andy1633
Casual Listener
[Desktop Entry]
Type=Application
Name=Spotify
GenericName=Music Player
Icon=/snap/spotify/current/usr/share/spotify/icons/spotify-linux-128.png
Exec=env BAMF_DESKTOP_FILE_HINT=/var/lib/snapd/desktop/applications/spotify_spotify.desktop /snap/bin/spotify --force-device-scale-factor=2 %U
Terminal=false
MimeType=x-scheme-handler/spotify;
Categories=Audio;Music;Player;AudioVideo;
StartupWMClass=spotify

Okay, this is what the final file looks like. I copied the file, replaced the "30" in the icon path with "current" and added the HiDPI command line argument to the exec line. Looks like it works for now. Thanks for the help! :)

SUGGESTED POSTS