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

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

[nongnu] elpa/pdf-tools c3c05e3bc5 1/2: pdf-annot: Fix: Render color onl


From: ELPA Syncer
Subject: [nongnu] elpa/pdf-tools c3c05e3bc5 1/2: pdf-annot: Fix: Render color only if it's defined.
Date: Fri, 2 Dec 2022 02:59:15 -0500 (EST)

branch: elpa/pdf-tools
commit c3c05e3bc564cd1a009d944e8002634ffcaf7376
Author: Vedang Manerikar <ved.manerikar@gmail.com>
Commit: Vedang Manerikar <ved.manerikar@gmail.com>

    pdf-annot: Fix: Render color only if it's defined.
    
    Free-text annotations do not have a color associated with them, which
    causes annotation listing to crash (since the default value of
    `pdf-annot-list-highlight-type` is now true). This bug was introduced
    in bb0b71f5bafd81d0b5647c4ec48fafa0bb6f6c21
---
 lisp/pdf-annot.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lisp/pdf-annot.el b/lisp/pdf-annot.el
index c82ed0cfb2..7140e9ae14 100644
--- a/lisp/pdf-annot.el
+++ b/lisp/pdf-annot.el
@@ -1652,7 +1652,7 @@ pretty-printed output."
         (type
          (let ((color (pdf-annot-get a 'color))
                (type (pdf-annot-print-property a 'type)))
-           (if pdf-annot-list-highlight-type
+           (if (and pdf-annot-list-highlight-type color)
                (propertize
                 type 'face
                 `(:background ,color



reply via email to

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