Thirteen alerts are already written for all four alert categories. These all obey the result from the corresponding message function.
beep alerts simply sound the terminal bell by calling
ding. They are disabled by default.
echo alerts display a message in the echo area by calling
message. They are enabled by default.
switch alerts switch to the buffer where the event occurred
(chat buffer for incoming messages, roster buffer for presence
changes, browse buffer for completed queries). They are disabled by
default. Take care when using them, as they may interrupt your
display alerts display but do not select the buffer in
question, using the function
display-buffer. See Choosing a Window for Display, for information about customizing its behaviour.
This is enabled by default for info requests.
wave alerts play a sound file by calling
play-sound-file. No sound files are provided. To use this,
enter the names of the sound files in
jabber-alert-info-wave, respectively. You can specify
specific sound files for contacts matching a regexp in the variables
screen alerts send a message through the Screen terminal
manager1. They do no
harm if called when you don't use Screen.
ratpoison alerts send a message through the Ratpoison
window manager2. They
do no harm if used when you're not running X, but if you are running X
with another window manager, the ratpoison processes will never exit.
Emacs doesn't hold on to them, though.
sawfish alerts send a message through the Sawfish window
wmii alerts display a message through the wmii window
xmessage alerts send a message through the standard
xmessage tool. The variable
controls how long the alert appears.
osd alerts send a message onto your screen using
libnotify alerts send a message onto your screen using
festival alerts speak the message using the Emacs interface
of the Festival speech synthesis system4.
autoanswer alert is kind of special: it will not show you
message/muc alert, but instead will automaticaly answer to sender. See
variable `jabber-autoanswer-alist' description for details.
Additionally, for one-to-one and MUC messages, there are
alerts (enabled by default), that aim to do the right thing with chat
buffers that are visible but not active. Sometimes you want point to
scroll down, and sometimes not. These functions should do what you
mean; if they don't, it's a bug.
Also, in MUC you can use a family of so-called “personal” alerts.
They are like other MUC alerts, but fire only on incoming messages
addresed directly to you (also known as “private messages”). One
example of such an alert is
jabber-muc-echo-personal, which shows
a note for an MUC message only if it was addressed to you.
Some of these functions are in the jabber-alert.el file, and the others are in their own files. You can use them as templates or inspiration for your own alerts.