branch: elpa/moe-theme
commit 3590d8034908650a227acc1ced5a4045bcb7be81
Author: kuanyui <[email protected]>
Commit: kuanyui <[email protected]>
Add Customizations!!! :heart:
---
README.md | 20 ++++++++++++++++----
moe-theme-switcher.el | 27 ++++++++++++++-------------
moe-theme.el | 21 ++++++++++++++-------
pics/mode-line-preview.png | Bin 0 -> 57263 bytes
4 files changed, 44 insertions(+), 24 deletions(-)
diff --git a/README.md b/README.md
index f74a6e04eb..a5f471045c 100644
--- a/README.md
+++ b/README.md
@@ -11,13 +11,17 @@
<a
href="https://raw.github.com/kuanyui/moe-theme.el/master/pics/light04.png"><img
src="pics/light04.png" width="355" height="192"/></a>
<a
href="https://raw.github.com/kuanyui/moe-theme.el/master/pics/dark05.png"><img
src="pics/dark05.png" width="355" height="192"/></a>
<a
href="https://raw.github.com/kuanyui/moe-theme.el/master/pics/light05.png"><img
src="pics/light05.png" width="355" height="192"/></a>
+<a
href="https://raw.github.com/kuanyui/moe-theme.el/master/pics/mode-line-preview.png"><img
src="pics/mode-line-preview.png" width="710" height="182"/></a>
## What Special?
* Optimized for terminal's 256 color palettes.
* Black-on-white & white-on-black.
* Delightful and cheerful color palettes.
-* Quite completed font faces for each mode.
-* Automatically switch between dark and light `moe-theme` by local time!
(optional)
+* Quite completed (and reasonable) font faces for each mode.
+* **Easy to customize!**
+ * Colorful Mode-line / Powerline.
+ * Enlarge titles font sizes or not.
+ * Automatically switch between dark and light `moe-theme` by local time!
(optional)
## Support
`moe-theme.el` provide good-looking™ and quite fully-supported font-faces for
various modes, include:
@@ -53,7 +57,7 @@ Download the archive of `moe-theme` to `~/.emacs.d/themes`
and extract it. Then,
```
## Customizations
-It's impossible to satisfy everyone with one theme, but `moe-theme` provide
some customizations that you may like.
+It's impossible to satisfy everyone with one fixed theme, but `moe-theme`
provide some customizations that you may like.
Select a theme you like and let's go on:
@@ -102,13 +106,21 @@ Mayby you'll also like `moe-theme-random-color`, which
gives you a random mood :
Now `moe-theme` supports
[Powerline](https://github.com/milkypostman/powerline), which makes mode-line
looks fabulous! We recommended installing `powerline` and run
`powerline-moe-theme`.
### Too Yellow Background?
-With 256-colors, default yellow background of moe-light may be too yellow on
some screens.
+With 256-colors terminal, default yellow background of moe-light may be too
yellow and harsh to eyes on some screens.
If you encounter this problem, and want to set background color to `#ffffff`
in terminal, set the value of `moe-light-pure-white-background-in-terminal` to
t:
```lisp
(setq moe-light-pure-white-background-in-terminal t)
```
+
+### Highlight Buffer-id on Mode-line?
+You may be dislike default highlight on mode-line-buffer-id, now it can be
disable:
+
+```lisp
+(setq moe-theme-highlight-buffer-id nil)
+```
+
## Have A Good Mood Today?
I prefer a terminal with a black-on-white color scheme. I found that in the
daytime, sunlight is strong and black-on-white is more readable; However,
white-on-black would be less harsh to the eyes at night.
diff --git a/moe-theme-switcher.el b/moe-theme-switcher.el
index edb139ef7e..d475f10780 100644
--- a/moe-theme-switcher.el
+++ b/moe-theme-switcher.el
@@ -1,7 +1,7 @@
;; moe-theme-switcher.el
;; Author: kuanyui ([email protected])
;; Date: 2013/05/11 11:39
-;;
+;;
;; This file is not a part of GNU Emacs,
;; but this file is released under GPL v3.
@@ -12,9 +12,11 @@
(defvar moe-theme-switch-by-sunrise-and-sunset t
"Automatically switch between dark and light moe-theme.
-If this value is nil, moe-theme will switch at fixed time (06:00 and 18:00).
+If this value is nil, moe-theme will switch at fixed time (06:00 and 18:00).
-If this value is t and both calendar-latitude and calendar-longitude are set
properly, the switching will be triggered at the sunrise and sunset time of the
local calendar.
+If this value is t and both calendar-latitude and calendar-longitude are set
+properly, the switching will be triggered at the sunrise and sunset time of the
+local calendar.
Take Keelung, Taiwan(25N,121E) for example, you can set like this:
@@ -68,7 +70,7 @@ Take Keelung, Taiwan(25N,121E) for example, you can set like
this:
(let (rise_set a b c d e f)
(setq rise_set (get-sunrise-sunset-string))
(if (string-match "0:00 hours daylight" rise_set) ;If polar-night
- (progn
+ (progn
(setq 24h/sunrise 'polar-night
24h/sunset 'polar-night))
(if (string-match "24:00 hours daylight" rise_set) ;If midnight-sun
@@ -100,14 +102,14 @@ Take Keelung, Taiwan(25N,121E) for example, you can set
like this:
(let ((now (list (string-to-number (format-time-string "%H"))
(string-to-number (format-time-string "%M")))))
(if (and (or ;magic-logic [tm]
- (> (car now) (car 24h/sunrise))
- (and
- (= (car now) (car 24h/sunrise))
- (>= (second now) (second 24h/sunrise))))
- (or
- (< (car now) (car 24h/sunset))
- (and
- (= (car now) (car 24h/sunset))
+ (> (car now) (car 24h/sunrise))
+ (and
+ (= (car now) (car 24h/sunrise))
+ (>= (second now) (second 24h/sunrise))))
+ (or
+ (< (car now) (car 24h/sunset))
+ (and
+ (= (car now) (car 24h/sunset))
(< (second now) (second 24h/sunset)))))
(moe-load-theme 'light)
(moe-load-theme 'dark)
@@ -141,4 +143,3 @@ Take Keelung, Taiwan(25N,121E) for example, you can set
like this:
(moe-theme-auto-switch)
(provide 'moe-theme-switcher)
-
diff --git a/moe-theme.el b/moe-theme.el
index eddb70f96e..fc4e31d447 100644
--- a/moe-theme.el
+++ b/moe-theme.el
@@ -36,7 +36,7 @@
;; It's impossible to satisfy everyone with one theme, so `moe-theme`
provide
;; some customizations that you may like.
;;
-;; # Resize Titles
##########################################################
+;; ### Resize Titles
########################################################
;;
;; You may want to resize the titles in `markdown-mode', `org-mode', or
;; `rst-mode':
@@ -51,7 +51,7 @@
;; If you don't like this, just leave them nil, and all the titles will be
;; the same size.
;;
-;; # Colorful Mode-line and Powerline
#######################################
+;; ### Colorful Mode-line and Powerline
#####################################
;;
;; Tired of boring blue mode-line? Set default mode-line color like this:
;;
@@ -64,7 +64,7 @@
;; Mayby you'll also like `moe-theme-random-color', which gives you a
;; random mood :D.
;;
-;; # Powerline
##############################################################
+;; ### Powerline
############################################################
;;
;; Now we supports Powerline (https://github.com/milkypostman/powerline),
;; which makes mode-line looks fabulous! We recommended installing Powerline
@@ -73,7 +73,7 @@
;; ### Too Yellow Background?
###############################################
;;
;; With 256-colors, default yellow background of moe-light may be too yellow
-;; on some screens.
+;; and harsh to eyes on some screens.
;;
;; If you encounter this problem, and want to set background color to
#ffffff
;; in terminal, set the value of
`moe-light-pure-white-background-in-terminal'
@@ -81,6 +81,13 @@
;;
;; (setq moe-light-pure-white-background-in-terminal t)
;;
+;; ### Highlight Buffer-id on Mode-line?
####################################
+;;
+;; You may be dislike default highlight on mode-line-buffer-id, now it can
be
+;; disable:
+;;
+;; (setq moe-theme-highlight-buffer-id nil)
+;;
;;
;; = Auto Switching
============================================================
;;
@@ -350,7 +357,7 @@ You may also like `moe-theme-random-color'"
(setq moe-theme-mode-line-color
(intern (completing-read
"Select a color: "
- '((blue) (orange) (magenta) (yellow) (purple) (red) (cyan)
(w/b))
+ '((blue) (green) (orange) (magenta) (yellow) (purple) (red)
(cyan) (w/b))
nil t "" nil nil t)))
(if (eq (frame-parameter nil 'background-mode) 'light)
(moe-light)
@@ -361,9 +368,9 @@ You may also like `moe-theme-random-color'"
(defun moe-theme-random-color ()
"Give me a random mode-line color.=w=+"
(interactive)
- (let* ((n (abs (% (random) 8)))
+ (let* ((n (abs (% (random) 9)))
(current-color moe-theme-mode-line-color)
- (color-list '(blue orange magenta yellow purple red cyan w/b)))
+ (color-list '(blue green orange magenta yellow purple red cyan w/b)))
(if (eq (elt color-list n) current-color) ;If gotten color eq
current-color, random again.
(moe-theme-random-color)
(setq moe-theme-mode-line-color (elt color-list n)))
diff --git a/pics/mode-line-preview.png b/pics/mode-line-preview.png
new file mode 100644
index 0000000000..d48ac26f0c
Binary files /dev/null and b/pics/mode-line-preview.png differ