The Party of Gno

I came across an interesting blog post about the FSF’s strategy on LWN, and thought it was worth sharing.

The essential argument is that the FSF does too much preaching about what people shouldn’t do, without offering constructive alternatives.


Posted by randomguy3 on 2010-06-18T22:24:55Z

D-Bus threading issues

There are some annoying issues and crashes in KDE 4 (and particularly in KRunner and Nepomuk) that are related to the thread-safety (or, rather, thread-non-safety) of libdbus-1.  kde-core-devel has seen some discussion about this recently.

There is a patch that fixes the issue, but it won’t make it into D-Bus before dbus-1.4, due to the fact that it changes the library behaviour and could potentially break bindings.  Thiago has confirmed that the change doesn’t break the Qt bindings, and (from the bug report), no-one has found any other bindings it breaks.

This is all just background on why, if you are running Arch Linux, you might want to check out the dbus-core-mt package on the AUR.  It’s dbus-core-1.2.24, as found in core, but with the afformentioned patch applied.  Note, however, that you use it at your own risk – it should improve KDE, but it may well break other stuff.


Posted by randomguy3 on 2010-06-01T00:08:11Z

Sacred Totems

One last Christmas themed one, while we’re still in the season.


Posted by randomguy3 on 2010-01-06T00:44:37Z

Merry Christmas, Charlie Brown

What is it all about?


Posted by randomguy3 on 2009-12-24T12:02:47Z

Exciting Nights at Akademy?

I’ve come away from GCDS with several pieces of clothing I didn’t have before.  Some of them – a T-shirt I bought and three more given out by sponsors – were expected.  Others were not.  One of my roommates had to leave part way through the week, and (unsurprisingly, given that the room was as messy as you might expect from three guys) managed to leave a couple of items behind, which I picked up.  However one item still puzzles me.

I have a pair of jeans that are certainly not mine, and both my GCDS roommates deny owning.  Now, I’m pretty sure that our room didn’t see quite the level of excitement that leads to random people’s clothing being left around.  So the question is: where did they come from?


Posted by randomguy3 on 2009-07-28T22:18:51Z

Akuadec

Another day of the Gran Canaria Desktop Summit. After yesterday’s post, I got several offers of power adaptors. However, I ended up buying one on my way back to the hotel, along with a bunch of food for lunch today (the lunches here at the university are poor and quite expensive for what they are).

In fact, speaking of food, I had the worst meal I’ve had this week, and one of the worst I’ve had in my life, last night. We went to a Chinese all-you-can-eat buffet. Now, now, don’t scoff. I’m had some good (although never excellent) food at all-you-can-eat buffets. It seems that the Canary Islands is not the place for them, though. This one was so bad that after my first plateful, I was still hungry but didn’t want to eat any more. Avoid like the plague.

This was in direct contrast to the meal I had with the Amarok guys the night before, which was really nice (if expensive) – masses of paella, salad, chips and warm chocolate brownie. It was seriously good.

Today we had more Amarok discussions. So far we’ve discussed:

  • liblastfm on Windows
  • Playlist synchronisation
  • Unit testing
  • Whether scripts should be able to respond to Amarok quitting (and potentially slow it down)
  • A UPnP collection
  • Reorganising the source files
  • Playdar
  • The UI for dynamic playlists, and context-sensitive information for the area on the left of Amarok (where collections and services etc. are)
  • The EngineController class
  • Mac/Windows ports

Still to come:

  • Media devices update
  • The evil “organise files” bug (pro tip: don’t use Amarok 2 to organise your files for now)
  • UI clutter

We’ve had a very productive couple of days, and Leo’s been taking photos of the whiteboard, so we have a permanent record of our discussions.  Expect blog posts about the cooler things we discussed.


Posted by randomguy3 on 2009-07-09T11:29:52Z

Guademy

It’s been a while since I posted. Such is life.

I’m really enjoying my first Akademy. I managed to forget a power adapter to convert between my British plug and the European sockets, but Nuno lent me one for a few days. I now have to find my own, though, as he went home today.

So, the conference. The keynotes on Saturday morning were really good. I recommend watching them when the videos are online (which they may be already). Of course, there is some furore over Richard Stallman’s talk, but I think that was always expected.

Yesterday was the KDE e.v. meeting, which I didn’t go to (not being a member of the e.v.). Instead, I slept in (sleep has been in short supply), went to the beach, and hacked. I put together a small plasmoid (87 lines of javascript) to show some controls for a media player. The idea is that you can put this on an auto-hiding panel on your desktop so that they don’t take up screen real estate, but are easily accessibly just by moving your mouse. The other half of the job, of course, is to do one that displays information. Then you can have the information about what song is currently playing permanently visible, and the controls only appear when you want them.

