this post was submitted on 18 Sep 2023
45 points (94.1% liked)

Linux

48743 readers
1212 users here now

From Wikipedia, the free encyclopedia

Linux is a family of open source Unix-like operating systems based on the Linux kernel, an operating system kernel first released on September 17, 1991 by Linus Torvalds. Linux is typically packaged in a Linux distribution (or distro for short).

Distributions include the Linux kernel and supporting system software and libraries, many of which are provided by the GNU Project. Many Linux distributions use the word "Linux" in their name, but the Free Software Foundation uses the name GNU/Linux to emphasize the importance of GNU software, causing some controversy.

Rules

Related Communities

Community icon by Alpár-Etele Méder, licensed under CC BY 3.0

founded 5 years ago
MODERATORS
 

Hi all, I have a 4k monitor and the steam app is very tiny. I have found out that I can fix it by running the app in the terminal with steam -forcedesktopscaling 2, but it is getting tiring launching it through the terminal. Is there any way I can change something in the app itself and make it launch with that command? KDE Plasma on endeavour OS is what I'm running Tried going into the .desktop file to add the command somewhere in the "exec", but failed. Could someone please help? Thank you

top 18 comments
sorted by: hot top controversial new old
[–] [email protected] 13 points 1 year ago (2 children)

This depends on if you installed Steam as a Flatpak or through the endeavourOS repositories, but one way that should work is editing the Exec line in the .desktop file. You've already tried that, but I don't know what you put there so it might be worth editing that line again. Try editing the Exec line to Exec=GDK_SCALE=2 /usr/bin/steam %U and let us know what happens.

[–] [email protected] 4 points 1 year ago* (last edited 1 year ago) (1 children)

Oh, and also there was Exec=/usr/bin/steam %U at the beginning under the [Desktop Entry] section that I added your command to to make it look like this Exec=GDK_SCALE=2 /usr/bin/steam %U and it still didn't work. Also, there are two steam apps, native and just plain steam in etc/usr/share/applications. I have two steams in my apps menu, steam(runtime) and native. It's so damn confusing :/

[–] Still 1 points 1 year ago* (last edited 1 year ago) (1 children)

you'd need to set the environment variables, that exec command is trying to run a program named GDK_SCALE, instead it should be like Exec=/usr/bin/env GDK_SCALE...

the two steam options are to choose between using the systems provided libraries and the ones that ship with steam, I recommend using the steam runtime rather than native

[–] [email protected] 1 points 1 year ago (1 children)

Changed Exec=/usr/bin/steam-runtime %U to Exec=usr/bin/env GDK_SCALE=2 and still nothing changed

[–] Still 2 points 1 year ago* (last edited 1 year ago)

you need the whole line to be like Exec=/usr/bin/env GDK_SCALE=2 /usr/bin/steam %U

I was just being lazy as I was on mobile at the time

/usr/bin/steam should be a link to /usr/bin/steam-runtime aswell

[–] [email protected] 2 points 1 year ago (1 children)

Thank you. Sorry, I forgot to mention that I just installed it from the repos. As for the exec command, it is a bit confusing because there are more than just one. There is an exec command under every catagory. For example, there is a section called [Desktop Action BigPicture] that has an exec line Exec=steam steam://open/bigpicture. There are more than one section, and they all have an exec line. I tried the line you provided at the very end of the steam.desktop and steam-native.desktop and still got nothing. So not sure honestly

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago) (1 children)

The other sections are different actions that appear in the context menu of the steam desktop icon, so that you can launch steam straight into big picture for example. If you just launch steam, just the [Desktop Entry] section will execute.

While in my experience the answer you replied to works, to get the same behavior as what you got in the terminal, you should edit the exec line to something like steam --forcedesktopscaling=2 %u.

If you use the separate actions, you should edit it there as well, but those won't have any effect on just launching steam.

[–] [email protected] 1 points 1 year ago (1 children)

Switched to this Exec=steam -forcedesktopscaling 2 %U and it still didn't work. Changed a couple of things there and still nothing. Damn, this is so annoying. Guess I will need to just do it through the terminal and call it a day

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago)

I just use in my Exec=

Exec=GDK_SCALE=2 steam

but that may differ in looks from the options you are using

I have a steam-big-ui.desktop that gives me the option to run in big mode, or I run normal steam for small mode.

[–] [email protected] 4 points 1 year ago (1 children)

I use openSUSE and Plasma. I can just right click the start menu thing, and click "Edit Applications". Fro m there, I find Steam (Games -> Steam). And you can edit the command in the "Program" box.

I did something similar to get Steam to run in my GPU, since it was killing my CPU performance by running on the integrated GPU. It worked fine for me!

Good luck!

[–] [email protected] 2 points 1 year ago (1 children)

Ok, so there is this line in there /usr/bin/steam-native, what do I append to it?

[–] [email protected] 2 points 1 year ago* (last edited 1 year ago) (1 children)

You got it working by appending -forcedesktopscaling 2, right? try appending that so it is /usr/bin/steam-native -forcedesktopscaling 2.

I would bet that your steam command is a link pointing to /usr/bin/steam-native. You could find out with which steam | xargs ls -al

[–] [email protected] 2 points 1 year ago (1 children)

It fails to launch when I appended that line. It's ok, I will just use the terminal. I'm getting sick of it. Thank you for your help

[–] [email protected] 1 points 1 year ago* (last edited 1 year ago) (1 children)

Launch options need to be set in their own "Arguments" line, it should work then. Like this:

And if you also want to use the "GDK_SCALE=2" environment variable, as suggested elsewhere in this thread, this would need to be set in the "Environment Variables" line.

[–] [email protected] 2 points 1 year ago

Didn't work. I just gave up on it. Lol

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago) (1 children)

I recommend using the environment variable. Place a text file, steam.sh for example, into ~/.config/plasma-workspace/env/ containing

!/bin/sh
export STEAM_FORCE_DESKTOPUI_SCALING=2.0
[–] [email protected] 2 points 1 year ago (1 children)

So, I created this file. I assume it needs to be set as “executable”? Did that and put in the path you suggested. Now what? Launched steam, still the same. Launch the file itself and nothing happened. :/

[–] [email protected] 1 points 1 year ago

Have you tried to reboot your PC?