I asked a similar question about hiDPI scaling here. This question regards a universal hiDPI mode, the other question is about fixing scaling on a specific application.

I am using a 4k monitor in Pop!_OS 19.04 running Gnome.

The OS automatically detects this and changes into hiDPI mode, but only after I log in after boot.

This means the log in screen when I boot is far too small. Additionally, when I log in, the screen flickers and I get a notification Displays Set to HiDPI mode every time. The problem does not arise when suspending the computer.

The command to change to hidpi mode manually is

gsettings set com.system76.hidpi enable true

but this does not seem to permanently change to hidpi mode. Running this command in Startup Applications does not work either.

Is there a way to permanently change to hiDPI mode so the OS doesn't have to change it every time I boot? Or change the default setting to hiDPI somehow?

  • Are you using gdm or lightdm? – Paradox Jul 18 at 3:11
  • @Paradox I am using gdm – Hans J Jul 18 at 3:18
  • Are you using Wayland or x11 ? – Paradox Jul 18 at 16:27

Since your are using gdm, this should work for you system-wide:

1) Open the configuration file:

sudo nano /usr/share/glib-2.0/schemas/org.gnome.desktop.interface.gschema.xml

2) Change the default value to the scaling factor you want (e.g. 2):

<key name="scaling-factor" type="u">

3) Apply the changes:

sudo glib-compile-schemas /usr/share/glib-2.0/schemas

It works with gdm using x11, not sure about Wayland.

  • This works great, and the login screen looks good, but after I log in the system still notifies me "Displays Set to HiDPI mode at startup" and the screen flickers. It doesn't do anything, but is there a way to suppress this? – Hans J Jul 18 at 20:36
  • Nevermind, you can suppress the notification and screen flickering by disabling the HiDPI daemon in settings. I'll mark this as correct. – Hans J Jul 18 at 21:31

You could add to set per boot some other way (I'm not entirely sure how 'Startup Applications' works). There are a couple ways to do this:

  1. You could do it with cron. To edit your crontab run crontab -e and it will open up the crontab file with your preferred editor (or it might prompt you to choose an editor). Then adding an entry at the bottom would allow you to run a command at boot. For example, to run an echo command that runs every time I reboot my machine I'd add @reboot echo "Hello" > ~/hello.txt (Please note that if you wish this to be ran as root you'll have to run crontab -e as root).
  2. You could add it to a /etc/rc.local file. This might not exist on your system, but it'd normally be the last thing to run before your login manager. To add something you could run sudo nano /etc/rc.local and paste in something like this:
gsettings set com.system76.hidpi enable true
exit 0

Hope this helps, I sadly don't have a way to test either of these methods and don't know a way of setting to hiDPI permanently (without setting it per boot).

Source(s): https://www.simplified.guide/linux/automatically-run-program-on-startup

  • I do not think that will help since it happens even before log in into GNOME. – Paradox Jul 18 at 3:10
  • Thanks for the suggestions, but neither of these solutions seem to work. This could be an issue with the login manager being set to lowdpi mode at startup. – Hans J Jul 18 at 3:53
  • It might also be because gsettings only works for GNOME itself, the login manager would be separate. I also wouldn't be surprised if it's set to lowdpi for compatibility, as this is something that'll run pre-Xorg. – Maniyar Jul 18 at 14:10

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.