aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPavel Janík2002-04-05 05:50:11 +0000
committerPavel Janík2002-04-05 05:50:11 +0000
commitde6debfb1ce40233a91a4a1dce2f4f13e8d9496e (patch)
tree9a89a1e6d41a9db0140be5da9deb192fc34b6164
parent14e415e7eea3e8c6b39f1126f6dce2ee8f91b28f (diff)
downloademacs-de6debfb1ce40233a91a4a1dce2f4f13e8d9496e.tar.gz
emacs-de6debfb1ce40233a91a4a1dce2f4f13e8d9496e.zip
(play-sound): New function (uses play-sound-internal).
-rw-r--r--lisp/simple.el21
1 files changed, 21 insertions, 0 deletions
diff --git a/lisp/simple.el b/lisp/simple.el
index eefac3fce0f..da2e3520074 100644
--- a/lisp/simple.el
+++ b/lisp/simple.el
@@ -3355,6 +3355,27 @@ specification for `play-sound'."
3355 (push 'sound sound) 3355 (push 'sound sound)
3356 (play-sound sound))) 3356 (play-sound sound)))
3357 3357
3358(defun play-sound (sound)
3359 "SOUND is a list of the form `(sound KEYWORD VALUE...)'.
3360The following keywords are recognized:
3361
3362 :file FILE - read sound data from FILE. If FILE isn't an
3363absolute file name, it is searched in `data-directory'.
3364
3365 :data DATA - read sound data from string DATA.
3366
3367Exactly one of :file or :data must be present.
3368
3369 :volume VOL - set volume to VOL. VOL must an integer in the
3370range 0..100 or a float in the range 0..1.0. If not specified,
3371don't change the volume setting of the sound device.
3372
3373 :device DEVICE - play sound on DEVICE. If not specified,
3374a system-dependent default device name is used."
3375 (unless (fboundp 'play-sound-internal)
3376 (error "This Emacs binary lacks sound support."))
3377 (play-sound-internal sound))
3378
3358(define-key global-map "\e\e\e" 'keyboard-escape-quit) 3379(define-key global-map "\e\e\e" 'keyboard-escape-quit)
3359 3380
3360(defcustom read-mail-command 'rmail 3381(defcustom read-mail-command 'rmail