aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--etc/themes/simple-16-theme.el141
1 files changed, 141 insertions, 0 deletions
diff --git a/etc/themes/simple-16-theme.el b/etc/themes/simple-16-theme.el
new file mode 100644
index 00000000000..83f22122967
--- /dev/null
+++ b/etc/themes/simple-16-theme.el
@@ -0,0 +1,141 @@
1;;; simple-16-theme.el --- Custom theme for faces -*- lexical-binding:t -*-
2
3;; Copyright (C) 2020 Free Software Foundation, Inc.
4
5;; Author: Jimmy Aguilar Mena <spacibba@aol.com>
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 <https://www.gnu.org/licenses/>.
21
22;;; Code:
23
24(deftheme simple-16
25 "Dark theme with a set of simple 16 colors only.")
26
27(defmacro simple-16-theme-color (colorname)
28 "Get color by name COLORNAME from `simple-16-color-theme-alist'."
29 (alist-get colorname '((black . "#000000")
30 (red . "#cd0000")
31 (green . "#00cd00")
32 (yellow . "#cdcd00")
33 (blue . "#0000ee")
34 (magenta . "#cd00cd")
35 (cyan . "#00cdcd")
36 (white . "#e5e5e5")
37 (brightblack . "#444444") ;;
38 (brightred . "#ff0000")
39 (brightgreen . "#00ff00")
40 (brightyellow . "#ffff00")
41 (brightblue . "#5c5cff")
42 (brightmagenta . "#ff00ff")
43 (brightcyan . "#00ffff")
44 (brightwhite . "#ffffff"))))
45
46(custom-theme-set-faces
47 'simple-16
48 `(default ((t (:background ,(simple-16-theme-color black)
49 :foreground ,(simple-16-theme-color white)))))
50
51 `(font-lock-preprocessor-face ((t (:foreground ,(simple-16-theme-color magenta)))))
52 `(font-lock-comment-face ((t (:foreground ,(simple-16-theme-color cyan)))))
53 `(font-lock-doc-face ((t (:foreground ,(simple-16-theme-color cyan)))))
54 `(font-lock-string-face ((t (:foreground ,(simple-16-theme-color red)))))
55 `(font-lock-function-name-face ((t (:foreground ,(simple-16-theme-color white)))))
56 `(font-lock-variable-name-face ((t (:foreground ,(simple-16-theme-color white)))))
57 `(font-lock-constant-face ((t (:foreground ,(simple-16-theme-color magenta)))))
58 `(font-lock-type-face ((t (:foreground ,(simple-16-theme-color green)))))
59 `(font-lock-keyword-face ((t (:foreground ,(simple-16-theme-color yellow)))))
60 `(font-lock-builtin-face ((t (:foreground ,(simple-16-theme-color green)))))
61
62 `(highlight ((t (:background ,(simple-16-theme-color brightblack)
63 :foreground nil))))
64 `(secondary-selection ((t (:background ,(simple-16-theme-color brightblack)
65 :foreground nil))))
66
67 `(isearch ((t (:background ,(simple-16-theme-color blue)
68 :foreground ,(simple-16-theme-color white)
69 :weight ultrabold))))
70 `(lazy-highlight ((t (:background ,(simple-16-theme-color brightblue)))))
71
72 `(region ((t (:background ,(simple-16-theme-color brightblue)))))
73
74 `(mode-line ((t (:background ,(simple-16-theme-color blue)
75 :foreground ,(simple-16-theme-color white)))))
76 `(mode-line-inactive ((t (:background ,(simple-16-theme-color brightblack)
77 :foreground ,(simple-16-theme-color white)))))
78
79 `(line-number ((t (:foreground ,(simple-16-theme-color brightblack)))))
80 `(line-number-current-line ((t (:foreground ,(simple-16-theme-color green)))))
81 `(fill-column-indicator ((t (:foreground ,(simple-16-theme-color brightblack)))))
82
83 `(show-paren-match ((t (:background ,(simple-16-theme-color brightblack)
84 :inherit nil))))
85
86 `(tab-bar ((t (:background ,(simple-16-theme-color black)
87 :foreground ,(simple-16-theme-color white)
88 :inverse-video nil))))
89 `(tab-bar-tab ((t (:inherit tab-bar :weight ultra-bold :underline t))))
90
91 `(tab-bar-tab-inactive ((t (:background ,(simple-16-theme-color black)
92 :foreground ,(simple-16-theme-color brightwhite)
93 :weight normal
94 :underline nil))))
95
96 `(Man-overstrike ((t (:inherit font-lock-type-face :bold t))))
97 `(Man-overstrike ((t (:inherit font-lock-keyword-face :underline t))))
98
99 `(which-func ((t (:background nil :foreground ,(simple-16-theme-color white)))))
100
101 ;; External packages
102 ;; Company
103 `(company-tooltip ((t (:background ,(simple-16-theme-color brightblack)
104 :foreground ,(simple-16-theme-color white)))))
105 `(company-tooltip-common ((t (:inherit company-tooltip
106 :foreground ,(simple-16-theme-color green)))))
107 `(company-tooltip-selection ((t (:background ,(simple-16-theme-color blue)
108 :weight ultra-bold))))
109 `(company-scrollbar-bg ((t (:background ,(simple-16-theme-color brightblack)))))
110 `(company-scrollbar-fg ((t (:background ,(simple-16-theme-color blue)))))
111
112 `(company-scrollbar-fg ((t (:foreground ,(simple-16-theme-color cyan)))))
113
114 ;; Ivy
115 `(ivy-minibuffer-match-face-1 ((t (:inherit nil :background nil
116 :foreground nil
117 :underline t))))
118 ;; Ivy like lazy-highlight
119 `(ivy-minibuffer-match-face-2 ((t (:background ,(simple-16-theme-color brightblue)))))
120 `(ivy-minibuffer-match-face-3 ((t (:background ,(simple-16-theme-color brightblue)))))
121 `(ivy-minibuffer-match-face-4 ((t (:background ,(simple-16-theme-color brightblue)))))
122
123 ;; Swiper
124 `(swiper-match-face-1 ((t (:inherit nil :background nil :underline t))))
125 ;; Swiper like lazy-highlight
126 `(swiper-background-match-face-2 ((t (:background ,(simple-16-theme-color brightblue)))))
127 `(swiper-background-match-face-3 ((t (:background ,(simple-16-theme-color brightblue)))))
128 `(swiper-background-match-face-4 ((t (:background ,(simple-16-theme-color brightblue)))))
129 ;; Swiper background like isearch
130 `(swiper-match-face-2 ((t (:background ,(simple-16-theme-color brightblue)))))
131 `(swiper-match-face-3 ((t (:background ,(simple-16-theme-color brightblue)))))
132 `(swiper-match-face-4 ((t (:background ,(simple-16-theme-color brightblue)))))
133
134 ;; Avy
135 `(avy-lead-face ((t (:background ,(simple-16-theme-color blue)
136 :foreground ,(simple-16-theme-color red)))))
137 )
138
139(provide-theme 'simple-16)
140
141;;; simple-16-theme.el ends here