[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/auto-dim-other-buffers 890051374f 01/82: first
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/auto-dim-other-buffers 890051374f 01/82: first |
Date: |
Mon, 12 Dec 2022 20:58:36 -0500 (EST) |
branch: elpa/auto-dim-other-buffers
commit 890051374f13e42a8d00c2614c0c0ac3c53b5e25
Author: Steven Degutis <sbdegutis@gmail.com>
Commit: Steven Degutis <sbdegutis@gmail.com>
first
---
README.md | 16 ++++++++++++++++
auto-dim-other-buffers.el | 35 +++++++++++++++++++++++++++++++++++
2 files changed, 51 insertions(+)
diff --git a/README.md b/README.md
new file mode 100644
index 0000000000..66a62d0bc6
--- /dev/null
+++ b/README.md
@@ -0,0 +1,16 @@
+# auto-dim-other-buffers.el
+
+Visually makes non-current buffers less prominent.
+
+## Installation
+
+Use [MELPA](http://melpa.milkbox.net/): `M-x package-install RET
auto-dim-other-buffers RET`
+
+## Usage
+
+* `turn-on-auto-dim-other-buffers`
+* `turn-off-auto-dim-other-buffers`
+
+## TODO:
+
+* Make the face more easily customizable
diff --git a/auto-dim-other-buffers.el b/auto-dim-other-buffers.el
new file mode 100644
index 0000000000..837a605185
--- /dev/null
+++ b/auto-dim-other-buffers.el
@@ -0,0 +1,35 @@
+;;; auto-dim-other-buffers.el --- Visually makes non-current buffers less
prominent
+
+;; Author: Steven Degutis
+;; URL: https://github.com/sdegutis/auto-dim-other-buffers.el
+;; Version: 1.0
+
+(make-face 'sd/dimmed-font)
+(set-face-attribute 'sd/dimmed-font nil :background "black")
+
+(defun turn-off-auto-dim-other-buffers ()
+ (interactive)
+ (remove-hook 'post-command-hook 'sd/auto-dim-other-buffers)
+ (let ((original (current-buffer)))
+ (dolist (buffer (buffer-list))
+ (set-buffer buffer)
+ (buffer-face-set nil))
+ (set-buffer original)
+ (buffer-face-set nil)))
+
+(defun turn-on-auto-dim-other-buffers ()
+ (interactive)
+ (add-hook 'post-command-hook 'sd/auto-dim-other-buffers))
+
+(defun sd/auto-dim-other-buffers ()
+ (let ((original (current-buffer)))
+ (dolist (buffer (buffer-list))
+ (unless (minibufferp buffer)
+ (set-buffer buffer)
+ (buffer-face-set 'sd/dimmed-font)))
+ (set-buffer original)
+ (buffer-face-set nil)))
+
+(provide 'auto-dim-other-buffers)
+
+;;; auto-dim-other-buffers.el ends here
- [nongnu] branch elpa/auto-dim-other-buffers created (now 33b5f88b79), ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers 890051374f 01/82: first,
ELPA Syncer <=
- [nongnu] elpa/auto-dim-other-buffers 16db9f4942 06/82: MUCH more efficient: only changes faces for 2 buffers max, and only when necessary, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers e7fcc5336c 13/82: less ceremonial readme?, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers 6804fde17b 11/82: screenshot, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers fb7ea24922 26/82: dimming/undimming when gaining/losing app focus, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers e64bdbdb0a 34/82: Use `face-remap-add-relative' to not interfere with `buffer-face-mode', ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers 6ebff3681f 46/82: Don’t dim already dimmed buffer, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers e85510688d 19/82: duh, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers c80b367dd0 22/82: Leave echo area alone, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers bea02696f0 21/82: Use save-current-buffer and with-current-buffer, ELPA Syncer, 2022/12/12
- [nongnu] elpa/auto-dim-other-buffers a969ff4e0e 16/82: minor mode, ELPA Syncer, 2022/12/12