Skip to content

KDE Blogs 

Monday, 22 December 2003

Programming-by-contract in C-based languages

Tjansen  | 
I do not know much about Eiffel (and I can't stand its Pascal-like syntax...), but the Eiffel feature that I like is design by contract. Design by contract means that function interfaces, the APIs, are seen as a contract between the creator and the user. In most languages this contract is mostly written down in the documentation. Eiffel has them written in the source code. It is also possible to do this in a language like Java, but Java's syntax needs a small modification to make this really comfortable. Let's take this function as an example: Read More
Sunday, 21 December 2003

default settings

Aseigo  | 
in prep for 3.2, i've been looking at some of the default settings and fixing up some of the errant ones... like no desktop text shadows, or soft line wrap in kedit... lots of little fiddly stuff.. and working on fixes for editting bookmarks with the context menu (the dialog is a little lackluster) and for ensuring that important servicemenus like the mount options are in the top level and not buried in the Action submenu. Read More
Saturday, 20 December 2003

Resource management in garbage collecting languages

Tjansen  | 
One of my favorite C++ features is resource management with stack-allocated objects. It can hardly get more convenient than writing { QMutexLocker m(myMutex); } Read More
Friday, 19 December 2003

User Linux *sigh*

Aseigo  | 
Bruce took his reply to the KDE proposal off his website and replaced it with four short paragraphs that are much more to-the-point and not nearly as dubious as his original piece. The web is vastly impermanent, which can be good but is often unfortunate as we lose our history and context easily. in related news JDub has said written up in his blog (http://www.gnome.org/~jdub/blog/) how dissapointed he is in some of the KDE people for the trail of snipes that occured on the User Linux discuss list in the last few days; i agree with his sentiments but wonder why he felt the need to whine about it in his blog. (hey, how self-referential! look at me, i'm Kevin Smith.) if it wasn't for the fact that we're doing a lot of cool stuff (e.g. code and technical specs) on the kde-debian list, i'd be seriously in the dumps right now. oh well... Read More
Thursday, 18 December 2003

KJSEmbed is useful!

Geiseri  | 
Well up until now most KJSEmbed examples we have had seemed very contrived. This morning we got into a problem with building buttons for our web site. We decided it was not worth doing in PHP since the buttons never changed, but none of us had the talent to build them by hand. So enter "cvs:[kdebindings/kjsembed/docs/examples/buttonmaker/buttonmaker.js|ButtonMaker]" :) Read More
Thursday, 18 December 2003

Property syntax

Tjansen  | 
Today I realized that the property syntax of in all C-based languages sucks. Lets a assume a very simple class called 'SubString' that describes a fragment of a string and has two properties: its length and the index of the first character of the string. The class implementation has two field members, one containing the first character's index, and the other the index of the first character after the string. One problem is that there is no field member corresponding to the second property. This is what I call a virtual property. In this simple example there is no real reason for having a virtual property, but in reality this happens quite frequently when you want to expose a value of an aggregated object. Let's try to implement this in Qt/C++, Java and C#. Read More
Tuesday, 16 December 2003

Bruce Peren's "response"

Aseigo  | 
Here are the points in the order they were presented in Bruce Peren's reply to the KDE in User Linux proposal, along with my thoughts on them. It's All Emotional Bruce first tries to explain it away by saying, "it's simply unbearable for their personal GUI not to be the one chosen for our project", after making references to emotional investments. He's right in that people do care for and about that which they create. He's wrong in that the "emotional investment" is why many of us had issues with the choice to ban KDE/Qt from his project. Read More
Tuesday, 16 December 2003

Thought Experiment: XML integrated into a C-like language

Tjansen  | 
In recent days I made the following thought experiment: how can XML processing be made easier by integrating XML support into a Java/C#-like programming language. I created the code snippet below to try out what such a language could look like. The syntax of this theoretical language: Read More
Saturday, 13 December 2003

The Linux platform and modern GUI-based operating systems

Tjansen  | 
During the last years I encountered a number of problems in the Linux platform's architecture that cause problems for GUIs on top of it. When I say 'the Linux platform', I refer to the Linux kernel, glibc and the common GNU and Linux tools, but not X11. I also ignore distribution-specific solutions for the problems. In general the lack of a tool is not a real problem for me, it just is some work that needs to be done. I am talking about the architecture, problems that can not be solved without incompatibilities or at least a lot of work. A 'modern GUI-based OS' is, for me, a OS that does not require a user to know or use a command line tool, even for rare system-administration tasks. That does not mean that it should be impossible to work with the command line and a text editor, but the command line must not be the only way to do an administration task. So here is the (incomplete) list: Read More
Saturday, 13 December 2003

Things more important the usual competition...

Haven't said much in a while -- mostly because things have been really busy for me lately. But today something really got my attention and merited some thought. In the last couple of days Ettore Perazzoli a GNOME / Evolution / Ximian hacker type of guy died; it was one of those moments for me where reading about it all of the desktop flame wars seemed to pass into irrelevance. Read More