PDA

View Full Version : Water Effect Notification


Fleece Flamingo
January 29th, 2008, 04:53 AM
Hey, I'm new to the forums so help me out
Recently I saw a video on youtube about a pidgin water drop notification. After searching and searching I found this thread http://forum.compiz-fusion.org/showthread.php?t=2191
However, having completed the whole "howto" nothing happens when I get a message in pidgin.
I am running Ubuntu 7.10 (Gutsy Gibbon)

Deciare
January 29th, 2008, 05:48 AM
Exactly which post's instructions did you follow? Several sets of instructions and scripts were suggested by different people.

For the sake of testing, try running this command in a console window:
dbus-send --print-reply --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:1 string:'x' int32:250 string:'y' int32:250
Do you see a ripple somewhere near the top-left corner of your screen? Do you see any output in the console?

What about the output of the next command? (Please make sure Pidgin is running first.)
xwininfo -root -tree | egrep ' (1[2-9]|2[0-4])x(1[2-9]|2[0-4])\+0\+0' | grep "pidgin" | cut -d ')' -f 2-

Fleece Flamingo
January 29th, 2008, 06:04 AM
I enter the first code into terminal and I dont get a ripple effect but I do get this output.
Error org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.compiz was not provided by any .service files

Oh, also I used the code from the first post in the development thread. Also, in CCSM does it matter if I the initiate command is disabled the water effect?

crdlb
January 29th, 2008, 06:16 AM
Please ensure that you have the Dbus plugin enabled in CCSM

Fleece Flamingo
January 29th, 2008, 06:26 AM
Oh ok thanks, for the first code I do get a ripple effect but more or less towards the middle of the screen
output of the second command is 22x22+0+0 +945+1

Oh Haha that enabling Dbus fixed it. Thanks, but when I get a message I get two ripples instead of one. And is there anyway to configure it to work with awn?

Fleece Flamingo
January 29th, 2008, 06:35 AM
And if I wanted to use this code what would I name it as (senicon.sh or waterping.sh) and where would I save it?

#!/bin/bash
#Panel layout - Top || Bottom || Left || Right
LAYOUT="Bottom"

if [ "x$1" == "x" ]; then
echo "Please specify the icon name, f. ex. 'pidgin' as parameter 1";
exit 0
fi

WINFO=`xwininfo -root -tree -name "$LAYOUT Expanded Edge Panel"| grep "$1" | cut -d ')' -f 2-`
WIW=`echo $WINFO | cut -d 'x' -f 1`
WIH=`echo $WINFO | cut -d 'x' -f 2 | cut -d '+' -f 1`
WIX=`echo $WINFO | cut -d '+' -f 4`
WIY=`echo $WINFO | cut -d '+' -f 5`
let WAX=WIX+WIW/2
let WAY=WIY+WIH/2

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:1 string:'x' int32:$WAX string:'y' int32:$WAY

Deciare
January 29th, 2008, 01:37 PM
You can name the script anything, but for the sake of simplicity, you should put it into one of the directories listed in your $PATH environment variable. Saving it into /usr/local/bin should work.

Then in Pidgin go into the Preferences manager. Under the Sounds tab set the Method to Command and type in senicon.sh pidgin
Enter the name of your script there instead of senicon.sh, if you called it something else.

And is there anyway to configure it to work with awn?
The script looks for Pidgin's tray icon, so it shouldn't matter which panel software you use as long as there's a place for the tray icon to go.