forked from mirrors/org-mode
org-print-speed-command: Rename and mark for internal use
* etc/ORG-NEWS (~org-print-speed-command~ is now an internal function): Announce the change. * lisp/org-compat.el (org-print-speed-command): Mark obsolete. * lisp/org-keys.el (org--print-speed-command): Rename as internal function. Add docstring. Rename the argument to be more clear. (org-speed-command-help): Use the new function name.
This commit is contained in:
parent
a0ee5d4c33
commit
5e946d3673
|
@ -13,6 +13,14 @@ Please send Org bug reports to mailto:emacs-orgmode@gnu.org.
|
||||||
|
|
||||||
* Version 9.7 (not released yet)
|
* Version 9.7 (not released yet)
|
||||||
** Important announcements and breaking changes
|
** Important announcements and breaking changes
|
||||||
|
*** ~org-print-speed-command~ is now an internal function
|
||||||
|
|
||||||
|
The old name is marked obsolete and the new name is
|
||||||
|
~org--print-speed-command~.
|
||||||
|
|
||||||
|
This function was always aimed for internal use when building speed
|
||||||
|
command help buffer. Now, it is stated explicitly.
|
||||||
|
|
||||||
*** Babel references =FILE:REFERENCE= now search current buffer when =FILE= does not exist
|
*** Babel references =FILE:REFERENCE= now search current buffer when =FILE= does not exist
|
||||||
|
|
||||||
When =FILE= does not exist, the reference is searched in the current
|
When =FILE= does not exist, the reference is searched in the current
|
||||||
|
|
|
@ -1197,6 +1197,10 @@ context. See the individual commands for more information."
|
||||||
(define-obsolete-function-alias 'org-export-get-parent-element
|
(define-obsolete-function-alias 'org-export-get-parent-element
|
||||||
'org-element-parent-element "9.7")
|
'org-element-parent-element "9.7")
|
||||||
|
|
||||||
|
(define-obsolete-function-alias 'org-print-speed-command
|
||||||
|
'org--print-speed-command "9.7"
|
||||||
|
"Internal function. Subject of unannounced changes.")
|
||||||
|
|
||||||
;;;; Obsolete link types
|
;;;; Obsolete link types
|
||||||
|
|
||||||
(eval-after-load 'ol
|
(eval-after-load 'ol
|
||||||
|
|
|
@ -789,19 +789,22 @@ command."
|
||||||
(function)
|
(function)
|
||||||
(sexp))))))
|
(sexp))))))
|
||||||
|
|
||||||
(defun org-print-speed-command (e)
|
(defun org--print-speed-command (speed-command)
|
||||||
(if (> (length (car e)) 1)
|
"Print information about SPEED-COMMAND in help buffer.
|
||||||
|
SPEED-COMMAND is an element of `org-speed-commands' or
|
||||||
|
`org-speed-commands-user'."
|
||||||
|
(if (> (length (car speed-command)) 1)
|
||||||
(progn
|
(progn
|
||||||
(princ "\n")
|
(princ "\n")
|
||||||
(princ (car e))
|
(princ (car speed-command))
|
||||||
(princ "\n")
|
(princ "\n")
|
||||||
(princ (make-string (length (car e)) ?-))
|
(princ (make-string (length (car speed-command)) ?-))
|
||||||
(princ "\n"))
|
(princ "\n"))
|
||||||
(princ (car e))
|
(princ (car speed-command))
|
||||||
(princ " ")
|
(princ " ")
|
||||||
(if (symbolp (cdr e))
|
(if (symbolp (cdr speed-command))
|
||||||
(princ (symbol-name (cdr e)))
|
(princ (symbol-name (cdr speed-command)))
|
||||||
(prin1 (cdr e)))
|
(prin1 (cdr speed-command)))
|
||||||
(princ "\n")))
|
(princ "\n")))
|
||||||
|
|
||||||
(defun org-speed-command-help ()
|
(defun org-speed-command-help ()
|
||||||
|
@ -811,7 +814,7 @@ command."
|
||||||
(user-error "Speed commands are not activated, customize `org-use-speed-commands'"))
|
(user-error "Speed commands are not activated, customize `org-use-speed-commands'"))
|
||||||
(with-output-to-temp-buffer "*Help*"
|
(with-output-to-temp-buffer "*Help*"
|
||||||
(princ "Speed commands\n==============\n")
|
(princ "Speed commands\n==============\n")
|
||||||
(mapc #'org-print-speed-command
|
(mapc #'org--print-speed-command
|
||||||
;; FIXME: don't check `org-speed-commands-user' past 9.6
|
;; FIXME: don't check `org-speed-commands-user' past 9.6
|
||||||
(if (boundp 'org-speed-commands-user)
|
(if (boundp 'org-speed-commands-user)
|
||||||
(append org-speed-commands
|
(append org-speed-commands
|
||||||
|
|
Loading…
Reference in New Issue