Re: Theme editor (custom-theme-visit-theme) shows only Lisp expressions for faces

[email protected]
Newsgroups gmane.emacs.help
Message-ID <[email protected]>
Teemu Likonen <[email protected]> writes:

> [1:text/plain Hide]
>
> I have a simple theme file (TL-theme.el in custom-theme-directory) which
> contains this:
>
>
>
>
> The theme editor (M-x custom-theme-visit-theme RET TL RET) shows face
> settings as Lisp expressions like this:
>
>       [X] Hide [Tab Bar] face:              [sample]
>        Tab bar face.
>     Lisp expression: 
>     ((t (:foreground "#eee" :background "#447" :inherit variable-pitch)))
>
> I would like to have them in friendly customize format which I get if I
> edit them with M-x customize-face RET tab-bar RET.
>
>     Hide [Tab Bar] face: [sample]
>        [ State ]: THEMED.
>        Tab bar face.
>        [X] Foreground: #eee           [ Choose ]  (sample)
>        [X] Background: #447           [ Choose ]  (sample)
>        [X] Inherit:
>            [INS] [DEL] Face: [link] (sample) variable-pitch
>            [INS]
>
> Is it possible to configure the theme editor to use the proper customize
> interface for face settings?

Have you considered deleting the faces (turn off the check
mark) that have the Lisp expressions, saving your theme,
load theme again, and adding the deleted faces by clicking
on ‘Insert Additional Face’ (near the end of the *Custom
Theme* buffer)?

When that is done (starting from ‘emacs -Q’), then Emacs
displays:

     [X] [Tab Bar] face: [sample]
        Tab bar face.
        [X] Foreground: black           [ Choose ]  (sample)
        [X] Background: grey85          [ Choose ]  (sample)
        [X] Inherit:
            [INS] [DEL] Face: [link] (sample) variable-pitch
            [INS]

From there, you could then choose different foreground and
background colors (and the ‘Custom’ menu item is added to
the Emacs menu line, for additional customizations).  Once
you have completed your changes and saved them, you can view
your new TL-theme.el file if you want to study what Emacs
expects in a theme definition.  (Or, you could ignore what
Lisp is required to define your theme and simply use the
Emacs *Custome Theme* interface.)

-- 
The lyf so short, the craft so long to lerne.
- Geoffrey Chaucer, The Parliament of Birds.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.