The ‘K’ Desktop Environment

From users to programmers, people everywhere have found that the 'K' Desktop Environment meets their need for user-friendly functionality.

The K Desktop Environment

Move over Windows98. There’s
a new Sheriff in town, and its
name is KDE. KDE is shorthand for “K Desktop Environment”. It is a project whose
goal is the creation of a complete Open Source desktop environment for UNIX-based
operating systems (like Linux). The ‘K’ in “KDE” doesn’t stand for anything, much
like the ‘X’ in “X Window System”. But what exactly is KDE, and what can it do
for you? Well, to some extent that depends on who you are and what you want to

If you are an end user, KDE provides you with a slew of applications and
configuration utilities that will help you to better use and administer your
computer. Among these are a file manager (similar to the Microsoft Windows file
manager) and an excellent online help system. This fills a tremendous need as
UNIX systems have often been criticized for having lousy help systems.

If you are a programmer, KDE provides an excellent set of programming
libraries, including one of the most full-featured Graphical User Interface (GUI)
toolkits available (The Qt Toolkit), and an Integrated Development Environment

The beauty of KDE is that all of these applications and tools for both users
and programmers are designed with a standard user interface, making them easier
to learn and use than traditional UNIX applications.

KDE was designed to be friendly and accessible to newbies (Windows users
should feel right at home with KDE), while also retaining all the power and
customization/flexibility that UNIX hackers have come to expect. This is possible
because the KDE libraries and desktop are built on top of the X Window System,
which is both extremely powerful and highly configurable. However, since X’s
tremendous flexibility comes with a great deal of complexity, the designers of
KDE sought to simplify and standardize the situation for both users and

The X Window System, the Linux kernel, and KDE all work together to create a
simple, powerful, highly configurable GUI. Most people who are used to Mac or
Windows based systems don’t really think about their computers as having separate
“operating systems” and “desktop environments” (or GUI), but they really are two
very separate things.

The way it works is fairly simple. KDE sits on top of both the X Window
System and the Linux kernel, and makes requests for services to both of them. The
user just interacts with KDE. For example, if KDE needs to draw something on the
screen, it talks to X. X then worries about talking to the computer’s hardware
and drawing windows on the screen. If a user interacts with a GUI program that
affects system resources (for example a network configuration utility), then KDE
talks to the Linux kernel and makes requests of the system based on the user’s
input. The user can simply interact with the KDE interface and let the computer
do the hard work.

Of course, if you want to make things more complicated, you can. You can
configure KDE however you want. If you know a great deal about how X works and
how window managers work and you want to configure KDE to use a non-default
window manager, you can use any one you prefer. The window manager (WM) is the
program that controls the placement of windows and other elements on the screen.
It is a separate program from X. X’s designers chose to separate the WM from X
itself to allow for maximum flexibility (and confusion). KDE comes with the KWM
(K Window Manager) installed by default, which interoperates seamlessly with the
rest of the ‘K’ environment. Any other WM will work with KDE, you just have to
alter a few configuration files. Part of what makes KDE so great is that new
users don’t need to know anything at all about this.

Before we explore all that KDE has to offer both users and programmers, let’s
take a look at how it came to be.


The KDE project emerged from
an idea posted to the Internet by
Matthias Ettrich in 1996 (Ettrich had previously authored LyX, a graphical
interface for the LaTeX typesetting engine). Because UNIX was primarily developed
by a community of technical users, its creators did not put much thought into
making it user-friendly. Ettrich sought to rectify this situation and to create a
free, easy to use graphical desktop system for UNIX-based operating systems. This
was to be aimed not just at developers, but also at new or less-experienced
users.Within months of the initial post, dozens of developers answered and the
KDE Project was born.

Every windowing system or GUI has a set of libraries or functions that draw
and create windows, menu bars, and other GUI items. This makes it so that
developers don’t need to re-invent the wheel every time they write an
application, and also so that programs written with a given toolkit have a
standard “look-and-feel”. These functions and libraries are often referred to as
a “widget toolkit”. Thus, one of the first decisions the KDE team had to make was
choosing an appropriate widget toolkit for development. The team debated writing
one from scratch, but eventually decided to use Troll Tech’s “Qt”. Qt is a
multi-platform toolkit that enables programmers to create applications for both
Microsoft Windows and the X Window System.

Qt was chosen primarily because it offered a high-quality interface, a well
thought-out API (Applications Programming Interface), and cross-platform support.
Also, by using Qt, the KDE team didn’t have to write a new toolkit. Finally, Qt
was extremely stable. There were no worries of improper widget functioning, and
the team was able to focus almost exclusively on designing KDE itself. There was
only one small problem with Qt which the KDE team considered negligible. Its
license did not completely adhere to “free software” political standards.
However, since the pros so far outweighed the cons of Qt, the team decided it was
an obvious choice.

The development of KDE moved quickly and the first fully-functional version
was made available in early 1997. By August 1997 a KDE developer’s conference –
“KDE ONE” — was held in Arnsberg, Germany.Soon after the conference, a series of
betas were released and on July 12, 1998, KDE version 1.0 was launched.
Development of the project is ongoing, and a KDE 2.0 release is expected by the
end of 1999.


