9

Tested On: Ubuntu Gnome 16.04 LTS

I had an issues with getting my HiDPI display, 3200x1800, working correctly with Chromium. By default, Chromium supports high resolutions but does not adapt manually.

So, I found a work-around to get it to work and wanted to share it with everyone else.

Here is what I did:

Originally searched:

$ cd / && find -iname 'chromium*'

Returned a lot of results... If your results where anything like mine, you will see a file in: /etc/chromium-browser/default

Edit this file (all preference):

$ sudo nano /etc/chromium-browser/default

There is a section that has a variable for arguments to pass to the actual file being called in the /bin folder.

It looks like:

CHROMIUM_FLAGS=””

CHANGE it to:

CHROMIUM_FLAGS=”--force-device-scale-factor=2”

Save the changes and restart Chromium. That should fix Chromium for those that want to use Chromium with a higher resolution.

[NOTICE] Please keep in mind, the scaling factor takes a floating point value, so you can scale to something like 1.25 or 2.13, or whatever preference you want.

Hope this helps.

  • r00thkr
r00t hkr
  • 109
  • 1
  • 2
  • 5
  • this doesnt fix autodetection though :( I'm not entirely sure why this works in chrome but not chromium – Michael Aquilina Jul 26 '16 at 13:21
  • Nope, it doesn't have any use with auto detected displays, unfortunately. Which means that if you switch resolutions you will also have to switch the scaling factor. It's a pain, I know, but it's a solution. I guess, theoretically, you could create some algorithm for generating a scaling floating point value and have a script or program re-create that file every time you boot your PC. Then it would be a bandage-style-auto-detection lol. – r00t hkr Jul 26 '16 at 13:35
  • I basically have that setup for spotify already. Uses gsettings to figure out the current gnome scaling factor and passes that as an argument to the spotify command. Considering chrome does this automatically means it should manage on its own though. – Michael Aquilina Jul 26 '16 at 13:42
  • Oh yeah, I totally agree. I noticed that they do have the logic in place, but for whatever reason it never properly executes. I'm curious how did you pull a gsettings value out to use as the argument? – r00t hkr Jul 26 '16 at 13:45

0 Answers0