[xmonad] Raising Amarok

Gwern Branwen gwern0 at gmail.com
Mon Jun 2 18:52:40 EDT 2008

On 2008.06.01 23:36:44 -0500, Spencer Janssen <sjanssen at cse.unl.edu> scribbled 1.2K characters:
> On Sun, Jun 01, 2008 at 11:18:57PM -0500, Spencer Janssen wrote:
> > On Sun, Jun 01, 2008 at 06:27:18PM -0400, Gwern Branwen wrote:
> > > Ho everyone:
> > >
> > > I recently installed Ubuntu, and so could now use Amarok (the Gentoo installation being messed up for me), and all is well. I went to add a keybinding:
> > >
> > > >          , ((m,              xK_a), runOrRaise "amarok" (title =? "Amarok"))
> > >
> > > And it is kind of odd. It is the correct name, and it works correctly when Amarok is not running - but if Amarok is running, it only causes a file dialogue to open up instead of the right thing. (See attached screenshots.)
> > >
> > > Is this Amarok's fault? Any ideas how to work around it?
> > >
> > > --
> > > gwern
> > > FSK S511 Zemin Monica PABX NSG mercur text Meade ULF
> >
> > Try matching on the WM_CLASS (note that it is set to "amarokapp") instead. If
> > this works, there might be some problem with the 'title' function.
> Very good advice, Spencer.  I'd also add that Amarok changes title when music
> is playing, making it rather likely that this is not an issue with xmonad's
> 'title' function at all.  WM_CLASS should be much more robust here since it is
> a violation of the ICCCM to change those properties after requesting that the
> window be mapped.

Yes, className "amarokapp" works fine. I asked because title to me was not failing in a familiar way - usually when I use 'title' and it fails, it is because the title has changed, and so title fails to find the existing app and it then falls through to the run part. It does not usually "sort of work" by bringing up some file dialogue!

sweeping Hitwords Intelsat Counter Cohiba Sayeret Rumsfeld VOA warfare encryption
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://www.haskell.org/pipermail/xmonad/attachments/20080602/ff43fde6/attachment.bin

More information about the xmonad mailing list