[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: color-complement for defface
From: |
Julien Danjou |
Subject: |
Re: color-complement for defface |
Date: |
Sun, 20 Feb 2011 18:44:04 +0100 |
User-agent: |
Gnus/5.110012 (No Gnus v0.12) Emacs/24.0.50 (gnu/linux) |
On Mon, Feb 14 2011, Ted Zlatanov wrote:
> TZ> Julien, do you want to propose a patch to the manual?
>
> I'll take an example, at least, and write the rest.
Sorry Ted. I had your mail tagged important, but well…
Here's a very simple example on how to use it:
#+begin_src: emacs-lisp
(defface myface
(let ((color "red"))
`((((class color) (background light))
(:foreground ,color))
(((class color) (background dark))
(:foreground ,(apply 'color-rgb->hex (color-complement color))))
(t nil)))
"My face.")
#+end_src
Obviously, a new function/macro could be created to automate this use of
color-complement.
--
Julien Danjou
❱ http://julien.danjou.info
pgp6CLpkk6s2Q.pgp
Description: PGP signature
- Re: Eliminating a couple of independent face definitions, (continued)
- Re: Eliminating a couple of independent face definitions, Jambunathan K, 2011/02/03
- RE: Eliminating a couple of independent face definitions, Drew Adams, 2011/02/05
- RE: Eliminating a couple of independent face definitions, Stephen J. Turnbull, 2011/02/06
- Re: Eliminating a couple of independent face definitions, Julien Danjou, 2011/02/04
- color-complement for defface (was: Eliminating a couple of independent face definitions), Ted Zlatanov, 2011/02/04
- Re: color-complement for defface, Ted Zlatanov, 2011/02/14
- Re: color-complement for defface,
Julien Danjou <=
- Re: Eliminating a couple of independent face definitions, Tim Cross, 2011/02/02
- Re: Eliminating a couple of independent face definitions, Dan Nicolaescu, 2011/02/03
Re: Eliminating a couple of independent face definitions, Chong Yidong, 2011/02/02
Re: Eliminating a couple of independent face definitions, Julien Danjou, 2011/02/02
Re: Eliminating a couple of independent face definitions, Štěpán Němec, 2011/02/02
FW: Eliminating a couple of independent face definitions, Drew Adams, 2011/02/02