# HG changeset patch # User yuuji@gentei.org # Date 1328744722 -32400 # Node ID d5e0c33d7dfdd4294eef4b8046dd289adff72271 # Parent 74229d191b1787e80c4ab4be565d4d7f8be0ca49 YaTeX-completing-read-or-skip introduced diff -r 74229d191b17 -r d5e0c33d7dfd yatexlib.el --- a/yatexlib.el Thu Feb 09 08:41:53 2012 +0900 +++ b/yatexlib.el Thu Feb 09 08:45:22 2012 +0900 @@ -2,7 +2,7 @@ ;;; YaTeX and yahtml common libraries, general functions and definitions ;;; yatexlib.el ;;; (c)1994-2012 by HIROSE Yuuji.[yuuji@yatex.org] -;;; Last modified Sun Jan 29 13:17:21 2012 on firestorm +;;; Last modified Thu Feb 9 08:32:18 2012 on firestorm ;;; $Id$ ;; General variables @@ -759,6 +759,12 @@ "" (apply 'read-string args))) +(defun YaTeX-completing-read-or-skip (&rest args) + "Do completing-read, or skip if last input char is \C-j." + (if (equal last-input-char YaTeX-skip-next-reader-char) + "" + (apply 'completing-read args))) + ;;;###autoload (fset 'YaTeX-rassoc (if (and nil (fboundp 'rassoc) (subrp (symbol-function 'rassoc)))