comparison lisp/subr.el @ 83156:8e09aff3715a

Merged in changes from CVS trunk. Patches applied: * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-383 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-384 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-385 src/xfaces.c (push_named_merge_point): Return 0 if a cycle is detected * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-386 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-387 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-388 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-389 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-390 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-391 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-392 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-393 Update from CVS git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-196
author Karoly Lorentey <lorentey@elte.hu>
date Thu, 10 Jun 2004 17:17:08 +0000
parents 2e868590c17b bb7bcfc53d76
children a79c4db19c4f
comparison
equal deleted inserted replaced
83155:235fb3b11e1f 83156:8e09aff3715a
1337 (setq prompt 1337 (setq prompt
1338 (if (string-match "\\(\\):[ \t]*\\'" prompt) 1338 (if (string-match "\\(\\):[ \t]*\\'" prompt)
1339 (replace-match (format " (default %s)" default) t t prompt 1) 1339 (replace-match (format " (default %s)" default) t t prompt 1)
1340 (replace-regexp-in-string "[ \t]*\\'" 1340 (replace-regexp-in-string "[ \t]*\\'"
1341 (format " (default %s) " default) 1341 (format " (default %s) " default)
1342 prompt t t)))) 1342 prompt t t))))
1343 (while 1343 (while
1344 (progn 1344 (progn
1345 (let ((str (read-from-minibuffer prompt nil nil nil nil 1345 (let ((str (read-from-minibuffer prompt nil nil nil nil
1346 (and default 1346 (and default
1347 (number-to-string default))))) 1347 (number-to-string default)))))
1706 (setq this-command (nth 4 handler))))) 1706 (setq this-command (nth 4 handler)))))
1707 1707
1708 (defun insert-buffer-substring-no-properties (buffer &optional start end) 1708 (defun insert-buffer-substring-no-properties (buffer &optional start end)
1709 "Insert before point a substring of BUFFER, without text properties. 1709 "Insert before point a substring of BUFFER, without text properties.
1710 BUFFER may be a buffer or a buffer name. 1710 BUFFER may be a buffer or a buffer name.
1711 Arguments START and END are character numbers specifying the substring. 1711 Arguments START and END are character positions specifying the substring.
1712 They default to the beginning and the end of BUFFER." 1712 They default to the values of (point-min) and (point-max) in BUFFER."
1713 (let ((opoint (point))) 1713 (let ((opoint (point)))
1714 (insert-buffer-substring buffer start end) 1714 (insert-buffer-substring buffer start end)
1715 (let ((inhibit-read-only t)) 1715 (let ((inhibit-read-only t))
1716 (set-text-properties opoint (point) nil)))) 1716 (set-text-properties opoint (point) nil))))
1717 1717
1718 (defun insert-buffer-substring-as-yank (buffer &optional start end) 1718 (defun insert-buffer-substring-as-yank (buffer &optional start end)
1719 "Insert before point a part of BUFFER, stripping some text properties. 1719 "Insert before point a part of BUFFER, stripping some text properties.
1720 BUFFER may be a buffer or a buffer name. 1720 BUFFER may be a buffer or a buffer name.
1721 Arguments START and END are character numbers specifying the substring. 1721 Arguments START and END are character positions specifying the substring.
1722 They default to the beginning and the end of BUFFER. 1722 They default to the values of (point-min) and (point-max) in BUFFER.
1723 Strip text properties from the inserted text according to 1723 Strip text properties from the inserted text according to
1724 `yank-excluded-properties'." 1724 `yank-excluded-properties'."
1725 ;; Since the buffer text should not normally have yank-handler properties, 1725 ;; Since the buffer text should not normally have yank-handler properties,
1726 ;; there is no need to handle them here. 1726 ;; there is no need to handle them here.
1727 (let ((opoint (point))) 1727 (let ((opoint (point)))