Copyright (C) 2000-2012 |
GNU Info (emacs-lisp-intro.info)rotate-yank-pointerThe `rotate-yank-pointer' Function ================================== The `rotate-yank-pointer' function changes the element in the kill ring to which `kill-ring-yank-pointer' points. For example, it can change `kill-ring-yank-pointer' from pointing to the second element to point to the third element. Here is the code for `rotate-yank-pointer': (defun rotate-yank-pointer (arg) "Rotate the yanking point in the kill ring." (interactive "p") (let ((length (length kill-ring))) (if (zerop length) ;; then-part (error "Kill ring is empty") ;; else-part (setq kill-ring-yank-pointer (nthcdr (% (+ arg (- length (length kill-ring-yank-pointer))) length) kill-ring)))))
automatically generated by info2www version 1.2.2.9 |