GNU bug report logs - #64695
29.0.92; xwidget webkit dark mode support or set all settings from elisp

Previous Next

Package: emacs;

Reported by: Daniel Nagy <danielnagy <at> posteo.de>

Date: Tue, 18 Jul 2023 07:20:02 UTC

Severity: wishlist

Found in version 29.0.92

To reply to this bug, email your comments to 64695 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#64695; Package emacs. (Tue, 18 Jul 2023 07:20:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Daniel Nagy <danielnagy <at> posteo.de>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Tue, 18 Jul 2023 07:20:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Daniel Nagy <danielnagy <at> posteo.de>
To: bug-gnu-emacs <at> gnu.org
Subject: 29.0.92; xwidget webkit dark mode support or set all settings from
 elisp
Date: Mon, 17 Jul 2023 20:33:22 +0000
Hello,

This is a feature request. Can xwidget webkit support the toggling of
dark mode? This is done by setting the boolean value of the gtk setting
"gtk-application-prefer-dark-theme". Better yet would be to allow to set
all kinds of gtk settings via elisp if this is somehow possible.

A good example of how dark mode can be set, can be seen in the surf
program of the suckless project:

https://git.suckless.org/surf/commit/1f5b8f3bd1f37d4d3dc45d21285f34ef4752dbaa.html

More info on the gtk setting:

https://docs.gtk.org/gtk3/property.Settings.gtk-application-prefer-dark-theme.html

Internally, this enables this css media query, to allow websites to
adapt to this user decision.

https://developer.mozilla.org/en-US/docs/Web/CSS/@media/prefers-color-scheme

Not all websites make use of this media query, but to test it out you
can check this previous link from MDN. It should turn darker if the gtk
setting is enabled correctly. The file, that would most likely to be
changed is `src/xwidget.c`.

Thank you,

In GNU Emacs 29.0.92 (build 1, x86_64-pc-linux-gnu, GTK+ Version
3.24.38, cairo version 1.16.0)
Windowing system distributor 'The X.Org Foundation', version 11.0.12101008
System Description: NixOS 23.11 (Tapir)

Configured using:
 'configure
 --prefix=/nix/store/m4wxxn3yblqsdlswa7k6rxsimyla4gca-emacs-gtk3-29.0.92
 --disable-build-details --with-modules --with-x-toolkit=gtk3 --with-xft
 --with-cairo --with-native-compilation --with-tree-sitter
 --with-xinput2 --with-xwidgets'

Configured features:
CAIRO DBUS FREETYPE GIF GLIB GMP GNUTLS GPM GSETTINGS HARFBUZZ JPEG JSON
LIBOTF LIBSELINUX LIBSYSTEMD LIBXML2 M17N_FLT MODULES NATIVE_COMP NOTIFY
INOTIFY PDUMPER PNG RSVG SECCOMP SOUND SQLITE3 THREADS TIFF
TOOLKIT_SCROLL_BARS TREE_SITTER WEBP X11 XDBE XIM XINPUT2 XPM XWIDGETS
GTK3 ZLIB

Important settings:
  value of $EMACSLOADPATH:
  value of $EMACSNATIVELOADPATH: /nix/store/ax4hv2192br3c62wqilp71w2q0m5psrm-emacs-packages-deps/share/emacs/native-lisp::
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

--
Daniel Nagy




Severity set to 'wishlist' from 'normal' Request was from Stefan Kangas <stefankangas <at> gmail.com> to control <at> debbugs.gnu.org. (Mon, 04 Sep 2023 08:21:01 GMT) Full text and rfc822 format available.

This bug report was last modified 1 year and 292 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.