branch: elpa/why-this commit b69263c66b63680e1db81f6da98de00c230c7384 Author: Akib Azmain Turja <a...@disroot.org> Commit: Akib Azmain Turja <a...@disroot.org>
Fix "Invalid face attribute :background nil" --- README.org | 4 ++++ why-this.el | 29 +++++++++++++++-------------- 2 files changed, 19 insertions(+), 14 deletions(-) diff --git a/README.org b/README.org index cacff98f5c..24b2b939bc 100644 --- a/README.org +++ b/README.org @@ -16,6 +16,10 @@ Editing history with heat map. * Install +** MELPA + +=M-x package-refresh-contents= and =M-x package-install RET why-this=. + ** straight.el #+begin_src emacs-lisp diff --git a/why-this.el b/why-this.el index f2cbfbec1e..b2cdb74789 100644 --- a/why-this.el +++ b/why-this.el @@ -364,21 +364,22 @@ TIME-FORMAT is used to format data." (if (not why-this-calculate-background) 'why-this-face `(:background - ,(face-background - (pcase type - ('region - (if (bound-and-true-p solaire-mode) - 'solaire-region-face - 'region)) - ('line - (if (bound-and-true-p hl-line-mode) + ,(or (face-background + (pcase type + ('region (if (bound-and-true-p solaire-mode) - 'solaire-hl-line-face - 'hl-line) - 'why-this-face)) - (_ - 'why-this-face)) - nil t) + 'solaire-region-face + 'region)) + ('line + (if (bound-and-true-p hl-line-mode) + (if (bound-and-true-p solaire-mode) + 'solaire-hl-line-face + 'hl-line) + 'why-this-face)) + (_ + 'why-this-face)) + nil t) + 'unspecified) :inherit why-this-face))) (defvar why-this-mode)