[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/org-superstar f14dd4dc8b 151/162: Fixed logic errors I int
From: |
Stefan Kangas |
Subject: |
[nongnu] elpa/org-superstar f14dd4dc8b 151/162: Fixed logic errors I introduced with last merge. |
Date: |
Fri, 31 Dec 2021 19:35:39 -0500 (EST) |
branch: elpa/org-superstar
commit f14dd4dc8bd20b368a2663b5a69b2944e4124c81
Author: D. Williams <d.williams@posteo.net>
Commit: D. Williams <d.williams@posteo.net>
Fixed logic errors I introduced with last merge.
---
org-superstar.el | 22 ++++++++++++++--------
tests/sample.org | 2 ++
2 files changed, 16 insertions(+), 8 deletions(-)
diff --git a/org-superstar.el b/org-superstar.el
index 60fdf5ee47..e52dd33e0e 100644
--- a/org-superstar.el
+++ b/org-superstar.el
@@ -517,20 +517,26 @@ symbol ‘default’, return it instead. Otherwise, return
nil."
(defun org-superstar--todo-bullet ()
"Return the desired TODO item bullet, if defined.
+
If no entry can be found in ‘org-superstar-todo-bullet-alist’ for
-the current keyword, return nil."
- (when-let* ((todo-kw
- (org-superstar--get-todo (match-beginning 0)))
- (todo-bullet
- (cdr (org-superstar--todo-assoc todo-kw))))
+the current keyword, return nil.
+
+If ‘org-superstar-special-todo-items’ is set to the symbol
+‘hide’, return that instead."
+ (let* ((todo-kw
+ (org-superstar--get-todo (match-beginning 0)))
+ (todo-bullet
+ (cdr (org-superstar--todo-assoc todo-kw))))
(cond
- ((and todo-kw (eq org-superstar-special-todo-items 'hide))
+ ((not todo-kw)
+ nil)
+ ((eq org-superstar-special-todo-items 'hide)
'hide)
((characterp todo-bullet)
todo-bullet)
((listp todo-bullet)
- (let ((todo-fallback (cadr todo-bullet))
- (todo-bullet (car todo-bullet)))
+ (when-let ((todo-fallback (cadr todo-bullet))
+ (todo-bullet (car todo-bullet)))
(if (org-superstar-graphic-p)
todo-bullet
todo-fallback))))))
diff --git a/tests/sample.org b/tests/sample.org
index becca23866..7824d8c050 100644
--- a/tests/sample.org
+++ b/tests/sample.org
@@ -1,5 +1,6 @@
#+TITLE:Sample File
#+STARTUP: showeverything
+#+TODO: TODO IN-PROGRESS | DONE
* Lorem ipsum dolor sit amet
** Consectetur adipiscing elit
*** Eiusmod tempor incididunt
@@ -24,6 +25,7 @@
***** TODO A
***** DONE B
+***** IN-PROGRESS C
*************** Inline task?
**************** second
- [nongnu] elpa/org-superstar e225b78a5c 113/162: Updating README to reflect version change., (continued)
- [nongnu] elpa/org-superstar e225b78a5c 113/162: Updating README to reflect version change., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar abb8e863a1 109/162: Fix: Make org-superstar-headline-p non-interactive, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 2eed7bd4fe 098/162: Removed redundant sentence., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 09ddc28383 108/162: Fixed an unescaped paren in docstring., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 9ee98125bf 121/162: Working around GitHub README strangeness, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 9c85b9eace 117/162: Create issue template: bug report, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 61896d5bcd 125/162: Updating README on volatile., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar c3955469d5 134/162: Updating feature list., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 8bfe6354d9 138/162: Updated documentation to address Issue #21., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar d0cb2f4b9f 150/162: Merge branch 'hide-all-todo-keywords' of andersjohansson, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar f14dd4dc8b 151/162: Fixed logic errors I introduced with last merge.,
Stefan Kangas <=
- [nongnu] elpa/org-superstar 03be6c0a30 162/162: Remove now redundant call to org-element-lineage, version bump., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 4a4ae121c1 061/162: Add further documentation regarding org-indent-mode., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 457b6cdb49 019/162: Updating README to include new features., Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar fe061dce0c 043/162: added simple batch mode based unit tests for font lock, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar c70360d76b 028/162: Adding "test image" face-test.el, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 5614c01993 081/162: fixed typo in README, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar d4948eb213 032/162: Updated README, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 45719ffd10 022/162: added a marker for melpa review, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar b196dc10af 025/162: adding first draft of public testing facilities, Stefan Kangas, 2021/12/31
- [nongnu] elpa/org-superstar 086ab28506 075/162: Updating Roadmap, Stefan Kangas, 2021/12/31