Welcome to the most active Linux Forum on the web.
Go Back > Blogs > radiodee1
User Name


Rate this Entry

Sound notification when email is recieved (gnome - evolution)

Posted 06-11-2009 at 08:18 AM by radiodee1
Updated 06-20-2009 at 06:44 AM by radiodee1

This is a duplication of some of the posts I made to the debian forum on LinuxQuestions, as well as some new material. What follows immediately is the first post to the thread. After that I skip around the thread a little. I've purposely only duplicated my own posts here, though some of the others were interesting. To read the original thread go to this link:

I use sqeeze and a little bit of sid. I also use evolution and gnome. I was going through different preferences and I found that if you go to "System->Preferences->Sound" there is a tab that has options for different alerts and sound effects that you can have your system play when certain actions take place. I want to make it so that a sound plays whenever I receive a new email, BUT on my system everything in this tab of the "Sounds Preferences" dialog box is grayed out. I cannot figure out how to get those options un-grayed.

I can clearly see (in the grayed out material) that there is an option for getting notification when mail is received. How do I do this?

When I click the "help" button on the dialog I get a help window that tells me, among other things, that:
You must select the Enable sound server startup option, and the Sounds for events option before you can access the Sound Events tabbed section.
How do I do that? They also mention a "General" tab, which I cannot even find. The only tabs I have are "Devices" and "Sounds". Has anyone else had this experience or anything like it? Thanks.

I googled a little and found someone tried to use gconf to change the keys directly. I went to the key at "/apps/evolution/eplugin/mail-notification" and entered a value in the spot marked "sound-file". I used "/usr/share/sounds/email.wav" but no sound played when I received an email. I find navigating around gconf to be difficult and so I might have missed something.

I got it to work. I installed pulseaudio-esound-compat, as I use pulseaudio (I guess I didn't even know) and restarted and it worked. The sound plays that I specified in gconf. The "Sounds" tab of "System->Preferences->Sound" is still grayed out.

I revisited this thing with the sounds because I wanted to remove pulseaudio and have it still work. I removed all pulseaudio packages and the email notification sounds stopped. I was back where I started, so I googled more and found this on a Ubuntu launchpad site:

Gnome 2.24 uses a different framework for playing sound events called libcanberra. Libcanberra will not play any sound themes unless it can find the freedesktop sound theme to fall back on, in the event that a sound for a particular event cannot be found.

Ubuntu currently doesn't have this theme in a stand-alone package in the archive. It has been packaged for Debian, however it has been rejected for licensing reasons.
This explains why the "sounds" tab on the gnome-sound-properties dialog box is greyed out. Reading further, someone explains how to get the sounds to work using a '' theme. First download the file from here:

Then the author did this:
extract to /usr/share/sounds and then could get some of the sounds working.
I tried this and it worked for me. Now my sound notification works under alsa, and the "sounds" tab is no longer grayed out. This is the page that has all the original info on it:

EDIT: I'm wrong again. In fact installing those files un-grays the "sounds" dialog, but it doesn't make the sounds audible. I'm gonna have to do more messing with these sounds.

I found this link today:

It's a bug report for evolution that basically says that the "Mail Notification" plugin for evolution is broken, or at least seems to be. The funny thing is that I got something to work when I had pulseaudio installed.

Trying to make sense of it all:
The gnome-sound-properties dialog from gnome 2.24 doesn't work because the sound theme could not be downloaded from the debian sites (due to licensing problems). If, however, you download the theme seperately the gnome-sound-properties dialog becomes active. You can then setup your system to play sounds for different desktop events, and you can even change which sounds get played with which events. Unfortunately the "Email Notification" event doesn't work. Why? I'm not sure.

The gnome-sound-properties dialog box is part of the package "gnome-control-center", and this is part of the 2.24 release of gnome. Evolution is, as of this writing, part of the 2.26 release of gnome. Maybe this explains why the gnome-sound-properties dialog plays sounds for most every desktop action except evolution mail notifications.

When I managed to get the sound notification to work with pulseaudio, this was probably a result of the interaction between pulseaudio and the evolution plugin for email notification, not the gnome-sound-properties program. This is because the key that I modified in the gconf database was called "/apps/evolution/eplugin/mail-notification". This plugin may have interacted directly with pulseaudio, not messing with gnome-sound-properties or canberra.

Finally, as an aside, I found that if you go to the gconf key at "/desktop/gnome/sound" you can set the "enable_esd" checkbox and thereby get sounds at login and logout. This may be similar to what happens when you install the debian package for that purpose.

Today I was looking at the gnome site and their description of the 2.26 release and especially the sound preferences. "gnome-control-center" is in unstable now, so I installed it. At first I was disappointed because there was not "gnome-sound-properties" to be found. Then I installed pulseaudio again. The volume control program ("gnome-volume-control") automatically became more complicated when I installed pulseaudio, resembling what I had found on the Gnome 2.26 web site. I was a little happier.

I went to evolution and turned on the Mail Notification plugin and selected a ".wav" file (only .wav would work) and restarted the computer. The file played when I received mail. My only problem was that the pulseaudio sound preferences would set all the audio outputs to "mute" every time I restarted the computer. Manually I needed to change the mute and output level if I wanted to hear any audio at all. I found, though, the option for "Simultaneous Output to HDA ATI SB" worked, and after setting that the output levels were persistent after a restart.

I'm wrong again. Under the "Output" tab I have three options. One is "HDA ATI SB" and one is "Simultaneous Output to HDA ATI SB". I thought the one "Simultaneous Output..." was the better one, but may not be. The notification sound doesn't play for that one. The "HDA ATI SB" option is good because the notification sound plays, but the output levels aren't persistent after a restart, as I noted above. I guess I'll stick with that, though, until I can figure something else out.
Posted in Uncategorized
Views 5926 Comments 0
« Prev     Main     Next »


All times are GMT -5. The time now is 06:10 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration