Category Archives: planetkde - Page 2

KDEPIM report

This week I focused my work on Akregator.


  • I fixed some errors on signal/slots
  • I reimplemented TextToSpeech support
  • I replaced QList to QVector where it was possible
  • I added some QStringLiteral
  • I used new Qt5 connect Api
  • I fixed some bugs.
  • I added support for share url (it allows to share url in Facebook/Twitter etc.)

Others work in KDEPIM:

  • I implemented ShareUrl, I use it in kmail/akregator
  • I fixed some bugs in Dav resource (thanks to Bruno Friedmann to provide me an access to an owncloud server). It was mainly GUI bugs.
  • I fixed some crashes in Accountwizard
  • KMail uses KPIM::CompletionConfigureDialog to configure addressline settings (it avoids 3 different dialogbox).
  • I added bookmarks support in Sieveeditor
  • I added spellchecking support in plaintexteditor.
  • I fixed application translations


Next week I will focus on the KAddressbook.

I hope that I will have more bug report about it.

Other Info:

Dan works on akonadi to replace protocol based on text to use a binary protocol directly.

He saw a lot of improvement. He hopes to merge it in master soon.

To conclude:

We are in good way to have a stable version for 15.08.

I was not sure some about it some weeks ago 🙂

KDEPIM KF5 status and test plan


As you know we decided to release kdepim kf5 in 15.08. (We have 2 months yet).

I use kdepim kf5 by default now on my main computer. Of course when I started to use it all apps crashed, or there was some part of code which was not ported to kf5 yet.

I tried to fix all crash that I found, I fixed a lot of bugs, and I finished some features (as Gravatar support, rewrite the kmail composer, reimplement text to speech etc.)

Now all applications work fine (no direct crash when I launch them). But of course it’s not perfect. I can’t use all application all the time. So I need some help to find bugs.

Test plan:

There is a lot of application in kdepim:

  • KMail
  • KAddressBook
  • KNotes
  • Kontact
  • KOrganizer
  • SieveEditor
  • AccountWizard
  • ImportWizard
  • etc. (Some others minor applications)

So I decided to focus each week on an application.

I will not work at 100% on a specific application, but I will use it a lot during this period and I will try to fix each bug that I will find.

As I worked a lot on KMail, I will not focus on it next week.

I will focus on Akregator, so if you can test it and you can report me bugs. I will not fix all bugs about akregator but I will try to for all porting bugs. I don’t have time to debug all akregator bugs 😉

How to test it ?

It’s better to use last version from git because I fix a lot of bugs each week. (I don’t know if distro provides snapshots).

I will increase version of kdepim each week so we will be sure that bug is against last version.


KDEPIM uses a lot of resource as Dav, Openxchange, etc. I don’t have access to them. So I can’t debug so it will good if some people will able to test them.

Thanks for your help.



I started porting of kdepim to KF5 1 year ago (in may 2014). When I started it I thought that it should be easy. But it was not easy because firstly KF5 was not release and it was not stable, there was some bugs. Secondary kdepim is not just KMail, it contains the kdepim libs + akonadi + kdepim runtime + kdepim apps (as korganizer, kmail, etc.).

The first step was to adapt cmake files to new framework environment.

I removed some applications which were not ported to pure kde4 (depended to kde3support), or some unmaintained applications (as ktimertracker) etc.

The second step was to split kdepimlibs as frameworks (for the moment just one lib is released).

The last step was removing kdelibs4support (it’s still in progress). This step is very long because we need to port each kdepimlibs library (The big problem is the KLocale porting… It’s complicated and there is not Howto for it…).


Last week I decided to use kdepim kf5 as default on my computer.

It was not an easy decision because I use KMail for my work.

But before to do it, I implemented a class for migrating data applications, because now we use XDG path and not .kde path for config/apps data etc. as it was in kde4

First impression:

I am impressed because KMail works fine 🙂 I can send/receive emails !

KAddressBook was totally broken but I fixed it last week end.

KOrganizer worked correctly.

SieveEditor works very fine.

For other applications they are working fine but I didn’t have time to evaluate them correctly.

Dead line:

We decided to release kdepim with kf5-15.08, so in 2 months.

Is it possible to do it ?

I hope 🙂 But it will hard to fix all bugs without some helps.