Today we had a very productive discussion on moving KDE to Git. The aim (if everything goes swimmingly) seems to be to move before KDE 4.4 goes into freeze. Amarok is intending to move very soon, though.

Speaking of Amarok, we’ve been sitting in one of the labs discussing things since the Git BoF. It’s amazing how much gets decided how quickly, especially when you’re used to deciding things on mailing lists. This is particularly true for user interface decisions. I’m expecting great things from the next release of Amarok.


Posted by randomguy3 on 2009-07-08T17:09:01Z

Akademy rooms

I figured I’d follow Peter Zhou’s lead and ask if anyone is still looking for a roommate at Akademy. I don’t bite, I promise…


Posted by randomguy3 on 2009-05-25T21:55:59Z

What’s Playing, Doc?

So, I was round at a friend’s, and he was playing with Amarok and the Plasma widgets screensaver, and wanted a way to see what was currently playing when his computer was locked.  Of course, I pointed him towards the Now Playing applet, but it was overkill for what he wanted – he didn’t want the buttons, or the sliders – just a display of the current information.  Well, I was in the mood for playing, and it took me about 15 minutes to construct a javascript plasmoid, most of which was spent researching how to use data engines from them.

The code I left him with was:

layout = new LinearLayout(plasmoid);
layout.setOrientation(QtVertical);

label = new Label();
layout.addItem(label);
label.text = 'No player'

plasmoid.dataUpdate = function(name, data) {
    label.text = 'Info:\n';
    for (var key in data) {
        label.text += key + ': ' + data[key] + '\n';
    }
}

plasmoid.dataEngine("nowplaying").connectSource("org.mpris.amarok", plasmoid, 500);

This was in a file called “main.js” in a subfolder called “contents”. In the plasmoid folder (the folder containing the contents folder), I also put in a metadata.desktop file:


[Desktop Entry]
Name=Simple Now Playing
Comment=Now Playing as Matt likes it
Icon=applications-multimedia
Type=Service
X-Plasma-API=javascript
X-Plasma-MainScript=main.js
X-Plasma-DefaultSize=200,100
X-KDE-ServiceTypes=Plasma/Applet
X-KDE-PluginInfo-Author=Alex Merry
X-KDE-PluginInfo-Email=alex.merry [SPAMNO]@[SPAMNO] kdemail.org
X-KDE-PluginInfo-Name=simplenowplaying
X-KDE-PluginInfo-Version=0.1
X-KDE-PluginInfo-Website=http://plasma.kde.org/
X-KDE-PluginInfo-Category=Multimedia
X-KDE-PluginInfo-Depends=
X-KDE-PluginInfo-License=GPL
X-KDE-PluginInfo-EnabledByDefault=true

Now it was just a case of calling plasmapkg -i . from within the plasmoid directory, and the simple widget was installed. This produces the following:

simple-now-playing

Of course, this will only work with Amarok, and doesn’t respond to Amarok being started or quit. That’s OK, it’s not much more work to deal with that:


layout = new LinearLayout(plasmoid);
layout.setOrientation(QtVertical);

label = new Label();
layout.addItem(label);
label.text = "No player found";

function firstSource() {
	var sources = plasmoid.dataEngine("nowplaying").sources;
	if (sources.length) {
		return sources[0];
	} else {
		label.text = "No player found";
		return '';
	}
}

plasmoid.dataUpdate = function(name, data) {
	if (source == name) {
		label.text = 'Info:\n';
		for (var key in data) {
			label.text += key + ': ' + data[key] + '\n';
		}
	}
}

source = firstSource();

npDataEngine = plasmoid.dataEngine("nowplaying");

npDataEngine.sourceRemoved.connect(function(name) {
	if (name == source) {
		source = firstSource();
		if (source) {
			npDataEngine.connect(source, plasmoid, 500);
		}
	}
});

npDataEngine.sourceAdded.connect(function(name) {
	if (!source) {
		source = name;
		npDataEngine.connect(source, plasmoid, 500);
	}
});

if (source) {
	npDataEngine.connectSource(source, plasmoid, 500);
}

Of course, it’s not much work to only show the things you’re interested in, but this covers the interesting parts of the plasmoid.

Interesting note: it appears that if you replace the line label.text = 'Info:\n'; with label.text = '';, the subsequent calls to label.text += ... don’t work – you just end up with a blank label.


Posted by randomguy3 on 2009-05-17T12:51:36Z

Answering the Eternal Question

Apparently, God is a monitor lizard.


Posted by randomguy3 on 2009-05-03T23:32:22Z