A dark mode for SWI Prolog?

It has been long discussions on many systems leading to most systems and apps now having default normal / dark / black modes. Maybe it would be also time for SWI-Prolog to have an automatic mode depending on system in spite of just a manual config file setup ?

Having moved from Windows to Linux Manjaro KDE Plasma configured in dark mode, i get SWI Prolog Emacs and XPCE with text on white background lost partially in windows darkened which is far from being aesthetic … though i suppose that it could be solved nicely by default with some lines of code to get the correct parameters on SWI Prolog side ?

EDIT It applies the same way for www.swi-prolog.org that is “burning eyes” when you browse in dark mode.

I’m happy to have an automatic switch between dark and light mode. I’m not aware of a sensible way to detect the desktop defaults though. There is the auto theme that uses ANSI sequences to figure out the terminal’s fore and background colors. Not all terminals support it and quite a few people run Prolog embedded in Emacs, Eclipse, VS, etc.

If anyone knows a better way to find out, please share or, better, provide patches that make the auto theme work on more platforms.

As for the website, this seems to be possible for most browsers. Requires someone to write sensible CSS though …

1 Like

My initial post was an open invitation for some members more specialized in each part to commit on Github :slight_smile: the same way @jamesnvc kindly commited on Helix for SWI-Prolog LSP integration