kdepim-4.14 ?

I never stopped to work on kdepim-4.14, but indeed now that I switch to kf5 I will reduce the time that I took to debug it.

But I will continue to backport the fixes on kdepim-4.14 until we release kf5, because I am not sure at 100% that new version will kf5 version.


I will continue to debug all applications, I will finish some new features until we release it.

How to help ?

Just take an application, use it as usual and report all bugs that you find.

kdebugsettings 1.0

Before to increase version to 1.0 I moved it from kdereview to kdeutils.

I added new features of course 🙂

Now you can import/export settings directly.

You can create a category file and it will load in kdebugsettings.

It’s very useful for big project as kdepim for example when I add a new logging categories for each module, but I don’t want to wait a new release.

So you need to create a “.categories” file and install it as “install( FILES kdepim.categories DESTINATION ${KDE_INSTALL_CONFDIR} )”


No idea 🙂 If you have so wishlist send me a bug 🙂

Embedded QML in qrc file

KDAB works on a lot of projects based on qml.
But sometime for specific applications it’s not safe to store directly qml file on file system.
As you know the QML files are plain text files.

For example if an user can have access to qml files he can change the logic of the application.
This is not critical for a application as  “Clock” but it can be critical in other domains.

So there is two methods to avoid it:

  • Using the Qt Resource for embedding the QML files (This blog will explain how to do).
  • Using the qtquickcompiler to generate a precompiled QML file (But a commercial license is needed)

The Qt Resource system allows to store a lot of data/binary files in executable directly.
Data can be an icon, a translation file, etc. and of course a QML file.

This blog will explain how to use it in a QML plugins implemented based on a QMLExtensionPlugins class.

For a standard application which uses some QML files this is very easy. We put them in a qrc file and we can access to it directly with a line as “view.setSource(QUrl(QStringLiteral(“qrc:/plugins.qml”)));”

We will see how to do it on a example based on qmlextensionplugins.

We adapted a qt qmlextensionplugins example (It’s the Clock example that you can find in qt source code) to create an little application.
Source code can be download here

It will display a clock.
The pro files were adapted to allow to install apps in “install” directory.
(qmake && make && make install).

When you look at install folder you can see all these files.


=> As you see the QML files are stored on filesystem.

Now what we need to change for using Qt Resource ?

We will create a Qt Resouce file which will embed all qml files and icons.

<qresource prefix=”/clock”>

