rendered paste body#!/bin/sh
WINFO=`xwininfo -root -tree | grep "$1" | egrep ' (2[0-9]|[2-3][0-9])x(2[0-9]|[2-3][0-9])\+0\+0' | cut -d ')' -f 2-`
WINFO=`echo $WINFO | cut -d 'x' -f 2-`
WINFO=`echo $WINFO | cut -d '+' -f 2-`
WINFO=`echo $WINFO | cut -d '0' -f 2-`
WINFO=`echo $WINFO | cut -d '0' -f 2-`
WIX=`echo $WINFO | cut -d '+' -f 2`
WIY=`echo $WINFO | cut -d '+' -f 3`
WIX=`expr $WIX + 15`
WIY=`expr $WIY + 15`
dbus-send --type=method_call --dest=org.freedesktop.compiz /org/freedesktop/compiz/water/allscreens/point org.freedesktop.compiz.activate string:'root' int32:`xwininfo -root | grep id: | awk '{ print $4 }'` string:'amplitude' double:1000 string:'x' int32:$WIX string:'y' int32:$WIY
chmod +x water_notify.sh
dans la conf de pidgin ~/.purple/prefs.xml
<pref name='sound'>
<pref name='enabled'>
<pref name='login' type='bool' value='0'/>
<pref name='logout' type='bool' value='0'/>
<pref name='im_recv' type='bool' value='1'/>
<pref name='first_im_recv' type='bool' value='1'/>
<pref name='send_im' type='bool' value='0'/>
<pref name='join_chat' type='bool' value='0'/>
<pref name='left_chat' type='bool' value='0'/>
<pref name='send_chat_msg' type='bool' value='0'/>
<pref name='chat_msg_recv' type='bool' value='1'/>
<pref name='nick_said' type='bool' value='0'/>
<pref name='pounce_default' type='bool' value='1'/>
</pref>
<pref name='file'>
<pref name='login' type='path' value='/usr/share/sounds/purple/receive.wav'/>
<pref name='logout' type='path' value=''/>
<pref name='im_recv' type='path' value=''/>
<pref name='first_im_recv' type='path' value=''/>
<pref name='send_im' type='path' value=''/>
<pref name='join_chat' type='path' value=''/>
<pref name='left_chat' type='path' value=''/>
<pref name='send_chat_msg' type='path' value=''/>
<pref name='chat_msg_recv' type='path' value=''/>
<pref name='nick_said' type='path' value=''/>
<pref name='pounce_default' type='path' value=''/>
</pref>
<pref name='conv_focus' type='bool' value='1'/>
<pref name='mute' type='bool' value='0'/>
<pref name='command' type='path' value='/home/mulima/donnees/prog/scripts/water_notification.sh pidgin'/>
<pref name='method' type='string' value='custom'/>
<pref name='volume' type='int' value='50'/>
</pref>