summaryrefslogtreecommitdiffhomepage
path: root/init.org
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2021-02-04 04:19:56 +0000
committerjao <jao@gnu.org>2021-02-04 04:19:56 +0000
commit8fa19bbfabbb0137b89d7bdaaa6f1d5ea5620957 (patch)
tree124430d3fd4629e1356465964a88348e073b49fe /init.org
parentc7b27f44ae23c29d773fad4dffb1d635eea89350 (diff)
downloadelibs-8fa19bbfabbb0137b89d7bdaaa6f1d5ea5620957.tar.gz
elibs-8fa19bbfabbb0137b89d7bdaaa6f1d5ea5620957.tar.bz2
themes spring cleaning
Diffstat (limited to 'init.org')
-rw-r--r--init.org174
1 files changed, 50 insertions, 124 deletions
diff --git a/init.org b/init.org
index a72a5ad..64e0cf1 100644
--- a/init.org
+++ b/init.org
@@ -123,6 +123,7 @@
(load custom-file)
(setq custom-unlispify-tag-names nil)
(setq custom-buffer-done-kill t)
+ (setq custom-raised-buttons nil)
#+end_src
*** Preamble (pre.el)
#+begin_src emacs-lisp
@@ -230,6 +231,16 @@
(defun jao-kb-toggled-p ()
(not (string-empty-p
(shell-command-to-string "setxkbmap -query|grep variant"))))
+
+ (set-keyboard-coding-system 'latin-1)
+ (setq default-input-method "catalan-prefix")
+ (set-language-environment "UTF-8")
+
+ (defun jao--set-kb-system (frame)
+ (select-frame frame)
+ (set-keyboard-coding-system 'latin-1)
+ t)
+ (add-to-list 'after-make-frame-functions 'jao--set-kb-system)
#+end_src
*** Battery
#+BEGIN_SRC emacs-lisp
@@ -269,7 +280,7 @@
(use-package pinentry :ensure t)
(pinentry-start)
#+end_src
-* Colours and themes
+* Fonts and colour themes
*** Transparency
#+begin_src emacs-lisp
(defvar jao-frames-default-alpha (if (eq window-system 'pgtk) 96 90))
@@ -299,35 +310,39 @@
(set-frame-parameter nil 'alpha (list level level))
(jao-sway-set-transparency))
#+end_src
-*** Faces, fonts, fontsets
-***** General
+*** Fonts
+***** Unicode fonts
+ See [[https://emacs.stackexchange.com/questions/251/line-height-with-unicode-characters/5386#5386][fonts - Line height with unicode characters]] for a good
+ discussion.
#+BEGIN_SRC emacs-lisp
- ;;; Font lock
- (global-font-lock-mode 1)
-
- ;; customize buttons
- (setq custom-raised-buttons nil)
-
- ;; language environment
- (set-language-environment "UTF-8")
- (set-keyboard-coding-system 'latin-1)
-
- (setq default-input-method "catalan-prefix")
- (defun jao--set-kb-system (frame)
- (select-frame frame)
- (set-keyboard-coding-system 'latin-1)
- t)
+ (defun jao--set-fontsets (frame)
+ ;; (set-fontset-font t 'unicode "Hack-9")
+ (set-fontset-font t 'greek "GFS Didot")
+ (set-fontset-font t 'mathematical "FreeSerif")
+ (set-fontset-font t 64257 "Quivira")
+ (set-fontset-font t 65039 nil)
+ (set-fontset-font t '(9472 . 9599) "Symbola")
+ (set-fontset-font t 'symbol "Symbola-12") ;; "Noto Sans Symbols-10"
+ ;; (set-fontset-font t 'symbol "Unifont-12")
+ (set-fontset-font t 'egyptian "Noto Sans Egyptian Hieroglyphs")
+ (set-fontset-font t 'hangul "NanumGothicCoding"))
+ (add-to-list 'after-make-frame-functions 'jao--set-fontsets)
- (add-to-list 'after-make-frame-functions 'jao--set-kb-system)
+ ;; (use-package unicode-fonts :ensure t)
+ ;; (unicode-fonts-setup)
+ #+END_SRC
+***** list-fonts-display
+ #+begin_src emacs-lisp
(defun list-fonts-display (&optional matching)
"Display a list of font-families available via font-config, in a new buffer.
- If the optional argument MATCHING is non-nil, only font families
- matching that regexp are displayed; interactively, a prefix
- argument will prompt for the regexp.
- The name of each font family is displayed using that family, as
- well as in the default font (to handle the case where a font
- cannot be used to display its own name)."
+ If the optional argument MATCHING is non-nil, only
+ font families matching that regexp are displayed;
+ interactively, a prefix argument will prompt for the
+ regexp. The name of each font family is displayed
+ using that family, as well as in the default font (to
+ handle the case where a font cannot be used to display
+ its own name)."
(interactive
(list
(and current-prefix-arg
@@ -363,118 +378,29 @@
(newline)))
(goto-char (point-min)))
(display-buffer buf))))
- #+END_SRC
-***** Unicode fonts
- See [[https://emacs.stackexchange.com/questions/251/line-height-with-unicode-characters/5386#5386][fonts - Line height with unicode characters]] for a good
- discussion.
- #+BEGIN_SRC emacs-lisp
- (defun jao--set-fontsets (frame)
- ;; (set-fontset-font t 'unicode "Hack-9")
- (set-fontset-font t 'greek "GFS Didot")
- (set-fontset-font t 'mathematical "FreeSerif")
- (set-fontset-font t 64257 "Quivira")
- (set-fontset-font t 65039 nil)
- (set-fontset-font t '(9472 . 9599) "Symbola")
- (set-fontset-font t 'symbol "Symbola-12") ;; "Noto Sans Symbols-10"
- ;; (set-fontset-font t 'symbol "Unifont-12")
- (set-fontset-font t 'egyptian "Noto Sans Egyptian Hieroglyphs")
- (set-fontset-font t 'hangul "NanumGothicCoding"))
- (add-to-list 'after-make-frame-functions 'jao--set-fontsets)
-
- ;; (use-package unicode-fonts :ensure t)
- ;; (unicode-fonts-setup)
-
- #+END_SRC
+ #+end_src
*** Themes
- #+BEGIN_SRC emacs-lisp
- (defvar jao-colors-use-light-scheme t)
- (defvar jao-colors-theme nil)
-
+ #+begin_src emacs-lisp
(defun jao-colors-scheme-dark-p ()
(equal "dark" (getenv "JAO_COLOR_SCHEME")))
(setq custom-theme-directory
(expand-file-name "lib/themes" jao-emacs-dir))
- (setq jao-frames-default-font "Hack-9") ;; "Iosevka-10"
-
- (if (or (not window-system) (jao-colors-scheme-dark-p))
- (setq jao-colors-use-light-scheme nil
- jao-colors-theme nil ;; 'doom
- jao-colors-theme
- (if (or (daemonp) window-system) jao-colors-theme 'console)
- jao-colors-doom-theme 'doom-tomorrow-night
- jao-colors-doom-theme 'doom-wilmersdorf
- jao-colors-doom-theme 'doom-nord
- jao-colors-doom-theme 'doom-sourcerer
- jao-frames-fringe-mode nil
- jao-vc-use-diff-hl t)
- (setq jao-colors-use-light-scheme t
- jao-colors-theme nil ;; 'doom
- ;; jao-colors-theme 'solarized-light
- jao-colors-doom-theme 'doom-solarized-light
- jao-vc-use-diff-hl t
- jao-frames-fringe-mode nil))
-
- ;; notification colors
- (setq jao-osd-cat-color-bg
- (if jao-colors-use-light-scheme "grey30" "white")
- jao-osd-cat-color-fg
- (if jao-colors-use-light-scheme "white" "grey30"))
+ (setq jao-frames-default-font "Hack-9")
(require 'jao-themes)
- (when (eq jao-colors-theme 'solarized)
- (use-package solarized-theme
- :ensure t
- :init (setq solarized-distinct-doc-face t
- solarized-distinct-fringe-background nil
- solarized-scale-org-headlines nil
- solarized-scale-outline-headlines nil
- solarized-use-variable-pitch nil
- solarized-use-less-bold t
- solarized-use-more-italic t)))
-
- (when (eq jao-colors-theme 'doom)
- (use-package doom-themes
- :ensure t
- :init (setq doom-nord-region-highlight 'frost
- doom-nord-brighter-modeline t
- doom-nord-light-region-highlight 'frost
- doom-nord-light-brighter-modeline t)))
-
- (when (eq jao-colors-theme 'modus)
- (use-package modus-operandi-theme
- :ensure t
- :init (setq modus-operandi-theme-completions 'opinionated
- modus-operandi-theme-diffs 'desaturated
- modus-operandi-theme-mode-line nil))
-
- (use-package modus-vivendi-theme
- :ensure t
- :init (setq modus-vivendi-theme-completions 'opinionated
- modus-vivendi-theme-diffs 'desaturated
- modus-vivendi-theme-mode-line nil)))
-
(defun jao-themes-setup ()
- (cond ((not jao-colors-theme)
- (let ((light jao-colors-use-light-scheme))
- (load-theme (if light 'jao-light 'jao-greenish) t)))
- ((eq jao-colors-theme 'modus)
- (let ((light jao-colors-use-light-scheme))
- (load-theme (if light 'modus-operandi 'modus-vivendi) t)))
- ((eq jao-colors-theme 'doom)
- (load-theme jao-colors-doom-theme t)
- ;; (load-theme 'jao-doom t)
- )
- ((eq jao-colors-theme 'solarized-light)
- (load-theme 'solarized-light t))
- ((eq jao-colors-theme 'zenburn)
- (require 'jao-zenburn-theme)
- (load-theme 'zenburn t))))
+ (let ((light (and window-system (not (jao-colors-scheme-dark-p)))))
+ (setq jao-osd-cat-color-bg (if light "grey30" "white")
+ jao-osd-cat-color-fg (if light "white" "grey30"))
+ (load-theme (if light 'jao-light 'jao-greenish) t)))
(when (not (eq window-system 'pgtk)) (jao-themes-setup))
- #+END_SRC
+
+ (global-font-lock-mode 1)
+ #+end_src
* Help system
*** Echos and suggestions
#+begin_src emacs-lisp