It is clear that Qt is an excellent toolkit and
using it as the foundation for KDE has provided the team with great benefits.
However, when it comes to licensing, if you are a die-hard free software fanatic
and nothing less than the GNU General Public license (GPL) will satisfy you, then
Qt might be considered to have one small drawback. Its license gives developers
the option of making their source code proprietary if they purchase a commercial
license from Troll Tech. However, if developers want to write Open Source
Software (OSS) with Qt, they don’t need to purchase a license — they just need
to make their source code freely available.

Also according to Qt’s old licensing agreement, if a developer changed any of
the source code for Qt, he first had to submit the changes to Troll Tech and then
Troll Tech might incorporate those changes themselves — if they chose to.
Developers were not permitted, according to the agreement, to distribute (even
freely) a modified Qt. Troll Tech was the only entity empowered to do that.

Thus some of KDE’s licensing terms incurred the wrath of purists within the
Open Source community, who did not believe that software could be truly Open
Source if it was developed with a toolkit that was not completely open. From the
purist’s point of view, the problems were obvious. For one thing, if the KDE team
wanted to add a feature that required a modification of Qt’s code and Troll Tech
did not accept that modification, the feature could not be implemented. Moreover,
if developers found a security hole within Qt, they would first have to forward
their fixes to Troll Tech before those fixes could be implemented. Another
drawback of this semi-restrictive agreement is that if Troll Tech ever chose in
the future to cease making Qt’s source code freely available (due to a buy-out, a
merger, bankruptcy, or just because they wanted to), the KDE team could then no
longer distribute it freely with their software.

These potential problems led to the creation of the “KDE Free Qt Foundation”.
The board of the foundation is comprised of two KDE developers who are not
affiliated with Troll Tech and two Troll Tech developers. Its purpose is to
guarantee the availability of Qt for free software development. The foundation
essentially has decided that if Qt development stops, or if Troll Tech chooses to
no longer make Qt available for free software development, the latest version of
Qt will be released under a BSD-style license, which is a less restrictive
license than either the GPL or LGPL (The “Library” GPL — a less restrictive
GPL). The KDE team hopes that the foundation will allay the concerns of the Open
Source community regarding the team’s use of Qt. At the same time, the team is
currently working on the “Harmony Project”. The goal of this project is the
creation of a LGPL clone of the Qt toolkit.

Spending too much time dwelling on the licensing issues distracts one from
all that KDE has to offer, so perhaps it is time to find out what KDE is really
all about.


As we have seen,
KDE is a GUI environment that makes UNIX-based operating systems more viable for the ordinary
user. Based on a handful of common libraries, KDE offers a friendly appearance, a
full-featured desktop, and a wide variety of easy to use GUI-based system
configuration tools. The text file editing that has scared off many potential
UNIX users is soon to be a thing of the past.

KDE’s desktop functionality centers around three applications/tools:

The panel: This is located at the bottom of the screen and is used to start
applications and to switch between desktops. Among other things, it contains the
“Application Starter”, which is a large “K” icon that displays a menu of
applications when clicked (similar to the Window95′s “Start” menu).

The desktop itself: KDE provides multiple desktops (each with its own
windows) and clicking on the numbered buttons on the panel will switch to the
corresponding desktop. Like any good desktop environment, KDE allows users to
place files and folders on the desktop for easy access.

The taskbar: This is located at the upper-left corner of the screen and is
used to switch between and manage currently running applications.

Fortunately, KDE goes beyond simply providing a desktop environment; it also
offers users an integrated suite of GUI-based system configuration tools. A few
of the more significant tools are listed below.

KFM: The ‘K’ File Manager was designed to do more than just browse local
filesystems on your hard drive. It also allows users to browse remote FTP and
HTTP sites as though they were local as well. KFM is highly customizable and
ships with KDE 1.0. There is, however, a new file manager currently being
developed by the team for a later release named “Konqueror”. Konqueror is
designed to be even more flexible and faster than KFM, and should be available at
about the same time as KDE 2.0.

KWM: The ‘K’ Window Manager creates a modern GUI look-and-feel under UNIX
without the traditional configuration hassles. For example, KWM offers unique
window titles and icons, but the user does not need to mess with ugly text-based
resource files. Additionally, KWM can be configured at runtime without needing to
be restarted. “Session Management” is another feature of KWM. The WM remembers
the state of your desktop and applications between logins, or “sessions”.

KControl: This is KDE’s configuration center and represents an effort to
standardize the process of configuring applications under UNIX. Most KDE-aware
applications can be configured through KControl, and it is the framework upon
which many administrative tools for UNIX are being built. Unlike the older method
for administering UNIX, where each task required a separate tool, KControl
simplifies matters by providing a unified interface.

KDE Screenshot 1
Move over Microsoft: Here comes the new KOffice.

KOffice: This is a full featured KDE office suite that provides users with an
integrated spreadsheet (KSpread), word processor (KWord),formula editor
(KFormula), chart and diagram program (KDiagram), image viewer (KIimage), drawing
program (KIllustrator), and presentation program (KPresentor).

