summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Goaziou <mail@nicolasgoaziou.fr>2016-02-17 15:54:07 +0100
committerNicolas Goaziou <mail@nicolasgoaziou.fr>2016-02-17 22:49:19 +0100
commit3debe06bdd94b9de5b7d39cc55e996f2ddf090c4 (patch)
tree2b5d8ea80ce96939f7ab0c633c349b179117d299
parent2c974fc8c8cace282a577e248f5e6939bbfcf6d4 (diff)
downloadorg-mode-3debe06bdd94b9de5b7d39cc55e996f2ddf090c4.tar.gz
Rename `org-insert-columns-dblock' into `org-columns-insert-dblock'
* lisp/org-colview.el (org-columns-dblock-insert): Rename to... (org-columns-insert-dblock): ... this. Also fix a bug that would insert "local" instead of `local' as the :id value. * lisp/org.el (org-mode-map): (org-org-menu): Use new name.
-rw-r--r--etc/ORG-NEWS3
-rw-r--r--lisp/org-colview.el20
-rw-r--r--lisp/org.el4
3 files changed, 16 insertions, 11 deletions
diff --git a/etc/ORG-NEWS b/etc/ORG-NEWS
index 90923c8..5ae88d2 100644
--- a/etc/ORG-NEWS
+++ b/etc/ORG-NEWS
@@ -308,8 +308,9 @@ Variable ~org-html-table-row-tags~ has been split into
~org-html-table-row-open-tag~ and ~org-html-table-row-close-tag~.
Both new variables can be either a string or a function which will be
called with 6 parameters.
-
*** =ITEM= special property returns headline without stars
+*** Rename ~org-insert-columns-dblock~ into ~org-columns-insert-dblock~
+The previous name is, for the time being, kept as an obsolete alias.
* Version 8.3
** Incompatible changes
diff --git a/lisp/org-colview.el b/lisp/org-colview.el
index cc33325..47417be 100644
--- a/lisp/org-colview.el
+++ b/lisp/org-colview.el
@@ -1322,19 +1322,23 @@ PARAMS is a property list of parameters:
(org-table-align)))))
;;;###autoload
-(defun org-insert-columns-dblock ()
+(defun org-columns-insert-dblock ()
"Create a dynamic block capturing a column view table."
(interactive)
- (let ((defaults '(:name "columnview" :hlines 1))
- (id (completing-read
+ (let ((id (completing-read
"Capture columns (local, global, entry with :ID: property) [local]: "
(append '(("global") ("local"))
(mapcar #'list (org-property-values "ID"))))))
- (if (equal id "") (setq id 'local))
- (if (equal id "global") (setq id 'global))
- (setq defaults (append defaults (list :id id)))
- (org-create-dblock defaults)
- (org-update-dblock)))
+ (org-create-dblock
+ (list :name "columnview"
+ :hlines 1
+ :id (cond ((string= id "global") 'global)
+ ((member id '("" "local")) 'local)
+ (id)))))
+ (org-update-dblock))
+
+(define-obsolete-function-alias 'org-insert-columns-dblock
+ 'org-columns-insert-dblock "Org 9.0")
diff --git a/lisp/org.el b/lisp/org.el
index 11a30c8..951586c 100644
--- a/lisp/org.el
+++ b/lisp/org.el
@@ -19905,7 +19905,7 @@ boundaries."
(org-defkey org-mode-map "\C-c\C-xe" 'org-set-effort)
(org-defkey org-mode-map "\C-c\C-xE" 'org-inc-effort)
(org-defkey org-mode-map "\C-c\C-xo" 'org-toggle-ordered-property)
-(org-defkey org-mode-map "\C-c\C-xi" 'org-insert-columns-dblock)
+(org-defkey org-mode-map "\C-c\C-xi" 'org-columns-insert-dblock)
(org-defkey org-mode-map [(control ?c) (control ?x) ?\;] 'org-timer-set-timer)
(org-defkey org-mode-map "\C-c\C-x." 'org-timer)
@@ -21757,7 +21757,7 @@ on context. See the individual commands for more information."
"--"
["Set property" org-set-property (not (org-before-first-heading-p))]
["Column view of properties" org-columns t]
- ["Insert Column View DBlock" org-insert-columns-dblock t])
+ ["Insert Column View DBlock" org-columns-insert-dblock t])
("Dates and Scheduling"
["Timestamp" org-time-stamp (not (org-before-first-heading-p))]
["Timestamp (inactive)" org-time-stamp-inactive (not (org-before-first-heading-p))]