Function: tmm-shortcut
tmm-shortcut is an interactive and byte-compiled function defined in
tmm.el.gz.
Signature
(tmm-shortcut)
Documentation
Choose the shortcut that the user typed.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/tmm.el.gz
(defun tmm-shortcut ()
"Choose the shortcut that the user typed."
(interactive)
(let ((c last-command-event) s)
(if (symbolp tmm-shortcut-style)
(setq c (funcall tmm-shortcut-style c)))
(if (memq c tmm-short-cuts)
(if (equal (buffer-name) "*Completions*")
(progn
(goto-char (point-min))
(re-search-forward
(concat "\\(^\\|[ \t]\\)" (char-to-string c) tmm-mid-prompt))
(choose-completion))
;; In minibuffer
(delete-region (minibuffer-prompt-end) (point-max))
(dolist (elt tmm-km-list)
(if (string=
(substring (car elt) 0
(min (1+ (length tmm-mid-prompt))
(length (car elt))))
(concat (char-to-string c) tmm-mid-prompt))
(setq s (car elt))))
(insert s)
(exit-minibuffer)))))