8000 Chrome and Electron render colors differently · Issue #10732 · electron/electron · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Chrome and Electron render colors differently #10732
Closed
@teleclimber

Description

@teleclimber
  • Electron version: 1.7.8
  • Operating system: Mac 10.12.6

Expected behavior

Colors set in CSS should render the same in Electron as they do in Chrome.

Actual behavior

Colors look different. See image:

electron-chrome-bg

How to reproduce

Set the background-color of an element of an Electron app to rgb( 126, 183, 253 ). Compare the color rendered by Electron to the same color as rendered in Chrome.

In your Electron app do not set vibrancy, and do not set background color via the BrowserWindow API.

Notice as well that if you take a screenshot and draw a rectangle of the same RGB in a drawing program it will match Chrome's color, not Electron.

Consequences

Please note this is not a trivial issue for those of us using Electron to create apps intended for design. Something that looks "right" to the user in an electron-based design app can look subtly different and "wrong" when they export their design and open it in a regular browser.

Thanks :)

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

      0