emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/focus 246eaeb8d1 72/82: Define faces for the unfocused and


From: ELPA Syncer
Subject: [nongnu] elpa/focus 246eaeb8d1 72/82: Define faces for the unfocused and focused regions
Date: Tue, 6 Sep 2022 04:58:59 -0400 (EDT)

branch: elpa/focus
commit 246eaeb8d16a57ba6b6b524568ef0e1599650935
Author: Lars Tveito <larstvei@ifi.uio.no>
Commit: Lars Tveito <larstvei@ifi.uio.no>

    Define faces for the unfocused and focused regions
---
 focus.el | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/focus.el b/focus.el
index 76480aa93d..16690d1725 100644
--- a/focus.el
+++ b/focus.el
@@ -59,14 +59,13 @@ Things that are defined include `symbol', `list', `sexp',
   :type '(float)
   :group 'focus)
 
-(defcustom focus-unfocused-face 'font-lock-comment-face
+(defface focus-unfocused-face
+  '((t :inherit font-lock-comment-face))
   "The face that overlays the unfocused area."
-  :type '(face)
   :group 'focus)
 
-(defcustom focus-focused-face nil
+(defface focus-focused-face nil
   "The face that overlays the focused area."
-  :type '(face)
   :group 'focus)
 
 (defvar focus-cursor-type cursor-type
@@ -132,8 +131,8 @@ It sets the `focus-pre-overlay', `focus-min-overlay', and
           focus-mid-overlay  (make-overlay (point-min) (point-max))
           focus-post-overlay (make-overlay (point-max) (point-max))
           focus-buffer (current-buffer))
-    (overlay-put focus-mid-overlay 'face focus-focused-face)
-    (mapc (lambda (o) (overlay-put o 'face focus-unfocused-face))
+    (overlay-put focus-mid-overlay 'face 'focus-focused-face)
+    (mapc (lambda (o) (overlay-put o 'face 'focus-unfocused-face))
           (list focus-pre-overlay focus-post-overlay))
     (add-hook 'post-command-hook 'focus-move-focus nil t)
     (add-hook 'change-major-mode-hook 'focus-terminate nil t)))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]