Compare commits

..

No commits in common. "a8d76c2bebd7b7a542cd62e6e6ce843623f20aab" and "0907961986a582ded514d54a8bfdf691f7bfaf86" have entirely different histories.

5 changed files with 38 additions and 90 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 9.5 KiB

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 66 KiB

View File

@ -1,61 +1,44 @@
# <img src=".repo-assets/icon.png" width=50> adwaita-dark-theme
A dark color scheme that aims to replicate the appearance and colors of GTK4 "libadwaita" applications.
# adwaita-dark-theme
[![MELPA](https://melpa.org/packages/adwaita-dark-theme-badge.svg)](https://melpa.org/#/adwaita-dark-theme)
[![MELPA Stable](https://stable.melpa.org/packages/adwaita-dark-theme-badge.svg)](https://stable.melpa.org/#/adwaita-dark-theme)
## About
`adwaita-dark-theme` is a dark color scheme that aims to replicate the appearance and colors of GTK4 "libadwaita" applications.
## Features
* Beautiful dark color scheme inspired by Adwaita
* Automatic 256-color mode support
* Configurable theme features
* Custom fringe bitmaps for diff-hl, flycheck, and flymake
* Custom configurations for
[neotree](https://github.com/jaypei/emacs-neotree)
and [eldoc-frame](https://git.tty.dog/jessieh/eldoc-frame)
* Custom fringe bitmaps for
[diff-hl](https://github.com/dgutov/diff-hl),
[flycheck](https://www.flycheck.org),
and [flymake](https://www.emacswiki.org/emacs/FlyMake)
* Lightweight, no dependencies
* Lightweight with no dependencies
## Preview
![Preview Image](.repo-assets/preview.webp "Preview Image")
![Preview Image](https://gitlab.com/jessieh/adwaita-dark-theme/raw/assets/preview.png "Preview Image")
## Configuration
To see all of the theme features that can be configured:
`M-x customize-group adwaita-dark-theme`
### Neotree Configuration
### Custom Neotree Configuration
`(eval-after-load 'neotree #'adwaita-dark-theme-neotree-configuration-enable)`
### eldoc-frame Configuration
`(eval-after-load 'eldoc-frame #'adwaita-dark-theme-eldoc-frame-configuration-enable)`
### Fringe Bitmaps
### Custom Fringe Bitmaps
To replace default line continuation/line wrap fringe bitmaps:\
`(adwaita-dark-theme-arrow-fringe-bmp-enable)`
For specific packages:
* diff-hl:\
To enable custom fringe bitmaps for [diff-hl](https://github.com/dgutov/diff-hl):\
`(eval-after-load 'diff-hl #'adwaita-dark-theme-diff-hl-fringe-bmp-enable)`
* flycheck:\
To enable custom fringe bitmaps for [flycheck](https://www.flycheck.org/en/latest/):\
`(eval-after-load 'flycheck #'adwaita-dark-theme-flycheck-fringe-bmp-enable)`
* flymake:\
To enable custom fringe bitmaps for [flymake](https://www.emacswiki.org/emacs/FlyMake):\
`(eval-after-load 'flymake #'adwaita-dark-theme-flymake-fringe-bmp-enable)`
## Feedback

View File

@ -3,7 +3,7 @@
;; Author: Jessie Hildebrandt <jessieh.net>
;; Homepage: https://gitlab.com/jessieh/adwaita-dark-theme
;; Keywords: mode-line faces
;; Version: 1.3.0
;; Version: 1.2.0
;; Package-Requires: ((emacs "27.1"))
;;
;; This file is not part of GNU Emacs.
@ -16,8 +16,8 @@
;; Features offered:
;; * Beautiful dark color scheme inspired by Adwaita
;; * Automatic 256-color mode support
;; * Custom configurations for neotree and eldoc-frame
;; * Custom fringe bitmaps for line continuations, visual-line-mode, diff-hl, flycheck, and flymake
;; * Custom configuration for neotree
;; * Lightweight with no dependencies
;;
;; To replace default line continuation/line wrap fringe bitmaps:
@ -26,9 +26,6 @@
;; To enable custom configuration for `neotree':
;; (eval-after-load 'neotree #'adwaita-dark-theme-neotree-configuration-enable)
;;
;; To enable custom configuration for `eldoc-frame':
;; (eval-after-load 'eldoc-frame #'adwaita-dark-theme-eldoc-frame-configuration-enable)
;;
;; To enable custom fringe bitmaps for `diff-hl':
;; (eval-after-load 'diff-hl #'adwaita-dark-theme-diff-hl-fringe-bmp-enable)
;;
@ -67,33 +64,33 @@
;; External variable defs
;; ---------------------------------- ;;
(eval-when-compile
(defvar diff-hl-fringe-bmp-function)
(defvar eldoc-frame-parameters)
(defvar flymake-error-bitmap)
(defvar flymake-warning-bitmap)
(defvar flymake-note-bitmap)
(defvar neo-global--window))
(defvar diff-hl-fringe-bmp-function)
(defvar flymake-error-bitmap)
(defvar flymake-warning-bitmap)
(defvar flymake-note-bitmap)
(defvar neo-global--window)
;; ---------------------------------- ;;
;; External function decls
;; ---------------------------------- ;;
(eval-when-compile
(declare-function flycheck-redefine-standard-error-levels "flycheck" (&optional margin-str fringe-bitmap))
(declare-function neo-open-dir "neotree" (full-path &optional arg))
(declare-function neo-open-file "neotree" (full-path &optional arg))
(declare-function neo-filepath-hidden-p "neotree" (node))
(declare-function neo-path--file-short-name "neotree" (file))
(declare-function neo-global--create-window "neotree" ())
(declare-function neo-buffer--newline-and-begin "neotree" ())
(declare-function neo-buffer--node-list-set "neotree" (line-num path))
(declare-function neo-buffer--insert-root-entry "neotree" (node))
(declare-function neo-buffer--insert-dir-entry "neotree" (node depth expanded))
(declare-function neo-buffer--insert-file-entry "neotree" (node depth))
(declare-function neotree-hidden-file-toggle "neotree" ())
(declare-function neotree-select-up-node "neotree" ())
(declare-function neotree-change-root "neotree" ()))
(declare-function flycheck-redefine-standard-error-levels "flycheck" (&optional margin-str fringe-bitmap))
(declare-function neo-open-dir "neotree" (full-path &optional arg))
(declare-function neo-open-file "neotree" (full-path &optional arg))
(declare-function neo-filepath-hidden-p "neotree" (node))
(declare-function neo-path--file-short-name "neotree" (file))
(declare-function neo-global--create-window "neotree" ())
(declare-function neo-buffer--newline-and-begin "neotree" ())
(declare-function neo-buffer--node-list-set "neotree" (line-num path))
(declare-function neo-buffer--insert-root-entry "neotree" (node))
(declare-function neo-buffer--insert-dir-entry "neotree" (node depth expanded))
(declare-function neo-buffer--insert-file-entry "neotree" (node depth))
(declare-function neotree-hidden-file-toggle "neotree" ())
(declare-function neotree-select-up-node "neotree" ())
(declare-function neotree-change-root "neotree" ())
;; -------------------------------------------------------------------------- ;;
;;
@ -176,7 +173,7 @@
;; [True color | 256-compatible]
(bg (if true-color-available-p "#1c1c1c" "gray11")) ; #1c1c1c
(bg-alt (if true-color-available-p "#242424" "gray14")) ; #242424
(bg-osd (if true-color-available-p "#060606" "gray3")) ; #080808
(bg-osd (if true-color-available-p "#101010" "gray6")) ; #0f0f0f
(base-0 (if true-color-available-p "#202020" "gray13")) ; #212121
(base-1 (if true-color-available-p "#262626" "gray15")) ; #262626
(base-2 (if true-color-available-p "#292929" "gray16")) ; #292929
@ -247,7 +244,6 @@
`(font-lock-doc-face ((,class (:foreground ,base-6))))
`(font-lock-comment-face ((,class (:foreground ,base-5))))
`(font-lock-comment-delimiter-face ((,class (:inherit font-lock-comment-face))))
`(font-lock-delimiter-face ((,class (:foreground ,base-7))))
`(font-lock-constant-face ((,class (:foreground ,violet))))
`(font-lock-variable-name-face ((,class ())))
`(font-lock-function-name-face ((,class ())))
@ -590,10 +586,6 @@
`(eldoc-box-body ((,class (:inherit (tooltip variable-pitch-text)))))
`(eldoc-box-border ((,class (:background ,base-3))))
;; eldoc-frame
`(eldoc-frame-default ((,class (:inherit (tooltip variable-pitch-text)))))
`(eldoc-frame-border ((,class (:background ,base-3))))
;; fic-mode
`(fic-face ((,class (:foreground ,yellow :weight bold))))
@ -1034,33 +1026,6 @@
(advice-add #'neo-buffer--insert-dir-entry :override #'adwaita-dark-theme--neotree-insert-dir)
(advice-add #'neo-buffer--insert-file-entry :override #'adwaita-dark-theme--neotree-insert-file))
;; -------------------------------------------------------------------------- ;;
;;
;; eldoc-frame configuration
;;
;; -------------------------------------------------------------------------- ;;
;; ---------------------------------- ;;
;; Setup function
;; ---------------------------------- ;;
;;;###autoload
(defun adwaita-dark-theme-eldoc-frame-configuration-enable ()
"Enable custom adwaita-dark configuration for use with eldoc-frame."
(set-face-background 'eldoc-frame-default "#000000")
(dolist (parameter '((left-fringe . 12)
(right-fringe . 12)
(alpha-background . 80)))
(add-to-list 'eldoc-frame-parameters parameter))
(add-hook 'eldoc-frame-buffer-hook
(lambda ()
(setq-local line-spacing 0.25)
(goto-char (point-min))
(insert (propertize "\s\n" 'face '(:height 0.2)))
(goto-char (point-max))
(insert (propertize "\s\n" 'face '(:height 0.2))))
100))
;; -------------------------------------------------------------------------- ;;
;;
;; Arrow fringe bitmaps configuration