Function: gnus-topic-move

gnus-topic-move is an interactive and byte-compiled function defined in gnus-topic.el.gz.

Signature

(gnus-topic-move CURRENT TO)

Documentation

Move the CURRENT topic to TO.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/gnus/gnus-topic.el.gz
(defun gnus-topic-move (current to)
  "Move the CURRENT topic to TO."
  (interactive
   (list
    (gnus-group-topic-name)
    (gnus-completing-read "Move to topic" (mapcar #'car gnus-topic-alist) t))
   gnus-topic-mode)
  (unless (and current to)
    (error "Can't find topic"))
  (let ((current-top (cdr (gnus-topic-find-topology current)))
	(to-top (cdr (gnus-topic-find-topology to))))
    (unless current-top
      (error "Can't find topic `%s'" current))
    (unless to-top
      (error "Can't find topic `%s'" to))
    (if (gnus-topic-find-topology to current-top 0);; Don't care the level
	(error "Can't move `%s' to its sub-level" current))
    (gnus-topic-find-topology current nil nil 'delete)
    (setcdr (last to-top) (list current-top))
    (gnus-topic-enter-dribble)
    (gnus-group-list-groups)
    (gnus-topic-goto-topic current)))