Debconf 2015 – 7

The other day, the main talk was “Lets encrypt”, today it was “Let’s reproduce”

Posted in debian, english

Debconf 2015 – 6

There is more people with blue hair at Debconf than at an average Akademy. KDE – we need to do better :)

Posted in debian, english, kde

Debconf 2015 – 5

Watching people figuring out how to use a Danish cheese slicer is kind interesting. But by using enough force most people succeeding in getting a lump of cheese.

Posted in debian, english

Debconf 2015 – 4

“I refuse to be bound by software I cannot negotiate with” — enrico

Posted in debian, english

Debconf 2015 – 3

It is still an open question what the Debian Project Leader wears under their kilt.

Posted in debian, english

Debconf 2015 – 2

It is amazing at debconf when your Application Manager is rocking the dance floor!

Posted in debian, english

Debconf 2015 – 1

When greeted by Clint with one single word: “kamelåså“, one has arrived to Debconf.

Posted in debian, english

Getting a Q_INVOKABLE C++ function reevaluated by QML engine

Unfortunately, with all the normal magic of QML property bindings, getting a property updated in a setup that involves return values from functions isn’t really doable, like this:

Text {
text: qtobject.calculatedValue()
}

I’m told there is a low priority feature request for a way of signalling that a function now returns a different value and all properties using it should be reevaluated.

I have so far discovered two different workarounds for that that I will be presenting here.

Using an extra property

Appending an extra property to trigger the reevaluation of the function is one way of doing it.

Text {
text: qtobject.calculatedValue() + qtobject.emptyNotifierThing
}

with the following on the C++ side:

Q_PROPERTY(QString emptyNotifierThing READ emptyString NOTIFY valueChanged)
QString emptyString() const {
return QString();
}

This is a bit more code to write and to remember to use, but it does get the job done.

Intermediate layer
Another way is to inject an intermediate layer, an extra object, that has the function. It can even be simplified by having a pointer to itself.

Text {
text: qtobject.dataAccess.calculatedValue()
}

with the following on the C++ side:

Q_PROPERTY(QObject* dataAccess READ dataAccess NOTIFY valueChanged)
QObject* dataAccess() {
return this;
}

It seems a bit simpler for the reader on the QML side, but also gets the job done.

I am not sure which way is the best one, but the intermediate layer has a nicer feeling to it when more complicated types are involved.

Posted in english, kde, qt

QImage and QPixmap in a Qt Quick item

For reasons I don’t know, apparantly a Qt Quick Item that can show a QImage or a QPixmap is kind of missing. The current Image QML item only works with data that can be represented by a URL.

So I wrote one that kind of works. Comments most welcome.

It is found on git.kde.org: http://quickgit.kde.org/?p=scratch/sune/imageitem.git

Oh, and the KDE End of Year fundraiser is still running. https://www.kde.org/fundraisers/yearend2014/. Go support it if you haven’t already.

Posted in english, kde, qt

Is linux about choice?

Occasionally, various quotes from people having an opinion if linux is about choice or not. Even pages like http://www.islinuxaboutchoice.com/ has shown up.

My short answer is “YES”. Linux is about choice. And you get all your choices directly from your f/loss definition of choice (FSF’s 4 freedoms / OSI’s opensource definition / Debian Free Software Guidelines)

It doesn’t mean that you get all the gui configuration bits that you want. It doesn’t mean that you without any problems can switch out any component. But it does mean that you can get it exactly your way. But it might require you to edit some source code and compile some stuff.

Posted in debian, english, kde