[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: theme and a question about creating them

From: Stefan Monnier
Subject: Re: theme and a question about creating them
Date: Thu, 06 Jan 2011 22:36:20 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (gnu/linux)

>>>> (defconst mycolor "#123456")
>>>> (deftheme mytheme)
>>>> (custom-theme-set-faces 'mytheme
>>>> `(default ((t (:background ,mycolor)))))
>>> Currently, the theme loading code is too strict about the forms in the
>>> theme file that it will evaluate.  It uses `unsafep' to check the forms,
>>> and (defconst mycolor "#123456") is considered unsafe under the criteria
>>> used by `unsafep'.
>>> I am not sure what's the best way of handling this.
>> How 'bout:
>> (deftheme mytheme)
>> (let ((mycolor "#123456"))
>> (custom-theme-set-faces 'mytheme
>> `(default ((t (:background ,mycolor))))))

> unsafep does not allow \`

I can't think of a reason why backquote wouldn't be safe, so it sounds
like it's just missing from the list of safe forms.  Or maybe it's the
general handling of macros which is at stake, but in any case it
shouldn't be unsolvable.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]