What’re you listening to?

At the moment, I can only start most KDE3 applications by clearing the environment of KDE4 things (basically by su’ing to myself) and running them from there.  Which means session management doesn’t work.  I got fed up with doing this with Amarok, so I’ve started using Juk as a stand-in until Amarok 2 is usable.

Now, I miss kirocker, which provided my KDE3 desktop with information about what music was playing in Amarok.  But, Plasma to the rescue!  In a reasonably short amount of time, I had a nowplaying data engine that queried Juk for what was currently being played.  It should be easily extensible to work with other players, but Juk is what I’m using at the moment.

I also hacked together a rough-and-ready applet that displays some of the information:

The Now Playing Applet

The engine should probably get some ability to execute commands like “play”, “pause”, “stop”, “next” and “previous”.  Publishing the volume might be a good idea, too.

The applet needs a lot of work.  In theory, the engine can pass album artwork, although Juk doesn’t publish it.  And there’s a lot more information available than what it printed there.  And long titles result in very small text.  If you fancy hacking around with the applet and making it pretty, be my guest: it’s all in playground.


7 Responses to “What’re you listening to?”

  1. Chani Says:

    cool! how’s juk itself? I’ve been meaning to compile that. haven’t used it in ages.

  2. randomguy3 Says:

    It’s usable, certainly. Not that I do anything spectacular with media players – I tend to put them on random and leave them going.

    It didn’t like me trying to change the global shortcuts to match what I was used to from Amarok, though.

  3. Diederik van der Boor Says:

    It would be really cool if each application doesn’t have to query all media players. e.g. with KMess I query all DCOP-enabled players at the moment.

    Instead, I’d love to have *ONE* central location which tracks the current players. Each application could read from that same location, including your applet data source. 😉

  4. Diederik van der Boor Says:

    Forgot to mention: really awesome to see developments for a “now playing” applet. Like you said, combined with artwork and player controls it would be a brilliant improvement for plasma. 🙂

    Now since applets can be moved from the desktop to the taskbar etc.. this would be really cool in combination with such new “now playing” control. whoah 😛 plasma is going to rock!

  5. kwilliam Says:

    I just installed Kirocker yesterday, and LOVE it, particularly the full screen mode. I’m thrilled to see somebody starting on a Plasma version, particularly since the Kirocker developer is not continuing to develop Kiriocker. I also love the idea of having a single Now Playing data engine that can poll different media players. (Presumably, it could support all the KDE players, and possibly others like VLC and MPlayer.)

  6. randomguy3 Says:

    The full screen mode is very nice, especially when working in front of the computer on traditional pen & paper.

    Don’t expect anything like that until 4.1 at least, but I’m hoping to have as many media players supported as possible. In theory, anything can work if there’s a way to query it. KDE and Gnome apps should all be accessible through D-Bus, and at least xmms has remote control functionality.

  7. Felix M. Wells Says:

    Very nice applet! I feel that Juk is somewhat neglected so it’s always nice to see little extentions for it and such. Although, Amarok 2 will be fantastic when it becomes usable.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: