WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
216795
System color 'canvas' cannot be set or read
https://bugs.webkit.org/show_bug.cgi?id=216795
Summary
System color 'canvas' cannot be set or read
Дилян Палаузов
Reported
2020-09-21 12:10:17 PDT
The way to obtain the default background color set by the user, is to call function getDefaultBackgroundColor() { let div = document.createElement("div"); div.style.backgroundColor = "canvas"; document.documentElement.appendChild(div); let color = getComputedStyle(div).backgroundColor; div.remove(); return color; } This does not work with WebKitGTK 2.28.1/Epiphany 3.36.4. In particular it allows setting custom CSS, and body.background-color in it, but it is unclear how to use the Canvas keyword as calor there. • How to configure WebKit to change the default canvas system colour, in terms of
https://www.w3.org/TR/css-color-4/#css-system-colors
• Please make the snippet above work. See also
https://bugzilla.mozilla.org/show_bug.cgi?id=1666127
and
https://gitlab.gnome.org/GNOME/epiphany/-/issues/1344
Attachments
Add attachment
proposed patch, testcase, etc.
Emilio Cobos Álvarez (:emilio)
Comment 1
2020-09-21 12:17:01 PDT
Ideally WebKit would support color: canvas and would allow users to change it, otherwise you need to use user stylesheets which don't reliably work.
Radar WebKit Bug Importer
Comment 2
2020-09-22 15:56:27 PDT
<
rdar://problem/69397317
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug