Created
July 8, 2024 17:31
-
-
Save jamescherti/316e2f87b9e8f0af9a560ee594552083 to your computer and use it in GitHub Desktop.
Emacs: Set all attributes of the specified FACE to `unspecified'.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; Description: Set all attributes of the specified FACE to `unspecified'. | |
;; Gits URL: https://gist.github.com/jamescherti/316e2f87b9e8f0af9a560ee594552083 | |
;; License: MIT | |
;; Author: James Cherti | |
(defun my-reset-face-attributes (face) | |
"Set all attributes of the specified FACE to `unspecified'." | |
(when (facep face) | |
(let ((attributes (face-all-attributes face))) | |
(dolist (attr attributes) | |
(set-face-attribute face nil (car attr) 'unspecified))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment