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

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

[elpa] externals/org 31d4875 3/5: Merge branch 'maint'


From: ELPA Syncer
Subject: [elpa] externals/org 31d4875 3/5: Merge branch 'maint'
Date: Tue, 27 Apr 2021 03:57:12 -0400 (EDT)

branch: externals/org
commit 31d48755bf87d1fb61914774594dcad2ad316465
Merge: e6d9b64 13a1a4f
Author: Bastien Guerry <bzg@gnu.org>
Commit: Bastien Guerry <bzg@gnu.org>

    Merge branch 'maint'
---
 doc/org-manual.org       |  2 +-
 lisp/org-agenda.el       | 16 +++++-----------
 lisp/org.el              | 14 +++++---------
 testing/lisp/test-org.el |  9 +--------
 4 files changed, 12 insertions(+), 29 deletions(-)

diff --git a/doc/org-manual.org b/doc/org-manual.org
index 19a037f..2bac0b1 100644
--- a/doc/org-manual.org
+++ b/doc/org-manual.org
@@ -344,7 +344,7 @@ conventions:
 
 - =boss=, =ARCHIVE= ::
 
-  Tags are case-sensitive.  User-defined tags are written in
+  Tags are case-sensitive.  User-defined tags are usually written in
   lowercase; built-in tags with special meaning are written as they
   should appear in the document, usually with all capitals.
 
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index 2c4624d..bd9d466 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -3984,7 +3984,7 @@ agenda display, configure `org-agenda-finalize-hook'."
                  (put-text-property (point-at-bol) (point-at-eol)
                                     'tags
                                     (org-with-point-at mrk
-                                      (mapcar #'downcase (org-get-tags)))))))))
+                                      (org-get-tags))))))))
        (setq org-agenda-represented-tags nil
              org-agenda-represented-categories nil)
        (when org-agenda-top-headline-filter
@@ -6813,8 +6813,8 @@ Any match of REMOVE-RE will be removed from TXT."
        (remove-text-properties 0 (length rtn) '(line-prefix t wrap-prefix t) 
rtn)
        (org-add-props rtn nil
          'org-category category
-         'tags (mapcar #'org-downcase-keep-props tags)
-         'org-priority-highest org-priority-highest
+          'tags tags
+          'org-priority-highest org-priority-highest
          'org-priority-lowest org-priority-lowest
          'time-of-day time-of-day
          'duration duration
@@ -6858,12 +6858,6 @@ The modified list may contain inherited tags, and tags 
matched by
                          (if have-i "::" ":"))))))
   txt)
 
-(defun org-downcase-keep-props (s)
-  (let ((props (text-properties-at 0 s)))
-    (setq s (downcase s))
-    (add-text-properties 0 (length s) props s)
-    s))
-
 (defvar org-agenda-sorting-strategy) ;; because the def is in a let form
 
 (defun org-agenda-add-time-grid-maybe (list ndays todayp)
@@ -8161,7 +8155,7 @@ If the line does not have an effort defined, return nil."
 When NO-OPERATOR is non-nil, do not add the + operator to
 returned tags."
   (if org-group-tags
-      (let ((case-fold-search t) rtn)
+      (let (case-fold-search rtn)
        (mapc
         (lambda (f)
           (let (f0 dir)
@@ -8169,7 +8163,7 @@ returned tags."
                 (setq dir (match-string 1 f) f0 (match-string 2 f))
               (setq dir (if no-operator "" "+") f0 f))
             (setq rtn (append (mapcar (lambda(f1) (concat dir f1))
-                                      (org-tags-expand f0 t t))
+                                      (org-tags-expand f0 t))
                               rtn))))
         filter)
        (reverse rtn))
diff --git a/lisp/org.el b/lisp/org.el
index 0dc5023..2e21ea8 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -11792,22 +11792,18 @@ When the optional argument SINGLE-AS-LIST is non-nil, 
MATCH is
 assumed to be a single group tag, and the function will return
 the list of tags in this group.
 
-When DOWNCASED is non-nil, expand downcased TAGS."
+The DOWNCASED argument is obsolete and has no effect."
   (unless (org-string-nw-p match) (error "Invalid match tag: %S" match))
   (let ((tag-groups
-        (let ((g (or org-tag-groups-alist-for-agenda org-tag-groups-alist)))
-          (if (not downcased) g
-            (mapcar (lambda (s) (mapcar #'downcase s)) g)))))
+         (or org-tag-groups-alist-for-agenda org-tag-groups-alist)))
     (cond
-     (single-as-list (org--tags-expand-group
-                     (list (if downcased (downcase match) match))
-                     tag-groups nil))
+     (single-as-list (org--tags-expand-group (list match) tag-groups nil))
      (org-group-tags
       (let* ((case-fold-search t)
             (tag-syntax org-mode-syntax-table)
             (group-keys (mapcar #'car tag-groups))
             (key-regexp (concat "\\([+-]?\\)" (regexp-opt group-keys 'words)))
-            (return-match (if downcased (downcase match) match)))
+            (return-match match))
        ;; Mark regexp-expressions in the match-expression so that we
        ;; do not replace them later on.
        (let ((s 0))
@@ -11827,7 +11823,7 @@ When DOWNCASED is non-nil, expand downcased TAGS."
                 m                      ;regexp tag: ignore
               (let* ((operator (match-string 1 m))
                      (tag-token (let ((tag (match-string 2 m)))
-                                  (list (if downcased (downcase tag) tag))))
+                                  (list tag)))
                      regexp-tags regular-tags)
                 ;; Partition tags between regexp and regular tags.
                 ;; Remove curly bracket syntax from regexp tags.
diff --git a/testing/lisp/test-org.el b/testing/lisp/test-org.el
index f6fb4b3..a6408b7 100644
--- a/testing/lisp/test-org.el
+++ b/testing/lisp/test-org.el
@@ -7196,14 +7196,7 @@ Paragraph<point>"
    (equal "{A+}"
          (org-test-with-temp-text "#+TAGS: [ A : B C ]"
            (org-mode-restart)
-           (let ((org-tag-alist-for-agenda nil)) (org-tags-expand "{A+}")))))
-  ;; Uppercase MATCH works with a non-nil DOWNCASED and SINGLE-AS-LIST.
-  (should
-   (equal (list "a" "b" "c")
-         (org-test-with-temp-text "#+TAGS: [ A : B C ]"
-           (org-mode-restart)
-           (let ((org-tag-alist-for-agenda nil))
-             (sort (org-tags-expand "A" t t) #'string-lessp))))))
+           (let ((org-tag-alist-for-agenda nil)) (org-tags-expand "{A+}"))))))
 
 
 ;;; TODO keywords



reply via email to

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