summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBastien Guerry <bzg@altern.org>2013-03-23 17:42:09 +0100
committerBastien Guerry <bzg@altern.org>2013-03-23 17:45:15 +0100
commitf373bca58b8fe665739815c2b7174dc91e2a9c0c (patch)
tree9164cfe13a5610d884e94238f0d7f39bb63a5060
parent869f9f2354bab39be8c7b2d461c6e6cbed1aa42d (diff)
downloadorg-mode-f373bca58b8fe665739815c2b7174dc91e2a9c0c.tar.gz
Rename some list variables
* org-element.el (org-element-paragraph-separate): Use new name `org-list-allow-alphabetical'. * org-list.el (org-list-allow-alphabetical): Rename from `org-alphabetical-lists'. (org-list-empty-line-terminates-plain-lists): Rename from `org-empty-line-terminates-plain-lists'. (org-checkbox-hierarchical-statistics): Rename from `org-hierarchical-checkbox-statistics'. * org.texi (Plain lists, Checkboxes): Use non-obsolete variable names.
-rw-r--r--doc/org.texi14
-rw-r--r--lisp/org-element.el2
-rw-r--r--lisp/org-list.el25
3 files changed, 21 insertions, 20 deletions
diff --git a/doc/org.texi b/doc/org.texi
index 2ebc408..794d90b 100644
--- a/doc/org.texi
+++ b/doc/org.texi
@@ -1642,12 +1642,12 @@ is supported, it may be better to not use it for plain list items.} as
bullets.
@item
@vindex org-plain-list-ordered-item-terminator
-@vindex org-alphabetical-lists
+@vindex org-list-allow-alphabetical
@emph{Ordered} list items start with a numeral followed by either a period or
a right parenthesis@footnote{You can filter out any of them by configuring
@code{org-plain-list-ordered-item-terminator}.}, such as @samp{1.} or
@samp{1)}@footnote{You can also get @samp{a.}, @samp{A.}, @samp{a)} and
-@samp{A)} by configuring @code{org-alphabetical-lists}. To minimize
+@samp{A)} by configuring @code{org-list-allow-alphabetical}. To minimize
confusion with normal text, those are limited to one character only. Beyond
that limit, bullets will automatically fallback to numbers.}. If you want a
list to start with a different value (e.g., 20), start the text of the item
@@ -1667,11 +1667,11 @@ line. In particular, if an ordered list reaches number @samp{10.}, then the
list. An item ends before the next line that is less or equally indented
than its bullet/number.
-@vindex org-empty-line-terminates-plain-lists
+@vindex org-list-empty-line-terminates-plain-lists
A list ends whenever every item has ended, which means before any line less
or equally indented than items at top level. It also ends before two blank
-lines@footnote{See also @code{org-empty-line-terminates-plain-lists}.}. In
-that case, all items are closed. Here is an example:
+lines@footnote{See also @code{org-list-empty-line-terminates-plain-lists}.}.
+In that case, all items are closed. Here is an example:
@example
@group
@@ -4593,7 +4593,7 @@ checked.
@cindex statistics, for checkboxes
@cindex checkbox statistics
@cindex property, COOKIE_DATA
-@vindex org-hierarchical-checkbox-statistics
+@vindex org-checkbox-hierarchical-statistics
The @samp{[2/4]} and @samp{[1/3]} in the first and second line are cookies
indicating how many checkboxes present in this entry have been checked off,
and the total number of checkboxes present. This can give you an idea on how
@@ -4601,7 +4601,7 @@ many checkboxes remain, even without opening a folded entry. The cookies can
be placed into a headline or into (the first line of) a plain list item.
Each cookie covers checkboxes of direct children structurally below the
headline/item on which the cookie appears@footnote{Set the variable
-@code{org-hierarchical-checkbox-statistics} if you want such cookies to
+@code{org-checkbox-hierarchical-statistics} if you want such cookies to
count all checkboxes below the cookie, not just those belonging to direct
children.}. You have to insert the cookie yourself by typing either
@samp{[/]} or @samp{[%]}. With @samp{[/]} you get an @samp{n out of m}
diff --git a/lisp/org-element.el b/lisp/org-element.el
index ba2461a..86180e9 100644
--- a/lisp/org-element.el
+++ b/lisp/org-element.el
@@ -160,7 +160,7 @@
;; Lists.
(let ((term (case org-plain-list-ordered-item-terminator
(?\) ")") (?. "\\.") (otherwise "[.)]")))
- (alpha (and org-alphabetical-lists "\\|[A-Za-z]")))
+ (alpha (and org-list-allow-alphabetical "\\|[A-Za-z]")))
(concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha "\\)" term "\\)"
"\\(?:[ \t]\\|$\\)"))
"\\)\\)")
diff --git a/lisp/org-list.el b/lisp/org-list.el
index ac94d15..5bc5a15 100644
--- a/lisp/org-list.el
+++ b/lisp/org-list.el
@@ -217,7 +217,8 @@ Valid values are ?. and ?\). To get both terminators, use t."
(const :tag "paren like in \"2)\"" ?\))
(const :tag "both" t)))
-(org-defvaralias 'org-alphabetical-lists 'org-list-allow-alphabetical) ;; Since 8.0
+(define-obsolete-variable-alias 'org-alphabetical-lists
+ 'org-list-allow-alphabetical "24.4") ; Since 8.0
(defcustom org-list-allow-alphabetical nil
"Non-nil means single character alphabetical bullets are allowed.
Both uppercase and lowercase are handled. Lists with more than
@@ -239,8 +240,8 @@ spaces instead of one after the bullet in each item of the list."
(const :tag "never" nil)
(regexp)))
-(org-defvaralias 'org-empty-line-terminates-plain-lists
- 'org-list-empty-line-terminates-plain-lists) ;; Since 8.0
+(define-obsolete-variable-alias 'org-empty-line-terminates-plain-lists
+ 'org-list-empty-line-terminates-plain-lists "24.4") ;; Since 8.0
(defcustom org-list-empty-line-terminates-plain-lists nil
"Non-nil means an empty line ends all plain list levels.
Otherwise, two of them will be necessary."
@@ -293,8 +294,8 @@ This hook runs even if checkbox rule in
implement alternative ways of collecting statistics
information.")
-(org-defvaralias 'org-hierarchical-checkbox-statistics
- 'org-checkbox-hierarchical-statistics) ;; Since 8.0
+(define-obsolete-variable-alias 'org-hierarchical-checkbox-statistics
+ 'org-checkbox-hierarchical-statistics "24.4") ;; Since 8.0
(defcustom org-checkbox-hierarchical-statistics t
"Non-nil means checkbox statistics counts only the state of direct children.
When nil, all boxes below the cookie are counted.
@@ -363,10 +364,10 @@ specifically, type `block' is determined by the variable
;;; Predicates and regexps
-(defconst org-list-end-re (if org-empty-line-terminates-plain-lists "^[ \t]*\n"
+(defconst org-list-end-re (if org-list-empty-line-terminates-plain-lists "^[ \t]*\n"
"^[ \t]*\n[ \t]*\n")
"Regex corresponding to the end of a list.
-It depends on `org-empty-line-terminates-plain-lists'.")
+It depends on `org-list-empty-line-terminates-plain-lists'.")
(defconst org-list-full-item-re
(concat "^[ \t]*\\(\\(?:[-+*]\\|\\(?:[0-9]+\\|[A-Za-z]\\)[.)]\\)\\(?:[ \t]+\\|$\\)\\)"
@@ -386,7 +387,7 @@ group 4: description tag")
((= org-plain-list-ordered-item-terminator ?\)) ")")
((= org-plain-list-ordered-item-terminator ?.) "\\.")
(t "[.)]")))
- (alpha (if org-alphabetical-lists "\\|[A-Za-z]" "")))
+ (alpha (if org-list-allow-alphabetical "\\|[A-Za-z]" "")))
(concat "\\([ \t]*\\([-+]\\|\\(\\([0-9]+" alpha "\\)" term
"\\)\\)\\|[ \t]+\\*\\)\\([ \t]+\\|$\\)")))
@@ -400,7 +401,7 @@ group 4: description tag")
(save-excursion
(goto-char (match-end 0))
(let ((counter-re (concat "\\(?:\\[@\\(?:start:\\)?"
- (if org-alphabetical-lists
+ (if org-list-allow-alphabetical
"\\([0-9]+\\|[A-Za-z]\\)"
"[0-9]+")
"\\][ \t]*\\)")))
@@ -1208,7 +1209,7 @@ some heuristics to guess the result."
(point))))))))
(cond
;; Trivial cases where there should be none.
- ((or org-empty-line-terminates-plain-lists (not insert-blank-p)) 0)
+ ((or org-list-empty-line-terminates-plain-lists (not insert-blank-p)) 0)
;; When `org-blank-before-new-entry' says so, it is 1.
((eq insert-blank-p t) 1)
;; `plain-list-item' is 'auto. Count blank lines separating
@@ -1613,7 +1614,7 @@ bullets between START and END."
STRUCT is list structure. PREVS is the alist of previous items,
as returned by `org-list-prevs-alist'."
- (and org-alphabetical-lists
+ (and org-list-allow-alphabetical
(catch 'exit
(let ((item first) (ascii 64) (case-fold-search nil))
;; Pretend that bullets are uppercase and check if alphabet
@@ -2429,7 +2430,7 @@ With optional prefix argument ALL, do this for the whole buffer."
(let ((cookie-re "\\(\\(\\[[0-9]*%\\]\\)\\|\\(\\[[0-9]*/[0-9]*\\]\\)\\)")
(box-re "^[ \t]*\\([-+*]\\|\\([0-9]+\\|[A-Za-z]\\)[.)]\\)[ \t]+\\(?:\\[@\\(?:start:\\)?\\([0-9]+\\|[A-Za-z]\\)\\][ \t]*\\)?\\(\\[[- X]\\]\\)")
(recursivep
- (or (not org-hierarchical-checkbox-statistics)
+ (or (not org-checkbox-hierarchical-statistics)
(string-match "\\<recursive\\>"
(or (org-entry-get nil "COOKIE_DATA") ""))))
(bounds (if all