cat /dev/maxilys

A glance in the mind of a KDE/Linux developer to see how ideas turn into code.

2006-03-26

KDE: Reaching the limits

That's it, I reached the limits of what I can do. There are widgets that just can't be styled. For example, the ugly misnamed QDial. You probably haven't ever seen this circular widget with a rotative hand like an analogic cynemometer --the round thing where you can see your speed on a car board. A quick look in Qt sources shows us no call to style().something(with a lot of parameters). No styling. Period. That's one thing. There is also this KKeyButton for which I have no idea if it's just possible to style it.

And finally, I found what was the widget used as window titlebar for a floating toolbar. It's just CC_TitleBar. I've already finished working on it. It now looks like a little more like the titlebar of a regular window --except a little smaller.

But I wasn't able to do all I had I mind. I reproduced the look... but I wanted more! I also wanted to reorder the buttons. And this part led me to troubles. 'ld' reported an error when I tried to use what a window decoration uses to know the order of the buttons. My googling session was unproductive. I was looking for something vague with generic solutions in which I could pick up some inspiration. I could find the exact text of the the error reported by 'ld' but it only applied to specific situations (this app or this lib, in this environment). I watched two dozens of pages before to give up.

Any way, I managed to get the buttons of the titlebar to react to mouseclick but not to mouseover. Qt sources talk about it but it's not clear at first sight when and why it applies. On the other hand, the titlebar changes of color when the pseudo-window is raised. Nice. :-)

The only thing that doesn't satisfy me right now is the icons on the buttons. I let KDE do the drawing and the color isn't right. I haven't done the new package so maybe I'll take the time to draw my own icons --to satisfy my hunger for control. ;-)

After that, I'm gonna do some new snapshots with the improved colorschemes and the new window titlebars. Serenity-decoration-0.4 has been waiting its release for a week at least. It's high time to give a new Serenity to the world. ;-)

0 Comments:

Post a Comment

<< Home