cyruseuros / ewal

GNU General Public License v3.0
29 stars 2 forks source link

[[https://melpa.org/#/ewal][file:https://melpa.org/packages/ewal-badge.svg]] [[https://melpa.org/#/ewal-spacemacs-themes][file:https://melpa.org/packages/ewal-spacemacs-themes-badge.svg]] [[https://melpa.org/#/ewal-evil-cursors][file:https://melpa.org/packages/ewal-evil-cursors-badge.svg]]

[[./img/ewal.png]]

A dependency-free, pywal-based, automatic, terminal-aware Emacs color-picker and theme generator.

It adds extra shades to =pywal= palettes and makes your Emacs look sexy in a GUI and in a terminal (=pywal= users only). =ewal-spacemacs-themes= shows what ewal can do in 400 flavors of =spacemacs-theme= and =doom-themes=, while =ewal-evil-cursors= spices up, well, your evil cursors. It also provides a function to colorize =spaceline= accordingly. All these packages (with the excepton of doom themes) are available on MELPA.

Get a color and a specific shade (+ for ligther, - for darker):

+BEGIN_SRC emacs-lisp :tangle yes

(ewal-load-color 'magenta +4)

+END_SRC

Use built-in palettes if your =pywal= theme fails to load (otherwise you just get a black-and-white theme and something about color being nil):

+BEGIN_SRC emacs-lisp :tangle yes

(setq ewal-use-built-in-on-failure-p t)

+END_SRC

Always use built-in palettes:

+BEGIN_SRC emacs-lisp :tangle yes

(setq ewal-use-built-in-always-p t)

+END_SRC

Pick a built-in palette:

+BEGIN_SRC emacs-lisp :tangle yes

(setq ewal-built-in-palette "sexy-material")

+END_SRC

Set custom folder and custom filename for =pywal= scheme (if you use =wpgtk= or keep your own palette somewhere on your system):

+BEGIN_SRC emacs-lisp :tangle yes

(setq ewal-json-file "~/path/to/cache-file")

+END_SRC

Use special cursor for insert state when evil insert bindings are disabled:

+BEGIN_SRC emacs-lisp :tangle yes

(setq ewal-evil-cursors-obey-evil-p t)

+END_SRC

My config with all its warts:

+BEGIN_SRC emacs-lisp :tangle yes

(use-package ewal :init (setq ewal-use-built-in-always-p nil ewal-use-built-in-on-failure-p t ewal-built-in-palette "sexy-material")) (use-package ewal-spacemacs-themes :init (progn (setq spacemacs-theme-underline-parens t my:rice:font (font-spec :family "Source Code Pro" :weight 'semi-bold :size 11.0)) (show-paren-mode +1) (global-hl-line-mode) (set-frame-font my:rice:font nil t) (add-to-list 'default-frame-alist `(font . ,(font-xlfd-name my:rice:font)))) :config (progn (load-theme 'ewal-spacemacs-modern t) (enable-theme 'ewal-spacemacs-modern))) (use-package ewal-evil-cursors :after (ewal-spacemacs-themes) :config (ewal-evil-cursors-get-colors :apply t :spaceline t)) (use-package spaceline :after (ewal-evil-cursors winum) :init (setq powerline-default-separator nil) :config (spaceline-spacemacs-theme))

+END_SRC