Skip navigation.
KDE Developer's Journals

Java

dipesh's picture

State of Kross in KDE4

Kross, the scripting framework, is one of the pillars new with KDE4. While the project started already a while back in 2004 it enveloped over the time to a rather big codebase. During the KDE4-process one of the main-goals was to decrease the codebase what can be even more difficult then writting new code.

krake's picture

Other integration fronts: GNU Classpath

Over on Planet Classpath the people blog about the ongoing
efforts and success with their Qt based AWT peers.

Nice to see that the high quality of Qt's code on all its platforms get more widespread acknowledgement outside the KDE area.

zander's picture

GUI Libraries

My first project in KDE was maintaining KOffice. This was years ago already. Later I was forced to use Java at work and have been doing that for some 6 years now. I recently left that job, but I still have a nice chunk of work from that job available as an open source project I started and worked on during that time together with some colleagues and volunteers.

This open source project is adding to Java/Swing all the nice things I was used to having in KDE. Think i18n and signal/slots and xmlgui as well as things like a GroupBox or colorbutton class.
I really tried to make it a marriage of technologies; best of both worlds.

Last Monday I did a 2.0 release of the collection of tools/framewords. This was more to fix the API then anything else since there were occasional bugfixes but no major changes for some time. Call it a signal to say we find it stable.
I'm quite surprised that in 5 days we already have over 250 downloads. This software may be more popular then I thought Smiling

So, what is this blog doing on kdedevelopers.org?
Well, I'm mostly pretty proud of a mature and really well received piece of work. But there are lots of ideas in there that KDE would be able to learn from. I did not just rewrite KDE technologies there, but also reused Java technologies and ideas from even other places.
For example; the recent collapsible groupbox addition from Danimo has been in there for some time now, including animating collapse:


(and 1 2 3 4)

Other ideas are the tooltip placement on a kSqueezedTextLabel so the text on the tooltip is exactly in the same spot as the text on the label. All the way up-to making signal/slots multithreading with various ExecutePolicies. A really powerfull concept unique to the User Interface Collection (http://uic.sf.net).

For me the parser that reads QtDesigner files and outputs Java code still has meaning even if I don't really program Java Swing that often anymore. The outputter can be retrofitted to output Java code for the KDE-qt bindings for Java quite easilly overcoming one big stumbling block for Java programmers that want to use KDE.

zander's picture

Switching focus

Over the last weeks I have been spending time on KDEPim and KMail in particular. Various usability and feedback issues have been fixed that bothered me before and I find KMail to be a lot more pleasant to use, fixing bugs beats working around them any day!

I have been struck with the complexity of C++ and moc and all that. Steep leurning curve! It took me hours to implement something that I would have done in 15 minutes in Java. It turned out i hit various bugs in GCC and limitations of what moc can do. Whats more is that I wanted to shift focus again, so I created an applet for our worldwide.kde.org website since that has been growing and usability has gone down at the same time.
Worldwide.kde.org has so many names up that it becomes useless without a zoom function in most of europe, but also outside. So I made a zoom function.

I downloaded the huge nasa BlueMarble image of earth (21600 pixels horizontal) and wrote an applet that ships with a 600x300 jpeg and allows you to zoom in on it all the way up to the full res image which means you still have a nice picture at 200x zoom.
I found it quite funny that 2 days after I finished this applet google came out with their new google.earth. Well, mine actually runs on all platforms, not just Windows.

Next I got the coordinates and names as used on Worldwide from Rainer Endres, who maintains the Worldwide database. So I wrote a parser and renderer for that data. Which was the easy part. Then I spent about a whole day writing and tweaking a placement algorithm so names don't overlap and make things unreadable. I think I succeeded quite nicely there Smiling

After some more bugs are squashed expect it to be shown on Worldwide, as Rainer liked this addition. For now, here is a screenshot:

and for the impatient; here is a jar you can start using 'java -jar': worldwide.jar

zander's picture

ReportWriter

At the last aKademy the openusability website was demonstrated with the idea that usability experts (mostly people that do this for a living) will describe problems in open source projects with suggestions on how to fix them.
Sounds great! There was one thing I found less then great; those poor usability experts had to write their report in an XML to make the website understand.

Now; I always think that XML is a great format as long as you have a nice GUI app that will generate it for you so in August I immidiately started sketching a GUI to enter that info.

manyoso's picture

Solaris, Java and the CDDL

By now everyone has heard of Sun's foray into Open Source Solaris. Groklaw has an interesting run down of the incompatibilities between the CDDL and the GPL. I find the whole thing tremendously interesting, but when you really think about it and the possible implications for Linux, it is not all that exciting. Sure, Solaris 10 is a hell of an operating system by most accounts, but at this point I think of it like the hoopla that surrounded Apple's release of Darwin. That too, was one hell of an operating system, with all of the doomsayers heralding it as the end of Linux... Well, a few years later not so much. Heh.

john ratke's picture

Checking out the Competition

Since I am somewhat new to C# and .net I decided to follow up on a
thread I had read on Joel On Software about the new Microsoft Visual
Studio Express
product
line which is targeted at enthusiasts and hobbyists. So I went, and
sure enough, Visual C# Express Beta was a free download, and only 50mb.
Note that they require that you give them a valid email address, and
also, from what I've read, the evaulation expires next year.

tjansen's picture

Concept for a hybrid static-/dynamically typed language

I am watching the static vs dynamic typing wars with some curiosity. On the one hand, I can't
understand how to write any large application without the help of static typing. The lack of information
in the code, especially the imprecise and fuzzy specification of APIs, reduces the confidence
that my code will work in all situations. It also does not fit my usual coding style for large
programs and applications: I tend code for days, weeks or even months until I have a usable state,
without executing the code even once. I RELY on the compiler's ability to find all typos during that time.


On the other hand, I see that there are many people who prefer dynamic languages. Most of them have
a write-a-little/test-a-little style, which I know from writing JSPs, so I can understand the style
at least somewhat.

tjansen's picture

Playing with the Switch and Foreach Statements

I've been thinking about C's control statements (if, while, switch, for etc) for a little while, and I think there's some room for improvements in the later two...

tjansen's picture

Argument Constraints in the Function Declaration

The most annoying thing when writing public APIs is that it's a lot of redundant typing. A good API implementation should check all arguments and return a useful error message if an argument is invalid. Good API documentation should document which arguments values are valid and which return values are possible. Both tasks are work-intensive and annoying for the developer, which is probably one of the reasons why there so many bad APIs.

Syndicate content