There is not a specific prefix.
And you just need to adapt qmldir for using a specific QtResource path (use qrc:///<path>)

module TimeExample
Clock 1.0 qrc:///clock/Clock.qml
plugin qmlqtimeexampleplugin

Of course the file qmldir can’t be stored in Qt Resource file otherwise  the application will not be able to  find plugin.

As you see now the list of files in install directory is limited to:


(of course I stored plugins.qml in another qrc file).

So the application is more safe now.

You can get source code here

KDebugSettings (0.3)

I improved kdebugsettings (and increased version to 0.3).

What’s new:

  • I added an Apply button so now we can test rules directly
  • We can customize kdeapplication rules, before we could just enable/disable them, now you can specify that you want to show just Debug/Critical/All (as for custom rules)
  • There is a new tab which shows rules which are stored in QT_LOGGING_RULES environment variable.
  • I added a warning when a rules starts by “*” which can override all others rules.
  • I added an Help button which show Qt qloggingcategory page


I will add a button to export/import rules.

I will ask to move it in kdereview. I think that it can move in official package.


Warning about "*" rules

Customize kdeapplication rules

Customize rule



Some weeks ago I spoke with David how to configure what debug to show in qt5 (now it uses qloggingcategory)

In kde4 time we had kdebugdialog. It allowed us to define some debug areas.

But we are not able to extend it because it was in kdelibs4support module and it was kdebug specific.

Qt5 doesn’t provide application to do it.


So I decided to create a new application named “kdebugsettings” (c) David 🙂

This application worked as old kdebugdialog, we have a file which defines categories.

This file is named kde.categories.

I added debug area that I found in source code. More areas will add in the future.

It will allow to generate qCDebug rule.

In kdebugsettings we have 2 tabs, one for kde applications which are defined in kde.categories and another one which allows to define custom rules (if you want to show warning/debug/all, enable/disable it).

Where to find it ?

It is stored in, in playground/util module.

You can test it and report bug/feature etc.


I hope for 15.08 to release it.


Last week I decided to evaluate “Ninja”.

What is it ?

It’s a build system developed by Chrome for Chrome. Evan Martin Developed it during his work.

He wanted to create a fast build system. It was a success 🙂

How to use it ?

Easy you need to create a file named which defines all dependancy as a Makefile.

But it’s not a problem because CMake is able to generate it for you.

So for KDE it’s not a problem as we use CMake to generate projects.

So now the command line:

“cmake -GNinja ../”

Too bad we can’t override default cmake generator. So I created a alias on my computer to avoid to write each time a big command line:

Add “alias cmninja=’cmake -GNinja'” in .alias

After that you call it you will have a “” in build directory.

Now for launching the build it it’s very easy: write “ninja”

make <-> Ninja commands:

Ninja has same commands as Make.

make clean <-> ninja -t clean
make -j8   <-> ninja -j8
make install <-> ninja install
make -k <-> ninja -k[X] (it will stop after X failed)

Pro/Cons ?


  • Faster as Make when we build from scratch
  • Less verbose as make
  • Very fast when we build and there is no files which changed (the time can be divided by 3 some time). So very fast when we rebuild all kde 🙂
  • Ninja will detect the amount of CPUs and use them all. (Not necessary to use ninja -j<X>)


  • We don’t have color output.
  • We can’t build in subdirectory. For example if I build kdepim and I hack kmail, I can go to kmail subdirectory. I very bad for it.
  • qmake doesn’t generate so we can’t use in qmake project.

Can I use in kdesrc-build?

Yes you can ! I use it.

Correction: We can use it in top-level.

This morning I fixed kf5-frameworks-build-include which forced build system.

So now you can add “custom-build-command ninja” in global settings of kdesrc-buildrc

cmake-options -GNinja -DCMAKE_BUILD_TYPE:STRING=debug -DKDE4_BUILD_TESTS=true

(just adds “-GNinja” to your current cmake-options)

So how I use it?

I use it for building all plasma5/kf5, it’s very fast to build. So I am happy.

For kdepim I still use make as I want to build in subdirectory.

More information:

You can have more information here:

KDEGames kf5

In December I blogged about porting of kdegames to kf5.

My objective was to release some games for the ‘15.04’.

So I worked harder to make it possible.

You can see status here :

So the plan now is to merge some application in master.

This WE we will merge libkdegames and the game names Bovo.

After that we will merge some applications when it’s possible (A game mustn’t have kdelibs4support, must have migration settings done, etc.) each 3 days until 15.04 freeze (in 4 weeks).

So we need YOU !

We need some testers to help us to make as bug free as possible.

kdepim 4.14 + unittest

As you saw I continue to work on 4.14 branch, in parallel I work on KF5 porting.

Why do I continue to work on 4.14 ?

Because KF5 kdepim version will not arrive before that AkonadiNext will be stable, so it will take time. AkonadiNext is writing from scratch.

I don’t know if you remember but during porting to akonadi, kdepim 4.4 was not improving during 2 years, no bug fixing, nothing. It was a very bad idea.

So I decided to continue to fix 4.14, until we release KF5.

What do I do in 4.14 ?

I continue to fix bug. And there is still a lot of bugs 🙂

I try to make it stable.

During this period I try to write a lot of unit-test on this branch.

Why do I write unit test ?

Because there is not unit test on kdepim 🙂 It’s a good reason.

But there is a second reason, as I port kdepim to KF5 and it’s not stable to use it, I can’t know if all works fine. So I create unit test, I verify that it works on 4.14 and after that I just need to run unit test on KF5 to be sure that it works fine on KF5 too.

What do I do when I add a new feature in KF5 ?

Now each new feature that I add, or feature will add in kdepim will have a unit test.

So in KMail or in each lib/apps that I maintain in kdepim, I will not accept new feature if there is not unit-test, because it’s very useful and I don’t want to write them after 🙂

It’s a pain when we need to write unit test on a code that we didn’t write.

And sometime code is not adapted to create unit test so it’s necessary to rewrite it. (I rewrote some code in 4.14 to allow to create some unit test).

It’s more easy to create unit test when we write feature that write them after.