diff options
| author | Chong Yidong | 2011-06-14 01:00:35 -0400 |
|---|---|---|
| committer | Chong Yidong | 2011-06-14 01:00:35 -0400 |
| commit | b9958282dc60f74c942f34412123ddc76f7c592e (patch) | |
| tree | 5b848b8f3c9e83f54acd4fab96f306e1e6ba22b6 | |
| parent | d647b7c44e4205c50b29d1533880e9ae7ce0bea6 (diff) | |
| download | emacs-b9958282dc60f74c942f34412123ddc76f7c592e.tar.gz emacs-b9958282dc60f74c942f34412123ddc76f7c592e.zip | |
* etc/themes/dichromacy-theme.el: New theme.
| -rw-r--r-- | etc/ChangeLog | 4 | ||||
| -rw-r--r-- | etc/themes/dichromacy-theme.el | 127 |
2 files changed, 131 insertions, 0 deletions
diff --git a/etc/ChangeLog b/etc/ChangeLog index 78c19326afe..109124af4ee 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog | |||
| @@ -1,3 +1,7 @@ | |||
| 1 | 2011-06-14 Chong Yidong <cyd@stupidchicken.com> | ||
| 2 | |||
| 3 | * themes/dichromacy-theme.el: New theme. | ||
| 4 | |||
| 1 | 2011-06-07 Paul Eggert <eggert@cs.ucla.edu> | 5 | 2011-06-07 Paul Eggert <eggert@cs.ucla.edu> |
| 2 | 6 | ||
| 3 | * NEWS: Mention new configure option --with-wide-int. | 7 | * NEWS: Mention new configure option --with-wide-int. |
diff --git a/etc/themes/dichromacy-theme.el b/etc/themes/dichromacy-theme.el new file mode 100644 index 00000000000..0105080ab08 --- /dev/null +++ b/etc/themes/dichromacy-theme.el | |||
| @@ -0,0 +1,127 @@ | |||
| 1 | ;;; dichromacy-theme.el --- color theme suitable for color-blind users | ||
| 2 | |||
| 3 | ;; Copyright (C) 2011 Free Software Foundation, Inc. | ||
| 4 | |||
| 5 | ;; Author: Chong Yidong <cyd@stupidchicken> | ||
| 6 | |||
| 7 | ;; This file is part of GNU Emacs. | ||
| 8 | |||
| 9 | ;; GNU Emacs is free software: you can redistribute it and/or modify | ||
| 10 | ;; it under the terms of the GNU General Public License as published by | ||
| 11 | ;; the Free Software Foundation, either version 3 of the License, or | ||
| 12 | ;; (at your option) any later version. | ||
| 13 | |||
| 14 | ;; GNU Emacs is distributed in the hope that it will be useful, | ||
| 15 | ;; but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | ;; GNU General Public License for more details. | ||
| 18 | |||
| 19 | ;; You should have received a copy of the GNU General Public License | ||
| 20 | ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. | ||
| 21 | |||
| 22 | ;;; Code: | ||
| 23 | |||
| 24 | (deftheme dichromacy | ||
| 25 | "Face colors suitable for red/green color-blind users. | ||
| 26 | The color palette is from B. Wong, Nature Methods 8, 441 (2011). | ||
| 27 | It is intended to provide good variability while being easily | ||
| 28 | differentiated by individuals with protanopia or deuteranopia. | ||
| 29 | |||
| 30 | Basic, Font Lock, Isearch, Gnus, Message, Flyspell, and | ||
| 31 | Ansi-Color faces are included.") | ||
| 32 | |||
| 33 | (let ((class '((class color) (min-colors 89))) | ||
| 34 | (orange "#e69f00") | ||
| 35 | (skyblue "#56b4e9") | ||
| 36 | (bluegreen "#009e73") | ||
| 37 | (yellow "#f8ec59") | ||
| 38 | (blue "#0072b2") | ||
| 39 | (vermillion "#d55e00") | ||
| 40 | (redpurple "#cc79a7") | ||
| 41 | (bluegray "#848ea9")) | ||
| 42 | (custom-theme-set-faces | ||
| 43 | 'dichromacy | ||
| 44 | `(default ((,class (:foreground "black" :background "white")))) | ||
| 45 | `(cursor ((,class (:foreground "white" :background "black")))) | ||
| 46 | ;; Highlighting faces | ||
| 47 | `(fringe ((,class (:background "#f7f7f7")))) | ||
| 48 | `(highlight ((,class (:foreground ,blue :background "#e5e5e5")))) | ||
| 49 | `(region ((,class (:foreground unspecified :background ,yellow)))) | ||
| 50 | `(secondary-selection ((,class (:background "#e5e5e5")))) | ||
| 51 | `(isearch ((,class (:foreground "white" :background ,vermillion)))) | ||
| 52 | `(lazy-highlight ((,class (:foreground "white" :background ,redpurple)))) | ||
| 53 | `(trailing-whitespace ((,class (:background ,vermillion)))) | ||
| 54 | ;; Mode line faces | ||
| 55 | `(mode-line ((,class (:box (:line-width -1 :style released-button) | ||
| 56 | :background "#e5e5e5" :foreground "black")))) | ||
| 57 | `(mode-line-inactive ((,class (:box (:line-width -1 :style released-button) | ||
| 58 | :background "#b0b0b0" | ||
| 59 | :foreground "black")))) | ||
| 60 | ;; Escape and prompt faces | ||
| 61 | `(minibuffer-prompt ((,class (:weight bold :foreground ,blue)))) | ||
| 62 | `(escape-glyph ((,class (:foreground ,vermillion)))) | ||
| 63 | ;; Font lock faces | ||
| 64 | `(font-lock-builtin-face ((,class (:foreground ,blue)))) | ||
| 65 | `(font-lock-comment-face ((,class (:slant italic :foreground ,bluegreen)))) | ||
| 66 | `(font-lock-constant-face ((,class (:weight bold :foreground ,vermillion)))) | ||
| 67 | `(font-lock-function-name-face ((,class (:foreground ,vermillion)))) | ||
| 68 | `(font-lock-keyword-face ((,class (:weight bold :foreground ,skyblue)))) | ||
| 69 | `(font-lock-string-face ((,class (:foreground ,bluegray)))) | ||
| 70 | `(font-lock-type-face ((,class (:weight bold :foreground ,blue)))) | ||
| 71 | `(font-lock-variable-name-face ((,class (:weight bold :foreground ,orange)))) | ||
| 72 | `(font-lock-warning-face ((,class (:weight bold :slant italic | ||
| 73 | :foreground ,vermillion)))) | ||
| 74 | ;; Button and link faces | ||
| 75 | `(button ((,class (:underline t :foreground ,blue)))) | ||
| 76 | `(link ((,class (:underline t :foreground ,blue)))) | ||
| 77 | `(link-visited ((,class (:underline t :foreground ,redpurple)))) | ||
| 78 | ;; Gnus faces | ||
| 79 | `(gnus-group-news-1 ((,class (:weight bold :foreground ,vermillion)))) | ||
| 80 | `(gnus-group-news-1-low ((,class (:foreground ,vermillion)))) | ||
| 81 | `(gnus-group-news-2 ((,class (:weight bold :foreground ,orange)))) | ||
| 82 | `(gnus-group-news-2-low ((,class (:foreground ,orange)))) | ||
| 83 | `(gnus-group-news-3 ((,class (:weight bold :foreground ,skyblue)))) | ||
| 84 | `(gnus-group-news-3-low ((,class (:foreground ,skyblue)))) | ||
| 85 | `(gnus-group-news-4 ((,class (:weight bold :foreground ,redpurple)))) | ||
| 86 | `(gnus-group-news-4-low ((,class (:foreground ,redpurple)))) | ||
| 87 | `(gnus-group-news-5 ((,class (:weight bold :foreground ,blue)))) | ||
| 88 | `(gnus-group-news-5-low ((,class (:foreground ,blue)))) | ||
| 89 | `(gnus-group-news-low ((,class (:foreground ,bluegreen)))) | ||
| 90 | `(gnus-group-mail-1 ((,class (:weight bold :foreground ,vermillion)))) | ||
| 91 | `(gnus-group-mail-1-low ((,class (:foreground ,vermillion)))) | ||
| 92 | `(gnus-group-mail-2 ((,class (:weight bold :foreground ,orange)))) | ||
| 93 | `(gnus-group-mail-2-low ((,class (:foreground ,orange)))) | ||
| 94 | `(gnus-group-mail-3 ((,class (:weight bold :foreground ,skyblue)))) | ||
| 95 | `(gnus-group-mail-3-low ((,class (:foreground ,skyblue)))) | ||
| 96 | `(gnus-group-mail-low ((,class (:foreground ,bluegreen)))) | ||
| 97 | `(gnus-header-content ((,class (:foreground ,redpurple)))) | ||
| 98 | `(gnus-header-from ((,class (:weight bold :foreground ,blue)))) | ||
| 99 | `(gnus-header-subject ((,class (:foreground ,orange)))) | ||
| 100 | `(gnus-header-name ((,class (:foreground ,skyblue)))) | ||
| 101 | `(gnus-header-newsgroups ((,class (:foreground ,vermillion)))) | ||
| 102 | ;; Message faces | ||
| 103 | `(message-header-name ((,class (:foreground ,skyblue)))) | ||
| 104 | `(message-header-cc ((,class (:foreground ,vermillion)))) | ||
| 105 | `(message-header-other ((,class (:foreground ,bluegreen)))) | ||
| 106 | `(message-header-subject ((,class (:foreground ,orange)))) | ||
| 107 | `(message-header-to ((,class (:weight bold :foreground ,blue)))) | ||
| 108 | `(message-cited-text ((,class (:slant italic :foreground ,bluegreen)))) | ||
| 109 | `(message-separator ((,class (:weight bold :foreground ,redpurple)))) | ||
| 110 | ;; Flyspell | ||
| 111 | `(flyspell-duplicate ((,class (:weight unspecified :foreground unspecified | ||
| 112 | :slant unspecified :underline ,orange)))) | ||
| 113 | `(flyspell-incorrect ((,class (:weight unspecified :foreground unspecified | ||
| 114 | :slant unspecified :underline ,redpurple))))) | ||
| 115 | |||
| 116 | (custom-theme-set-variables | ||
| 117 | 'dichromacy | ||
| 118 | `(ansi-color-names-vector ["black" ,vermillion ,bluegreen ,yellow | ||
| 119 | ,blue ,redpurple ,skyblue "white"]))) | ||
| 120 | |||
| 121 | (provide-theme 'dichromacy) | ||
| 122 | |||
| 123 | ;; Local Variables: | ||
| 124 | ;; no-byte-compile: t | ||
| 125 | ;; End: | ||
| 126 | |||
| 127 | ;;; dichromacy-theme.el ends here | ||