فهرست منبع

Ignore TODO keywords and Priorities when sorting headlines.

This applies to numeric and alphanumeric sorting.
Carsten Dominik 17 سال پیش
والد
کامیت
22a6e1718c
3فایلهای تغییر یافته به همراه28 افزوده شده و 15 حذف شده
  1. 15 10
      ORGWEBPAGE/Changes.org
  2. 8 0
      lisp/ChangeLog
  3. 5 5
      lisp/org.el

+ 15 - 10
ORGWEBPAGE/Changes.org

@@ -15,18 +15,19 @@
 :VISIBILITY: content
 :END:
 
-* Incompatible changes
-*** Prefix interpretation when storing remember notes
-    The prefix argument to the `C-c C-c' command that finishes a
-    remember process is not interpetred differently:
+** Incompatible changes
 
-    :C-c C-c       Store the note to predefined file and headline
-    :C-1 C-c C-c   Select the storage location interactively
-    :C-0 C-c C-c   Re-use the last used location
-    :C-u C-c C-c   Like C-c C-c, but immediately visit the note
-    :              in its new location.
+**** Prefix interpretation when storing remember notes
+     The prefix argument to the `C-c C-c' command that finishes a
+     remember process is not interpetred differently:
 
-    This was requested by John Wiegley.
+     :C-c C-c       Store the note to predefined file and headline
+     :C-1 C-c C-c   Select the storage location interactively
+     :C-0 C-c C-c   Re-use the last used location
+     :C-u C-c C-c   Like C-c C-c, but immediately visit the note
+     :              in its new location.
+
+     This was requested by John Wiegley.
 
 
 ** Details
@@ -43,6 +44,10 @@
 
     This was requested by John Wiegley.
 
+*** Sorting entries now ignores the TODO keyword and the priority
+    Numerical and alphanumerical sorting now skips any TODO
+    keyword or priority cookie when constructing the comparison
+    string.  This was a request by Wanrong Lin.
 
 *** New face =org-scheduled= for entries that at some time in the future.
     This was a request by Richard G Rigley.

+ 8 - 0
lisp/ChangeLog

@@ -1,3 +1,11 @@
+2008-09-04  Carsten Dominik  <dominik@science.uva.nl>
+
+	* org.el (org-sort-entries-or-items): Make numeric and alpha
+	comparisons ignore any TODO keyword and priority cookie.
+
+	* org-remember.el (org-remember-handler): Reinterpretation of the
+	prefix argument.
+
 2008-09-03  Carsten Dominik  <dominik@science.uva.nl>
 
 	* org-agenda.el (org-agenda-get-scheduled): Use new

+ 5 - 5
lisp/org.el

@@ -5300,13 +5300,13 @@ WITH-CASE, the sorting considers case as well."
 	   (lambda nil
 	     (cond
 	      ((= dcst ?n)
-	       (if (looking-at outline-regexp)
-		   (string-to-number (buffer-substring (match-end 0)
-						       (point-at-eol)))
+	       (if (looking-at org-complex-heading-regexp)
+		   (string-to-number (match-string 4))
 		 nil))
 	      ((= dcst ?a)
-	       (funcall case-func (buffer-substring (point-at-bol)
-						    (point-at-eol))))
+	       (if (looking-at org-complex-heading-regexp)
+		   (funcall case-func (match-string 4))
+		 nil))
 	      ((= dcst ?t)
 	       (if (re-search-forward org-ts-regexp
 				      (save-excursion