Function: org-agenda-toggle-archive-tag

org-agenda-toggle-archive-tag is an interactive and byte-compiled function defined in org-agenda.el.gz.

Signature

(org-agenda-toggle-archive-tag)

Documentation

Toggle the archive tag for the current entry.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/org/org-agenda.el.gz
(defun org-agenda-toggle-archive-tag ()
  "Toggle the archive tag for the current entry."
  (interactive)
  (org-agenda-check-no-diary)
  (org-agenda-maybe-loop
   #'org-agenda-toggle-archive-tag nil nil nil
   (let* ((hdmarker (or (org-get-at-bol 'org-hd-marker)
			(org-agenda-error)))
	  (buffer (marker-buffer hdmarker))
	  (pos (marker-position hdmarker))
	  (inhibit-read-only t)
	  newhead)
     (org-with-remote-undo buffer
       (with-current-buffer buffer
	 (widen)
	 (goto-char pos)
	 (org-fold-show-context 'agenda)
	 (call-interactively 'org-toggle-archive-tag)
	 (end-of-line 1)
	 (setq newhead (org-get-heading)))
       (org-agenda-change-all-lines newhead hdmarker)
       (beginning-of-line 1)))))