Hello,

This is what theme generator plugins try to do : provide default faces and an API that allows users to define a theme by only specifying a set of colors and a set of overrides (if you want function-related faces to be "accent3" instead of "accent1").

Henrik tried to do it with emacs-doom-themes ( https://github.com/hlissner/emacs-doom-themes ) but apparently the theme generation part is not really good and he has been trying to find time to rewrite that part. But using that API to define a theme seems really easy : https://github.com/hlissner/emacs-doom-themes/blob/master/themes/doom-one-theme.el

I think this is the kind of helpers that would warrant upstream integration :
- Upstream can handle changes in
https://github.com/hlissner/emacs-doom-themes/blob/master/doom-themes-base.el default faces and the theme generation macro [1]
- theme writers or others end users just manage their color palette and the few faces they want to override

[1] :
https://github.com/hlissner/emacs-doom-themes/blob/d6ee47dc8ed2cf9e585f62243214af03ba5b1687/doom-themes.el#L395

On Tue, Sep 15, 2020, at 15:39, Theodor Thornhill wrote:


On September 15, 2020 12:16:42 PM GMT+02:00, Protesilaos Stavrou <info@protesilaos.com> wrote:

>The 16-colour palette that has to work on both light and dark
>backgrounds is a constraint that Emacs' defface can circumvent.  An
>excerpt from 'M-x find-library faces':
>
>(defface link
>  '((((class color) (min-colors 88) (background light))
>     :foreground "RoyalBlue3" :underline t)
>    (((class color) (background light))
>     :foreground "blue" :underline t)
>    (((class color) (min-colors 88) (background dark))
>     :foreground "cyan1" :underline t)
>    (((class color) (background dark))
>     :foreground "cyan" :underline t)
>    (t :inherit underline))
>  "Basic face for unvisited links."
>  :group 'basic-faces
>  :version "22.1")
>
>If one really wants to keep it to 16 colours, then maintain two sets of
>them.  One for dark, another for light.  And keep accessibility in mind.
>
>


Could it be an idea to generalize the modus themes? They seem very comprehensive

Theodor Thornhill



Gerry Agbobada