From 745e868b075655b8438b4a2805ba30e33cd710b0 Mon Sep 17 00:00:00 2001 From: bmag Date: Fri, 9 Nov 2018 20:11:47 +0200 Subject: [PATCH] update spacemacs theme Update spacemacs theme to commit c162ad13 upstream. https://github.com/nashamri/spacemacs-theme/commit/c162ad13e4ae1965619012332d3b5f57c9172e98 --- core/libs/spacemacs-theme/README.md | 58 ++++++++++++++++++- core/libs/spacemacs-theme/spacemacs-common.el | 46 +++++++++++---- 2 files changed, 91 insertions(+), 13 deletions(-) diff --git a/core/libs/spacemacs-theme/README.md b/core/libs/spacemacs-theme/README.md index 623686778..4d76e7674 100644 --- a/core/libs/spacemacs-theme/README.md +++ b/core/libs/spacemacs-theme/README.md @@ -67,6 +67,10 @@ This toggles italics for keywords. This toggles the use of varying org agenda heights. +* `spacemacs-theme-org-bold`: + +This toggles bold text for org headings. + * `spacemacs-theme-org-height`: This toggles the use of varying org headings heights. @@ -75,6 +79,10 @@ This toggles the use of varying org headings heights. This toggles highlighting of org headings. +* `spacemacs-theme-org-priority-bold`: + +This toggles bold text for priority items in agenda view. + * `spacemacs-theme-custom-colors`: This allows for specifying a list of custom colors to override spacemacs theme colors. More details in the next section. @@ -165,7 +173,7 @@ Here are some screenshots of the various variables: If you are using [spacemacs](https://github.com/syl20bnr/spacemacs), you can put this snippet in your `dotspacemacs/user-init` to override these colors: -``` +```elisp (custom-set-variables '(spacemacs-theme-custom-colors '((act1 . "#ff0000") (act2 . "#0000ff") @@ -174,6 +182,52 @@ If you are using [spacemacs](https://github.com/syl20bnr/spacemacs), you can put This will override `act1`, `act1` and `base` to use the specified colors. -# Like the theme and want to use it in other places? +### Use a custom flycheck fringe bitmap + +If you don't use spacemacs and want to get the same look of flycheck fringe bitmap, you can put the following snippet into your `init.el` (this assumes you are using `use-package`): + +```elisp +(use-package flycheck + :init + (progn + (define-fringe-bitmap 'my-flycheck-fringe-indicator + (vector #b00000000 + #b00000000 + #b00000000 + #b00000000 + #b00000000 + #b00000000 + #b00000000 + #b00011100 + #b00111110 + #b00111110 + #b00111110 + #b00011100 + #b00000000 + #b00000000 + #b00000000 + #b00000000 + #b00000000)) + + (flycheck-define-error-level 'error + :severity 2 + :overlay-category 'flycheck-error-overlay + :fringe-bitmap 'my-flycheck-fringe-indicator + :fringe-face 'flycheck-fringe-error) + + (flycheck-define-error-level 'warning + :severity 1 + :overlay-category 'flycheck-warning-overlay + :fringe-bitmap 'my-flycheck-fringe-indicator + :fringe-face 'flycheck-fringe-warning) + + (flycheck-define-error-level 'info + :severity 0 + :overlay-category 'flycheck-info-overlay + :fringe-bitmap 'my-flycheck-fringe-indicator + :fringe-face 'flycheck-fringe-info))) +``` + +## Like the theme and want to use it in other places? Then check out this project [base16-builder](https://github.com/auduchinok/base16-builder). diff --git a/core/libs/spacemacs-theme/spacemacs-common.el b/core/libs/spacemacs-theme/spacemacs-common.el index 6b167c3bb..8bea942cc 100644 --- a/core/libs/spacemacs-theme/spacemacs-common.el +++ b/core/libs/spacemacs-theme/spacemacs-common.el @@ -70,6 +70,16 @@ to 'auto, tags may not be properly aligned. " :type 'boolean :group 'spacemacs-theme) +(defcustom spacemacs-theme-org-bold t + "Inherit text bold for org headings" + :type 'boolean + :group 'spacemacs-theme) + +(defcustom spacemacs-theme-org-priority-bold t + "Inherit text bold for priority items in agenda view" + :type 'boolean + :group 'spacemacs-theme) + (defcustom spacemacs-theme-org-highlight nil "Highlight org headings." :type 'boolean @@ -284,9 +294,9 @@ to 'auto, tags may not be properly aligned. " `(diff-removed ((,class :background nil :foreground ,red))) ;;;;; diff-hl - `(diff-hl-change ((,class :background ,blue-bg :foreground ,blue))) - `(diff-hl-delete ((,class :background ,red-bg :foreground ,red))) - `(diff-hl-insert ((,class :background ,green-bg :foreground ,green))) + `(diff-hl-change ((,class :background ,blue-bg-s :foreground ,blue))) + `(diff-hl-delete ((,class :background ,red-bg-s :foreground ,red))) + `(diff-hl-insert ((,class :background ,green-bg-s :foreground ,green))) ;;;;; dired `(dired-directory ((,class (:foreground ,keyword :background ,bg1 :inherit bold)))) @@ -372,6 +382,8 @@ to 'auto, tags may not be properly aligned. " `(ess-numbers-face ((,class (:inherit font-lock-constant-face)))) `(ess-operator-face ((,class (:foreground ,var)))) `(ess-paren-face ((,class (:foreground ,blue)))) + `(ess-r-control-flow-keyword-face ((,class (:foreground ,keyword)))) + `(ess-r-signal-keyword-face ((,class (:foreground ,war)))) ;;;;; evil `(evil-ex-substitute-matches ((,class (:background ,red-bg :foreground ,red)))) @@ -581,10 +593,9 @@ to 'auto, tags may not be properly aligned. " ;;;;; linum-mode `(linum ((,class (:foreground ,lnum :background ,bg2 :inherit default)))) -;;;;; display-line-numbers-mode (Emacs 26+) - (when (>= emacs-major-version 26) - `(line-number ((,class (:foreground ,lnum :background ,bg2)))) - `(line-number-current-line ((,class (:foreground ,base :background ,bg2))))) +;;;;; line-numbers + `(line-number ((,class (:foreground ,lnum :background ,bg2 :inherit default)))) + `(line-number-current-line ((,class (:foreground ,base :background ,bg2 :inherit line-number)))) ;;;;; linum-relative `(linum-relative-current-face ((,class (:foreground ,comp)))) @@ -717,8 +728,8 @@ to 'auto, tags may not be properly aligned. " `(org-footnote ((,class (:underline t :foreground ,base)))) `(org-hide ((,class (:foreground ,base)))) `(org-kbd ((,class (:inherit region :foreground ,base :box (:line-width 1 :style released-button))))) - `(org-level-1 ((,class (:inherit bold :foreground ,head1 :height ,(if spacemacs-theme-org-height 1.3 1.0) :background ,(when spacemacs-theme-org-highlight head1-bg))))) - `(org-level-2 ((,class (:inherit bold :foreground ,head2 :height ,(if spacemacs-theme-org-height 1.2 1.0) :background ,(when spacemacs-theme-org-highlight head2-bg))))) + `(org-level-1 ((,class (:inherit bold :bold ,(if spacemacs-theme-org-bold 'unspecified nil) :foreground ,head1 :height ,(if spacemacs-theme-org-height 1.3 1.0) :background ,(when spacemacs-theme-org-highlight head1-bg))))) + `(org-level-2 ((,class (:inherit bold :bold ,(if spacemacs-theme-org-bold 'unspecified nil) :foreground ,head2 :height ,(if spacemacs-theme-org-height 1.2 1.0) :background ,(when spacemacs-theme-org-highlight head2-bg))))) `(org-level-3 ((,class (:bold nil :foreground ,head3 :height ,(if spacemacs-theme-org-height 1.1 1.0) :background ,(when spacemacs-theme-org-highlight head3-bg))))) `(org-level-4 ((,class (:bold nil :foreground ,head4 :background ,(when spacemacs-theme-org-highlight head4-bg))))) `(org-level-5 ((,class (:bold nil :foreground ,head1)))) @@ -728,7 +739,7 @@ to 'auto, tags may not be properly aligned. " `(org-link ((,class (:underline t :foreground ,comment)))) `(org-meta-line ((,class (:foreground ,meta)))) `(org-mode-line-clock-overrun ((,class (:foreground ,err)))) - `(org-priority ((,class (:foreground ,war :inherit bold)))) + `(org-priority ((,class (:foreground ,war :inherit bold :bold ,(if spacemacs-theme-org-priority-bold 'unspecified nil))))) `(org-quote ((,class (:inherit org-block :slant italic)))) `(org-scheduled ((,class (:foreground ,comp)))) `(org-scheduled-today ((,class (:foreground ,func :height ,(if spacemacs-theme-org-agenda-height 1.2 1.0))))) @@ -745,6 +756,16 @@ to 'auto, tags may not be properly aligned. " `(org-verse ((,class (:inherit org-block :slant italic)))) `(org-warning ((,class (:foreground ,err :inherit org-priority)))) +;;;;; outline + `(outline-1 ((,class (:inherit org-level-1)))) + `(outline-2 ((,class (:inherit org-level-2)))) + `(outline-3 ((,class (:inherit org-level-3)))) + `(outline-4 ((,class (:inherit org-level-4)))) + `(outline-5 ((,class (:inherit org-level-5)))) + `(outline-6 ((,class (:inherit org-level-6)))) + `(outline-7 ((,class (:inherit org-level-7)))) + `(outline-8 ((,class (:inherit org-level-8)))) + ;;;;; perspective `(persp-selected-face ((,class (:inherit bold :foreground ,func)))) @@ -856,6 +877,7 @@ to 'auto, tags may not be properly aligned. " `(web-mode-builtin-face ((,class (:inherit ,font-lock-builtin-face)))) `(web-mode-comment-face ((,class (:inherit ,font-lock-comment-face)))) `(web-mode-constant-face ((,class (:inherit ,font-lock-constant-face)))) + `(web-mode-current-element-highlight-face ((,class (:background ,bg3)))) `(web-mode-doctype-face ((,class (:inherit ,font-lock-comment-face)))) `(web-mode-function-name-face ((,class (:inherit ,font-lock-function-name-face)))) `(web-mode-html-attr-name-face ((,class (:foreground ,func)))) @@ -915,8 +937,10 @@ to 'auto, tags may not be properly aligned. " (custom-theme-set-variables theme-name - `(ansi-color-names-vector [,bg4 ,red ,green ,yellow ,blue ,magenta ,cyan ,base])) + `(ansi-color-names-vector [,bg4 ,red ,green ,yellow ,blue ,magenta ,cyan ,base]) +;;;;; pdf-tools + `(pdf-view-midnight-colors '(,base . ,bg1))) ))