KDE also comes with numerous editors and viewers, games (KDE has excellent
multimedia support), and Internet and networking support. For example, the KDE
team knew that one of the most frustrating experiences for new users was getting
their Linux box onto the Internet. So they developed “kppp”, which is a graphical
utility that makes it easy even for newbies to set up a PPP connection to their
Internet Service Provider (ISP).


Being programmers themselves, the KDE team was well aware that they needed to
create a development platform that was robust enough to entice other developers
to put their efforts into the KDE project. So they have tried to make software
development easier by offering programmers a large number of pre-built resources
including libraries, an integrated development environment, and a standard
inter-application communication system. Some of the more useful software
development tools offered by KDE include the following:

KDE Screenshot 2
Good IDE-a: The IDE that comes with KDE makes Windows programmers

KDevelop UNIX programmers no longer have to envy their Windows counterparts
for their easy-to-use GUI programming tools. With KDevelop, KDE programmers now
have their own IDE that they can use to make the Windows guys jealous. It even
has a wizard-based project builder.

KDE SDK: The KDE Software Development Kit is still only alpha quality code
and is very immature. Among the utilities it contains is a program called “KDoc”,
which creates standard documentation for KDE’s class libraries. There are also
SGML tools with KDE extensions that can be used to create professional
documentation for KDE applications.

KDE Dialog Definition Language (KDDL): Missing from UNIX has been the RAD
(Rapid Application Development) tools that are available under Windows. Some of
those RAD-like tools are now beginning to appear. The KDDL is an HTML-style
dialog definition language that allows for very rapid development and testing of
dialog boxes.


Early in the development of KDE, the team recognized that the X Window System
had fallen behind the Microsoft Windows world with regard to object-oriented
programming technologies. Using easy to learn languages such as Visual Basic,
users with a minimal programming background could glue separate software
“objects” or “components” together with ease to create new applications that
exhibited previously unavailable functionality. In fact, a whole cottage industry
has grown up around Microsoft’s “Active X” component technology.

It’s not that UNIX didn’t have excellent infrastructure for implementing an
object system — it did. CORBA (the Common Object Request Broker Architecture)
implementations were available for UNIX. CORBA is an industry-wide open standard
that specifies the requirements for building an “Object Request Broker” or ORB.
An ORB is a piece of software that takes requests from different pieces of
software and passes these requests along to other pieces of software that know
how to properly respond. Thus, as long as any software object can speak to the
ORB, it can by default speak to all other objects that speak to the ORB. This
environment greatly increases software re-useability and flexibility.

Unfortunately, certain keystones of GUI programming such as support for
“named events” and “function callbacks” were not a part of the CORBA standard,
and no one had yet extended the CORBA system to make it suitable for use in a GUI
programming environment. So the KDE team decided to develop the “KDE Object
Model” or KOM to add the missing functionality to CORBA. Because CORBA is not
really a piece of software, but is rather a specification for how to write a
specific piece of software, the team needed to decide whether they were going to
build on an existing CORBA implementation or write their own. They decided to
build on an existing one and chose MICO (which stands for MICO Is CORBA — it’s
another recursive acronym) for its flexibility, speed, and clean

The KDE Object Model was, therefore, developed to add functionality to CORBA
by making it possible for named events to be passed between elements of an
application, between applications in a system, and between networked systems. KOM
also offers event filtering mechanisms, an essential part of the model in that
they allow software objects to decide which events concern them and which they
can ignore.

All of this functionality was added to CORBA by using a “signals and slots”
based mechanism very similar to the model that already existed in Qt. The signals
and slots model is a powerful idea that makes GUI programming much simpler. It
works as follows: An object (say, an on-screen window) will have a “slot” for a
particular event (such as a mouse click). When the appropriate “signal” (the
mouse click) is received by that slot, a function will be called on the object
(highlight text, for example). Until that signal is received, the object ignores
all other signals.

KOM was developed in such a way that it is independent of any GUI code. This
allows non-GUI applications to use KOM’s functionality, without burdening
themselves with extra and unnecessary code. This also meant that to fully
integrate KOM into KDE, another layer had to be built on top of KOM. The
“OpenParts” layer adds KOM functionality to GUI-based KDE applications.


OpenParts essentially allows different graphical elements (called “parts”) to
be embedded into each other. The top level part is called the “part shell”.
OpenParts arbitrates access to restricted interface resources (such as menubars
and toolbars) inside the partshell.

For, example, if a KSpread part were embedded in a KWord part, the menubar
can only reflect one of the applications at a time. The user lets OpenParts know
which application should be active by clicking on the appropriate section of the
document. OpenParts then turns over control of the menubar to the active


It is our hope that we have inspired you to give KDE a try. You can download
the latest version from http://www.kde.org/mirrors.html or from
ftp://ftp.kde.org/pub/kde/stable/latest/distribution. Installation instructions can be found at http://www.kde.org. There is also a FAQ there that can provide you with useful
information if you get stuck.

Robert Williams and Christian Tibirina are members of the KDE team. Robert
can be reached at kwilliams@jrc-utah. com. Christian can be reached at

Comments are closed.