Skip to content

Blurry rendering on High-DPI after Chrome 45 upgrade #3349

Closed

Description

@CharlieHess

We're seeing text / image blurriness on high-DPI displays, after the Chrome 45 upgrade (Windows only).

Slack 1.2.2 (Electron 0.30.5) on the left
Slack 1.2.5 (Electron 0.34.1) on the right
slack-dpi-bug

Any idea what would cause this?

Activity

  1. zcbenz commented on Nov 6, 2015

    @zcbenz
    Contributor

    Did you turn off direct-write?

  2. added
    blocked/need-info ❌
    on Nov 6, 2015
  3. anaisbetts commented on Nov 6, 2015

    @anaisbetts
    Contributor

    @zcbenz We're seeing this on Windows 10, where we hard-code direct-write: true, though I'll double-check

  4. zcbenz commented on Nov 6, 2015

    @zcbenz
    Contributor

    It is hard to say what has happened, you can do following comparisons to have a better idea:

    • Open the Slack website in Electron window and see if it has the same problem.
    • Export the page in Slack app to local HTML file, then open it in Chrome browser and check whether it is a bug of Chrome.
    • Open the exported page in default app to check whether it is caused by the settings of BrowserWindow.
  5. zcbenz commented on Nov 16, 2015

    @zcbenz
    Contributor

    Closing until more information is provided.

  6. anaisbetts commented on Nov 16, 2015

    @anaisbetts
    Contributor

    Atom is seeing a raft of new font issues reported in the last week or two:

    atom/atom#9596
    atom/atom#9454
    atom/atom#9226
    atom/atom#9161

    I think this is a Chrome 45 bug, hopefully Chrome 47 drops soon so we can move to it

  7. as-cii commented on Nov 16, 2015

    @as-cii
    Contributor

    Looking at those issues it would seem like this is not related just to a specific platform: given that the Slack team is observing similar issues too, I'd agree that this could be related to a Chromium 🐛.

    So, based on @paulcbetts's investigation, there are a couple of things we should probably do to fix this:

    1. Make sure we're running the latest Squirrel version. It seems like AppCompat was messing with DPI stuff and this has been fixed in the last versions (Remove AppCompat shims that applied to our applications Squirrel/Squirrel.Windows#478)
    2. Upgrade Electron's Chromium Version. It seems like the Chromium team is aware of this problem and they've been discussing it over here: unfortunately, a fix hasn't landed yet, so I think the only two options here would be to:
      • Wait for a fix to land on the next Chrome versions;
      • Or, if that's not going to happen anytime soon, patch libchromiumcontent ourselves;

    As far as I can tell, they're already working on a fix (https://code.google.com/p/chromium/issues/detail?id=485650) and the plan is to :shipit: in time for Chrome 49.

    @zcbenz: I am going to reopen this issue, but I'd like to hear your thoughts about it 💭. From the changelogs it's not clear if some sort of fix has been shipped on Chrome 48, but it's probably worth having a 👀 at it.

  8. reopened this on Nov 16, 2015
  9. as-cii commented on Nov 16, 2015

    @as-cii
    Contributor

    Also, since this seems to affect a pretty big portion of Atom's user base, do you think downgrading to the previous version of Electron in Atom could be an option? It would be a sort of a bummer but we're not really sure about how long it's going to take to fix that problem in the Chromium codebase.

    Thoughts?

    /cc: @nathansobo @benogle

  10. etiktin commented on Nov 17, 2015

    @etiktin
    Contributor

    The fix mentioned in https://code.google.com/p/chromium/issues/detail?id=484400 looks pretty simple (DSF < 1.3 => 1.0 and using a single decimal). Can any one confirm that rounding the scale factor solves the visual issues (can be tested by passing --force-device-scale-factor with the new factor)?

  11. added and removed
    blocked/need-info ❌
    on Nov 17, 2015
  12. zcbenz commented on Nov 17, 2015

    @zcbenz
    Contributor

    I'll apply the patch in Chromium of blacklisting device-scaling-factor < 1.3 and see whether it fixes the problem.

  13. albuic commented on Nov 17, 2015

    @albuic

    @etiktin
    I confirm that --force-device-scale-factor=1 worked for me (Debian with i3wm). Hope you will find a fix for everybody ! ;-)

  14. zcbenz commented on Nov 17, 2015

    @zcbenz
    Contributor

    @paulcbetts @as-cii Most reports I saw were on Linux, the fix for crbug.com/484400 is only available on Linux and I will apply the patch in Electron, but I'm still unsure on how to fix it on Windows.

  15. zcbenz commented on Nov 24, 2015

    @zcbenz
    Contributor

    v0.34.4 has been published with the fix for Linux, v0.35.1 included the fix too. However I'm not sure whether it really fixed the problem since I can not find a machine to test it, please report back if it is still there.

    /cc @as-cii

  16. as-cii commented on Nov 24, 2015

    @as-cii
    Contributor

    Thanks, @zcbenz. I'll make sure to open a PR on Atom that upgrades Electron to the latest version, so that we can test if this fix solves the issue on Linux. After having a second 👀 on the Windows reports for blurry text on Atom, I feel like it could be related to another issue (subpixel font scaling + tiling), although at this point I am not sure what's triggering this behavior on the Slack app.

  17. soren121 commented on Nov 24, 2015

    @soren121

    I built microsoft/vscode on Linux with Electron 0.34.4 and the blurry text is indeed fixed! Thanks.

  18. zcbenz commented on Jan 7, 2016

    @zcbenz
    Contributor

    So on Linux high DPI already works fine, which fixed most of the feedbacks on high DPI problem. For Windows I don't know whether Chrome 47 has fixed the problem, but I'm assuming it has.

  19. mattconsto commented on Feb 22, 2016

    @mattconsto

    At least for me, Chrome 47/48 hasn't fixed the issue. Only the code is blurry, which I fixed with --force-device-scale-factor=1, which has the unfortunate side effect of making the menu bar and file tree smaller than it should be. I've noticed this issue with a few websites in Chrome such as Google Drive so I've switched to using Firefox for editing stuff there.

    I'm running Windows 8.1 64bit on a 1920x1080 screen at whatever Larger scaling is (I 'think' it may be 1.5 but honestly I'm not sure). Before writing this I downloaded the Atom installer and reinstalled it, to no avail.

    If this is the wrong place to put this, and I was supposed to create a new issue, I'm sorry and put it here because it seems this was never really resolved for Windows.

  20. anaisbetts commented on Feb 22, 2016

    @anaisbetts
    Contributor

    @mattconsto fwiw, switching your DPI to either 1.0 (i.e. 100%) or 2.0 (200%) will work around your issue (and also generally makes other apps look better too)

  21. mattconsto commented on Feb 23, 2016

    @mattconsto

    @paulcbetts I have a 14" laptop, so doing so makes everything look really tiny, and I can't set my DPI to 200% without Windows 10. I prefer a few applications to look blurry or small than everything look small, which is why --force-device-scale-factor=1 is a better work around for me. I have come to except that for some applications I'll need to disable device scaling.

  22. felixrieseberg commented on Aug 10, 2016

    @felixrieseberg
    Member

    It's worth pointing out that Chromium M53 will enable "use zoom for dsf" by default, meaning that this change should eventually trickle down to Electron and fix a lot of the blurriness discussed here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions