<?xml version="1.0"?>
<?xml-stylesheet type="text/css" href="http://techbase.kde.org/skins/common/feed.css?0.2"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
		<id>http://techbase.kde.org/api.php?action=feedcontributions&amp;user=DrSlowDecay&amp;feedformat=atom</id>
		<title>KDE TechBase - User contributions [en]</title>
		<link rel="self" type="application/atom+xml" href="http://techbase.kde.org/api.php?action=feedcontributions&amp;user=DrSlowDecay&amp;feedformat=atom"/>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Special:Contributions/DrSlowDecay"/>
		<updated>2013-05-24T17:01:01Z</updated>
		<subtitle>User contributions</subtitle>
		<generator>MediaWiki 1.20.2</generator>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-12-28T20:09:16Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Beliebte Fehler */  partly translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Die Grundlagen von apidox sind einfach und machen Spaß: Man schreibt einfach Kommentare in den Code, die erklären wofür dieser ist. Diese Kommetare sind fast das gleiche wie das, was man sowieso in die header des Codes schreiben muß, so ist das ganze also nicht so schwer. &lt;br /&gt;
&lt;br /&gt;
APIDOX werden in speziellen Kommentaren geschrieben. Diese Kommentare starten mit /** (Schrägstrich, Stern, Stern) -- und das ist es, was sie besonders macht. Der Rest des Kommentars ist einfacher Text, der den Teil des Programms beschreibt. Dieser Text wird vom Doxygen Prozessor interpretiert, damit dadurch passende Beschreibungen der Parameter und Rückgabewerte erfolgen kann. Doch die Dokumentation ist recht unkompliziert: Man schreibt einfach, was eine Methode tut innerhalb von /** und */, so wie folgendes Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für eine vernünftige apidox muß jedes &amp;quot;Ding&amp;quot; des Programms dokumentiert werden. &amp;quot;Dinge&amp;quot; sind hierbei Verzeichnisse, Dateien, Namensräume, Klassen, Methoden, Aufzählungen und Variablen. Man kann eventuell Dateien und Verzeichnisse auslassen und sich nur auf die letzteren Punkte konzentrieren. Komplette apidox sehen ungefähr so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wie man sieht, ist jede Schachtelungsebene der eben erwähnten &amp;quot;Dinge&amp;quot; mit einem Kommentar versehen -- Der Namensraum, die Klasse und die Methode. Private &amp;quot;Dinge&amp;quot; benötigen keine apidox, protected &amp;quot;Dinge&amp;quot; jedoch schon.  &lt;br /&gt;
&lt;br /&gt;
Es ist wichtig, jede einzelne Schachtelungsebene zu dokumentieren, denn läßt man einen Ebene aus, ignoriert Doxygen die inneren ebenso und man findet diese nicht mehr wieder. Angenommen man würde im obigen Beispiel die Klassendokumentation weglassen, dann würde die Dokumentation für die Methode Socket() ebenfalls verschwinden. Das ist eine der typischen Fallen beim Schreiben von apidox.  &lt;br /&gt;
&lt;br /&gt;
Und wenn man nur eine Erklärung für jeden Teil seines Programmes schreibt, hat man schon einen großen Teil des Weges zu einer kompletten apidox hinter sich gelassen. Diese Erklärungen zu schreiben macht das Programm einfacher für andere Entwickler zu verstehen und zeigt einem oft schon sub-optimale Designs oder Namenswahlen. Auf diese Art gewinnen beide Seiten.  &lt;br /&gt;
&lt;br /&gt;
Man findet in der Liste von unterstützen Tags auch Beispiele für ausgefallenere apidox -- Erklärung von Parametern oder wie man die apidox mit Beispielen und Personendaten versieht. Es lohnt sich auch nachzusehen, wie man apidox aktiviert, doch es ist auch möglich die Arbeit aufzuteilen: Du schreibst die apidox selber und fragst den Originalautor (mailto:groot@kde.org), diese für dein Modul zu aktivieren. Er verspricht (zunmindest in der englischsprachigen Originalversion) das dann zu tun.  &lt;br /&gt;
 &lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
Wenn mann neuen Code schreibt und dabei apidox verwenden möchte, sollte man am besten KDevelop benutzen. Vernünftig konfiguriert kann dieses automatisch ein Grundgerüst für apidox einfügen, man muß dann nur noch die eigentlichen Beschreibungen einfügen. Und man muß sich nicht mehr mit apidox kommandos rumärgern. &lt;br /&gt;
&lt;br /&gt;
Wenn man sich nicht in dieser günstigen Lage befindet, sollte die folgende Checkliste einen durch die schlimmsten Untiefen beim Schreiben von apidox führen:&lt;br /&gt;
&lt;br /&gt;
'''1. Schreibe die apidox direkt mit dem Code zusammen'''&lt;br /&gt;
&lt;br /&gt;
Wenn man es mit etwas Disziplin schafft, direkt beim Schreiben einer Funktion foo(), wo man sich sowieso Gedanken über den gewünschten Effekt machen muss, auch gleich an die apidox zu denken, spart man sich diese Zeit sicherlich später, wenn man nicht mehr mühsam herausfinden muss, was die Funktion foo() eigentlich machen soll. &lt;br /&gt;
&lt;br /&gt;
Das heißt nicht, dass man es auf diese Art und Weise machen muss, doch es bietet sich an. Durch die apidox werden auch Entscheidungen bezüglich des Designs dokumentiert. Auch wird dokumentiert, was ein bestimmter Codeabschnitt eigentlich macht, unabhängig davon, was er aktuell tut. Das macht es möglich, unabhängig zu überprüfen, ob der Code das tut, wozu er geschrieben ist. Das liegt daran, dass es bereits in der apidox dokumentiert wurde. &lt;br /&gt;
&lt;br /&gt;
'''2. Dokumentierte deine Header vollständig'''&lt;br /&gt;
&lt;br /&gt;
Die Header sind das, was den Benutzern als erstes vom Code ins Auge springt (in diesem Zusammenhang sind Entwickler Benutzer, die Code wiederverwenden). Aus diesem Grund sollen sie vollständig sein, d.h. jede noch so kleine Struktur sollte im Header dokumentiert werden. Im Einzelnen:&lt;br /&gt;
&lt;br /&gt;
*Jede Datei sollte einen Kommentar haben, der den Nutzen dieser Datei beschreibt. Das wird von den KDE Richtlinien sowieso vorgeschrieben -- am Anfang der Datei sollte einfach vermerkt werden, wofür die Datei gut ist und in groben Zügen, was sie definiert. Das sollte in einem /** @file */ Kommentar erfolgen.&lt;br /&gt;
* Jeder Namensraum (namespace) sollte einen Kommentar haben. Ein bestimmter Namensraum benötigt nur einmal im Quellcodebaum einen Kommentar, doch es kann nicht schaden ihn bei jedem Auftreten erneut zu beschreiben -- nur kurz sollte es sein. Diese Kommentare sind einfache apidox Kommentare zwischen /** und */; keine besonderen Befehle wie bei Dateien das @file Befehl.&amp;lt;br&amp;gt;&lt;br /&gt;
Man sollte nur sicherstellen, dass der Kommentar direkt vor dem Namensraum steht und nichts dazwischen steht. Das folgende Beispiel zeigt, wie es aussehen soll:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:Im nächsten Beispiel hat jemand etwas Extracode zwischen den apidox Kommentar und den Namensraum, der dokumentiert werden soll, gebracht. Das könnte Doxygen zu Fehlern bringen (in diesem Fall ist es einfach den Fehler zu finden) oder die Dokumentation des Namensraum kann sich plötzlich auf etwas ganz anderes beziehen (dann ist der Fehler schwer zu finden).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
Dieser Abschnitt listet einige beliebte Fehler auf, die einem beim Schreiben der Apidox unterlaufen können. Typischerweise sind das leicht zu übersehende Fehler, die seltsame Fehlermeldungen produzieren, aber auch ein paar stilistische Fehler die vermieden werden sollten, werden angesprochen.&lt;br /&gt;
&lt;br /&gt;
'''Fehlende APIDOX''': Man ''weiß'', dass man die dox für die Klasse &amp;quot;Moose&amp;quot; geschrieben hat, doch nach der Generierung ist sie nicht sichtbar. Man ''weiß'' auch, dass eine auf Dateiebene sichtbare Funktion int foo() dokumentiert wurde, doch die ist auch nicht da. Was geht hier vor?&lt;br /&gt;
&lt;br /&gt;
Der häufigste Fehler, der zu &amp;quot;fehlender&amp;quot; apidox führt ist, zu vergessen, die umgebenden Strukturen zu dokumentieren. Die &amp;quot;Struktur&amp;quot; im Quellcode kommt von den Dateien, den Namensräumen, Klassen und Methoden. Um also eine Klasse zu dokumentieren muss man den Namensraum dokumentieren, in dem sie sich befinden (sofern es einen gibt) und die Datei in dem sie sich befindet. Um eine Methode zu dokumentieren, muss man die Klasse dokumentieren, in dem sie sich befindet (und so wiederum den Namensraum und die Datei). So die einfachste Daumenregel ist es, einfach ''alles'' zu dokumentieren. &lt;br /&gt;
&lt;br /&gt;
{{note (de)|Diese Regel ist nicht ganz richtig: Klassen benötigen nicht, dass die Datei dokumentiert wird, in der sie sich befinden, aus diesem Grund kann man den /** @file */ Kommentar auslassen für Dateien, die nur Klassen und Namensräume beinhalten.&lt;br /&gt;
Beachte das Klassen in einem Namensraum erfordern, dass der Namensraum dokumentiert wird, doch Klassen im :: Namensraum benötigen keine Extradokumentation. &lt;br /&gt;
Etwas unklar ist das bei anonymen Namensräumen.&lt;br /&gt;
&lt;br /&gt;
Für Funktionen in der Dateiebene, also Funktionen, die in einer Datei definiert werden und nicht in einem Namensraum oder einer Klasse ''muß'' die Datei, in der sie definiert ist, dokumentiert werden. Das gilt meistens für Dateien die eine Sammlung von nicht-Methoden Funktionen zur Verfügung stellen.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': Diese Markierung zeigte Binärkompatibilität an, ähnlich wie es ''@since'' tut. Das Argument hinter ''@bc'' zeigt den Bereich der Binärkompatibilität (zum Beispiel KDE4) an. Klassen, die nicht mit ''@bc'' markiert sind, können in einigen Modulen als inkompatibel markiert werden, damit sie vermieden werden.&lt;br /&gt;
&lt;br /&gt;
Beispiel:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Diese Markierung zeigt an, welche Bibliotheken mit einer bestimmten Klasse gelinkt werden sollen. Auch wenn es normalerweise der Name des Verzeichnisses ist, in dem sich die Klasse befinden, ist dies nicht immer der Fall.&lt;br /&gt;
&lt;br /&gt;
Beispiel:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
Es kann nützlich sein, Beispielcode zur APIDOX einer Klasse hinzuzufügen. Sehr nützlich ist es auf jeden Fall für Leser, die sich fragen, wie man eine Klasse genau zu benutzen hat. Die meisten Klassen in {{path|kdelibs/kdecore}} haben Beispielcode.&lt;br /&gt;
&lt;br /&gt;
Ein Weg, um Beispielcode zu schreiben ist es, @code und @endcode um den Block des Beispielcodes in den Doxygenkommentaren selber zu legen, wie im folgenden Beispiel:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Auf diese Art wird es in den meisten Beispielen in {{path|kdelibs}} gemacht. Das funktioniert auch ganz gut, man kann sich bei den Beispielen aufs wesentliche beschränken.&lt;br /&gt;
&lt;br /&gt;
Ein wichtiges Problem dieser Herangehensweise um Beispielcode zu schreiben ist es, dass der Code niemals geprüft wird, ob er wirklich funktioniert. Die meisten Codebeispiele sind so gepackt, dass es schwer ist, diese in einen funktionsfähigen Code umzuschreiben, der wirklich kompiliert und läuft.&lt;br /&gt;
&lt;br /&gt;
Um dieses Problem zu lösen, kann man ''richtigen Code'' schreiben, der wirklich kompiliert (als Teil dr Test-Suite für den Code, den man sowieso hat) und exakt beschreibt, wie eine Klasse in einem richtigen Programm benutzt werden soll. Man muß jedoch nicht den gesamten Code in die APIDOX übernehmen, sondern braucht nur die interessanten Teile zu markieren. Um das zu bewerkstelligen, wird eine Datei in das &amp;lt;tt&amp;gt;tests&amp;lt;/tt&amp;gt; Unterverzeichnis eingefügt. Dann kann man das Doxygen @include-Tag benutzen, um den Code dieser Datei in die API Dokumentation zu übernehmen.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-30T15:38:40Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* KDE spezifische Tags */ translated that part&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Die Grundlagen von apidox sind einfach und machen Spaß: Man schreibt einfach Kommentare in den Code, die erklären wofür dieser ist. Diese Kommetare sind fast das gleiche wie das, was man sowieso in die header des Codes schreiben muß, so ist das ganze also nicht so schwer. &lt;br /&gt;
&lt;br /&gt;
APIDOX werden in speziellen Kommentaren geschrieben. Diese Kommentare starten mit /** (Schrägstrich, Stern, Stern) -- und das ist es, was sie besonders macht. Der Rest des Kommentars ist einfacher Text, der den Teil des Programms beschreibt. Dieser Text wird vom Doxygen Prozessor interpretiert, damit dadurch passende Beschreibungen der Parameter und Rückgabewerte erfolgen kann. Doch die Dokumentation ist recht unkompliziert: Man schreibt einfach, was eine Methode tut innerhalb von /** und */, so wie folgendes Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für eine vernünftige apidox muß jedes &amp;quot;Ding&amp;quot; des Programms dokumentiert werden. &amp;quot;Dinge&amp;quot; sind hierbei Verzeichnisse, Dateien, Namensräume, Klassen, Methoden, Aufzählungen und Variablen. Man kann eventuell Dateien und Verzeichnisse auslassen und sich nur auf die letzteren Punkte konzentrieren. Komplette apidox sehen ungefähr so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wie man sieht, ist jede Schachtelungsebene der eben erwähnten &amp;quot;Dinge&amp;quot; mit einem Kommentar versehen -- Der Namensraum, die Klasse und die Methode. Private &amp;quot;Dinge&amp;quot; benötigen keine apidox, protected &amp;quot;Dinge&amp;quot; jedoch schon.  &lt;br /&gt;
&lt;br /&gt;
Es ist wichtig, jede einzelne Schachtelungsebene zu dokumentieren, denn läßt man einen Ebene aus, ignoriert Doxygen die inneren ebenso und man findet diese nicht mehr wieder. Angenommen man würde im obigen Beispiel die Klassendokumentation weglassen, dann würde die Dokumentation für die Methode Socket() ebenfalls verschwinden. Das ist eine der typischen Fallen beim Schreiben von apidox.  &lt;br /&gt;
&lt;br /&gt;
Und wenn man nur eine Erklärung für jeden Teil seines Programmes schreibt, hat man schon einen großen Teil des Weges zu einer kompletten apidox hinter sich gelassen. Diese Erklärungen zu schreiben macht das Programm einfacher für andere Entwickler zu verstehen und zeigt einem oft schon sub-optimale Designs oder Namenswahlen. Auf diese Art gewinnen beide Seiten.  &lt;br /&gt;
&lt;br /&gt;
Man findet in der Liste von unterstützen Tags auch Beispiele für ausgefallenere apidox -- Erklärung von Parametern oder wie man die apidox mit Beispielen und Personendaten versieht. Es lohnt sich auch nachzusehen, wie man apidox aktiviert, doch es ist auch möglich die Arbeit aufzuteilen: Du schreibst die apidox selber und fragst den Originalautor (mailto:groot@kde.org), diese für dein Modul zu aktivieren. Er verspricht (zunmindest in der englischsprachigen Originalversion) das dann zu tun.  &lt;br /&gt;
 &lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
Wenn mann neuen Code schreibt und dabei apidox verwenden möchte, sollte man am besten KDevelop benutzen. Vernünftig konfiguriert kann dieses automatisch ein Grundgerüst für apidox einfügen, man muß dann nur noch die eigentlichen Beschreibungen einfügen. Und man muß sich nicht mehr mit apidox kommandos rumärgern. &lt;br /&gt;
&lt;br /&gt;
Wenn man sich nicht in dieser günstigen Lage befindet, sollte die folgende Checkliste einen durch die schlimmsten Untiefen beim Schreiben von apidox führen:&lt;br /&gt;
&lt;br /&gt;
'''1. Schreibe die apidox direkt mit dem Code zusammen'''&lt;br /&gt;
&lt;br /&gt;
Wenn man es mit etwas Disziplin schafft, direkt beim Schreiben einer Funktion foo(), wo man sich sowieso Gedanken über den gewünschten Effekt machen muss, auch gleich an die apidox zu denken, spart man sich diese Zeit sicherlich später, wenn man nicht mehr mühsam herausfinden muss, was die Funktion foo() eigentlich machen soll. &lt;br /&gt;
&lt;br /&gt;
Das heißt nicht, dass man es auf diese Art und Weise machen muss, doch es bietet sich an. Durch die apidox werden auch Entscheidungen bezüglich des Designs dokumentiert. Auch wird dokumentiert, was ein bestimmter Codeabschnitt eigentlich macht, unabhängig davon, was er aktuell tut. Das macht es möglich, unabhängig zu überprüfen, ob der Code das tut, wozu er geschrieben ist. Das liegt daran, dass es bereits in der apidox dokumentiert wurde. &lt;br /&gt;
&lt;br /&gt;
'''2. Dokumentierte deine Header vollständig'''&lt;br /&gt;
&lt;br /&gt;
Die Header sind das, was den Benutzern als erstes vom Code ins Auge springt (in diesem Zusammenhang sind Entwickler Benutzer, die Code wiederverwenden). Aus diesem Grund sollen sie vollständig sein, d.h. jede noch so kleine Struktur sollte im Header dokumentiert werden. Im Einzelnen:&lt;br /&gt;
&lt;br /&gt;
*Jede Datei sollte einen Kommentar haben, der den Nutzen dieser Datei beschreibt. Das wird von den KDE Richtlinien sowieso vorgeschrieben -- am Anfang der Datei sollte einfach vermerkt werden, wofür die Datei gut ist und in groben Zügen, was sie definiert. Das sollte in einem /** @file */ Kommentar erfolgen.&lt;br /&gt;
* Jeder Namensraum (namespace) sollte einen Kommentar haben. Ein bestimmter Namensraum benötigt nur einmal im Quellcodebaum einen Kommentar, doch es kann nicht schaden ihn bei jedem Auftreten erneut zu beschreiben -- nur kurz sollte es sein. Diese Kommentare sind einfache apidox Kommentare zwischen /** und */; keine besonderen Befehle wie bei Dateien das @file Befehl.&amp;lt;br&amp;gt;&lt;br /&gt;
Man sollte nur sicherstellen, dass der Kommentar direkt vor dem Namensraum steht und nichts dazwischen steht. Das folgende Beispiel zeigt, wie es aussehen soll:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:Im nächsten Beispiel hat jemand etwas Extracode zwischen den apidox Kommentar und den Namensraum, der dokumentiert werden soll, gebracht. Das könnte Doxygen zu Fehlern bringen (in diesem Fall ist es einfach den Fehler zu finden) oder die Dokumentation des Namensraum kann sich plötzlich auf etwas ganz anderes beziehen (dann ist der Fehler schwer zu finden).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': Diese Markierung zeigte Binärkompatibilität an, ähnlich wie es ''@since'' tut. Das Argument hinter ''@bc'' zeigt den Bereich der Binärkompatibilität (zum Beispiel KDE4) an. Klassen, die nicht mit ''@bc'' markiert sind, können in einigen Modulen als inkompatibel markiert werden, damit sie vermieden werden.&lt;br /&gt;
&lt;br /&gt;
Beispiel:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Diese Markierung zeigt an, welche Bibliotheken mit einer bestimmten Klasse gelinkt werden sollen. Auch wenn es normalerweise der Name des Verzeichnisses ist, in dem sich die Klasse befinden, ist dies nicht immer der Fall.&lt;br /&gt;
&lt;br /&gt;
Beispiel:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
Es kann nützlich sein, Beispielcode zur APIDOX einer Klasse hinzuzufügen. Sehr nützlich ist es auf jeden Fall für Leser, die sich fragen, wie man eine Klasse genau zu benutzen hat. Die meisten Klassen in {{path|kdelibs/kdecore}} haben Beispielcode.&lt;br /&gt;
&lt;br /&gt;
Ein Weg, um Beispielcode zu schreiben ist es, @code und @endcode um den Block des Beispielcodes in den Doxygenkommentaren selber zu legen, wie im folgenden Beispiel:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Auf diese Art wird es in den meisten Beispielen in {{path|kdelibs}} gemacht. Das funktioniert auch ganz gut, man kann sich bei den Beispielen aufs wesentliche beschränken.&lt;br /&gt;
&lt;br /&gt;
Ein wichtiges Problem dieser Herangehensweise um Beispielcode zu schreiben ist es, dass der Code niemals geprüft wird, ob er wirklich funktioniert. Die meisten Codebeispiele sind so gepackt, dass es schwer ist, diese in einen funktionsfähigen Code umzuschreiben, der wirklich kompiliert und läuft.&lt;br /&gt;
&lt;br /&gt;
Um dieses Problem zu lösen, kann man ''richtigen Code'' schreiben, der wirklich kompiliert (als Teil dr Test-Suite für den Code, den man sowieso hat) und exakt beschreibt, wie eine Klasse in einem richtigen Programm benutzt werden soll. Man muß jedoch nicht den gesamten Code in die APIDOX übernehmen, sondern braucht nur die interessanten Teile zu markieren. Um das zu bewerkstelligen, wird eine Datei in das &amp;lt;tt&amp;gt;tests&amp;lt;/tt&amp;gt; Unterverzeichnis eingefügt. Dann kann man das Doxygen @include-Tag benutzen, um den Code dieser Datei in die API Dokumentation zu übernehmen.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Sensors</id>
		<title>Development/Tutorials/Sensors</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Sensors"/>
				<updated>2008-11-30T14:25:32Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Sensors}}&lt;br /&gt;
&lt;br /&gt;
Implementing KSysGuard sensors simple example.&lt;br /&gt;
&lt;br /&gt;
Prerequisities: KDE, Perl.&lt;br /&gt;
&lt;br /&gt;
Imagine you have a program that monitors some value important for you.&lt;br /&gt;
You want the value to be plotted or displayed in the KDE systray.&lt;br /&gt;
&lt;br /&gt;
The most straightforward way is to add it to KSysGuard as a sensor.&lt;br /&gt;
&lt;br /&gt;
== Example ==&lt;br /&gt;
&lt;br /&gt;
Step 1. Create, for example, &amp;quot;/home/vi/code/sensor/sensor.pl&amp;quot; with the following content:&lt;br /&gt;
&amp;lt;code lang=&amp;quot;perl&amp;quot;&amp;gt;#!/usr/bin/perl -w  &lt;br /&gt;
$|=1;&lt;br /&gt;
&lt;br /&gt;
print &amp;quot;ksysguardd 1.2.0\n&amp;quot;;&lt;br /&gt;
print &amp;quot;ksysguardd&amp;gt; &amp;quot;;&lt;br /&gt;
&lt;br /&gt;
while(&amp;lt;&amp;gt;){&lt;br /&gt;
    if(/monitors/){&lt;br /&gt;
	print &amp;quot;random\tinteger\n&amp;quot;;&lt;br /&gt;
    }&lt;br /&gt;
    if(/random/){&lt;br /&gt;
	if(/\?/){&lt;br /&gt;
	    print &amp;quot;Random Value\t0\t100\n&amp;quot;;&lt;br /&gt;
	}else{&lt;br /&gt;
	    print int(rand()*100),&amp;quot;\n&amp;quot;;&lt;br /&gt;
	}&lt;br /&gt;
    }&lt;br /&gt;
    print &amp;quot;ksysguardd&amp;gt; &amp;quot;;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Step 2: Launch KSysGuard, File-&amp;gt;Connect Host-&amp;gt;Custom Command, enter &amp;quot;/home/vi/code/sensor/sensor.pl&amp;quot; in the Command field, OK.&lt;br /&gt;
&lt;br /&gt;
Step 3: Open &amp;quot;127.0.0.1&amp;quot;, find &amp;quot;random   Integer Value&amp;quot;, drag it to some sheet.&lt;br /&gt;
&lt;br /&gt;
You will see your sensor (random value from 0 to 100 in this case).&lt;br /&gt;
&lt;br /&gt;
== Systray ==&lt;br /&gt;
&lt;br /&gt;
If you want to see the plot is your systray, follow this:&lt;br /&gt;
&lt;br /&gt;
Step 1: Add &amp;quot;KSysGuard applet to the desktop&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Step 2: In there's no spare displays, choose &amp;quot;Configure System Guard&amp;quot; in the context menu of the applet and increase &amp;quot;Number of displays&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Step 3: Launch KSysGuard, follow previous example to get access to your sensor.&lt;br /&gt;
&lt;br /&gt;
Step 4: Drag and drop from &amp;quot;random Integer Value&amp;quot; to the free display in the systray.&lt;br /&gt;
&lt;br /&gt;
Step 5: &amp;quot;Signal plotter&amp;quot;, then you will be asked again to provide the data source. Choose &amp;quot;Custom Command&amp;quot; with the same script.&lt;br /&gt;
&lt;br /&gt;
[Step 6: Open properties and remove grids and lines to clean up the plot]&lt;br /&gt;
&lt;br /&gt;
== Protocol ==&lt;br /&gt;
&lt;br /&gt;
The ksysguardd protocol:&lt;br /&gt;
1. Server sends version line (&amp;quot;ksysguardd 1.2.0&amp;quot;) ended with newline.&lt;br /&gt;
2. Server sends &amp;quot;ksysguardd&amp;gt; &amp;quot; with spacebar and without newline.&lt;br /&gt;
Available commands:&lt;br /&gt;
   monitors -- List available sensors&lt;br /&gt;
   &amp;lt;sensor name&amp;gt; -- Get the value of some sensor&lt;br /&gt;
   &amp;lt;sensor name&amp;gt;? -- Get the metadata of the sensor&lt;br /&gt;
&lt;br /&gt;
&amp;quot;monitor&amp;quot; command:&lt;br /&gt;
For each sensor, send the sensor name TAB the sensor type (integer) NEWLINE.&lt;br /&gt;
Then go back to the prompt &amp;quot;ksysguardd&amp;gt; &amp;quot;.&lt;br /&gt;
&lt;br /&gt;
get command:&lt;br /&gt;
For integer sensors, server should send one integer value and NEWLINE.&lt;br /&gt;
&lt;br /&gt;
info command:&lt;br /&gt;
Server should send the Display Name of the sensor TAB minimum value TAB maximum value TAB units NEWLINE. Looks like this command or some part of it is optional.&lt;br /&gt;
&lt;br /&gt;
== Example session ==&lt;br /&gt;
&lt;br /&gt;
Example of session:&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
ksysguardd 1.2.0&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
96&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
46&lt;br /&gt;
ksysguardd&amp;gt; monitors&lt;br /&gt;
random.integer&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
11&lt;br /&gt;
ksysguardd&amp;gt; random?&lt;br /&gt;
Random Value.0.100&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
47&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
54&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
5&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
37&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
41&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
58&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
36&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
69&lt;br /&gt;
ksysguardd&amp;gt; random&lt;br /&gt;
83&lt;br /&gt;
ksysguardd&amp;gt; &lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/KPixmapCache</id>
		<title>Development/Tutorials/KPixmapCache</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/KPixmapCache"/>
				<updated>2008-11-30T14:22:45Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/KPixmapCache}}&lt;br /&gt;
== Introduction ==&lt;br /&gt;
{{class|KPixmapCache}} provides disk-caching of QPixmaps. If you're using SVGs or generating pixmaps from some data, you might consider using it as it eliminates the need to generate the same pixmaps over and over again.&lt;br /&gt;
&lt;br /&gt;
== Using it ==&lt;br /&gt;
=== Creating the cache object ===&lt;br /&gt;
It's API is similar to that of the QPixmapCache.&lt;br /&gt;
To use it, you first need to create the cache object, using a unique name:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
KPixmapCache* cache = new KPixmapCache(&amp;quot;myapp-images&amp;quot;);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Inserting and finding pixmaps ===&lt;br /&gt;
Once that is done you can easily retrieve and insert images with insert() and find() methods:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QPixmap pix(&amp;quot;file1.png&amp;quot;);&lt;br /&gt;
cache-&amp;gt;insert(&amp;quot;file1.png&amp;quot;, pix);&lt;br /&gt;
&lt;br /&gt;
QPixmap pix2;&lt;br /&gt;
if (cache-&amp;gt;find(&amp;quot;file2.png&amp;quot;, pix2)) {&lt;br /&gt;
    // The pixmap was loaded from cache.&lt;br /&gt;
} else {&lt;br /&gt;
    // Pixmap was not found in the cache.&lt;br /&gt;
    // Load and insert it:&lt;br /&gt;
    pix2 = QPixmap(&amp;quot;file2.png&amp;quot;);&lt;br /&gt;
    cache-&amp;gt;insert(&amp;quot;file2.png&amp;quot;, pix2);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== The Easy Way ===&lt;br /&gt;
As loading pixmaps from files with the aid of cache is a very common operation, KPixmapCache provides a convenience method for that:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString filename(&amp;quot;myfile.png&amp;quot;);&lt;br /&gt;
QPixmap pix = cache-&amp;gt;loadFromFile(filename);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
This first checks if the given file is in the cache. If it is, it's loaded from the cache, otherwise it's loaded from the file and inserted into cache.&lt;br /&gt;
&lt;br /&gt;
Similar method is provided for loading SVG files:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString filename(&amp;quot;myfile.svg&amp;quot;);&lt;br /&gt;
QPixmap pix = cache-&amp;gt;loadFromSVG(filename);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
This renders contents of the SVG file onto pixmap, using SVG's default size by default. If you need a different size, you can specify it as the second argument of that method:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString filename(&amp;quot;myfile.svg&amp;quot;);&lt;br /&gt;
QSize size(150, 250);&lt;br /&gt;
QPixmap pix = cache-&amp;gt;loadFromSVG(filename, size);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
This renders the SVG onto a pixmap with the size of 150x250 pixels.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Timestamps ===&lt;br /&gt;
Often you need to make sure the cache is up-to-date and you're not using obsolete pixmaps. For this, the cache provides timestamp() method. By default it returns time when the cache was created, but you can set your own timestamp with setTimestamp() method.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
// Our data&lt;br /&gt;
MyDataObject data;&lt;br /&gt;
// Make sure the cache is up to date&lt;br /&gt;
if (cache-&amp;gt;timestamp() &amp;lt; data.timestamp()) {&lt;br /&gt;
    // Data is newer than the cache&lt;br /&gt;
    // Thus the cache is obsolete, delete and reinitialize it&lt;br /&gt;
    cache-&amp;gt;discard();&lt;br /&gt;
}&lt;br /&gt;
// Here the cache is always recent enough&lt;br /&gt;
QPixmap visualizedData;&lt;br /&gt;
QString key(&amp;quot;data-visualization&amp;quot;);&lt;br /&gt;
// Try to find the visualization from the cache&lt;br /&gt;
if (!cache-&amp;gt;find(key, visualizedData)) {&lt;br /&gt;
    // Visualization is not in the cache, recreate it...&lt;br /&gt;
    visualizedData = createVisualization(data);&lt;br /&gt;
    // ...and put the resulting image into cache&lt;br /&gt;
    cache-&amp;gt;insert(key, visualizedData);&lt;br /&gt;
}&lt;br /&gt;
// Show the visualizedData pixmap to user&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
This example creates a visual representation of some data. If the data is more recent than the cache, then contents of the cache are deleted using the discard() method. Next, we check if cache already contains the necessary pixmap. If it does, then there is no need to recreate it from the data (which might be expensive).&lt;br /&gt;
&lt;br /&gt;
=== API docs ===&lt;br /&gt;
For a list of all KPixmapCache methods, check out its [http://api.kde.org/classmapper.php?class=KPixmapCache&amp;amp;module=kdelibs&amp;amp;version=4.0 API docs].&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Build/KDE4.x</id>
		<title>Getting Started/Build/KDE4.x</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Build/KDE4.x"/>
				<updated>2008-11-30T14:19:56Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting_Started/Build/KDE4.x}}&lt;br /&gt;
&lt;br /&gt;
==Objectives==&lt;br /&gt;
&lt;br /&gt;
You probably want to keep your current KDE-3.5.x installation till you feel that KDE-4.x.y meets your needs for actual day to day use of your computer.  Yet, you want to be able to change over with a minimum of work when the time comes to make the switch.&lt;br /&gt;
&lt;br /&gt;
==Method==&lt;br /&gt;
&lt;br /&gt;
The best way to accomplish this is to install the needed support libraries on your system in the usual manner.  Convention is that these should be installed in the /usr/local/ directory.  By default, Troll Tech installs Qt in: /usr/local/Trolltech/Qt-4/.  It is best to install KDE-4.x.y in its own directory so that the directory can be deleted if some large problem occurs.  I will be using /usr/local/KDE-4/ but you can call it whatever you want.&lt;br /&gt;
&lt;br /&gt;
We will keep configurations straight by using a separate user account for accessing KDE-4.x.y.  This user account will contain your configurations of KDE-4.x.y and will have a script to set the environment variables (.bash_profile if using Linux).&lt;br /&gt;
&lt;br /&gt;
==Installation==&lt;br /&gt;
&lt;br /&gt;
=== Required packages from your distribution===&lt;br /&gt;
* [[Getting_Started/Build/KDE4/LFS|Linux from Scratch]] or to build from source.&lt;br /&gt;
&lt;br /&gt;
(Till other distro instructions are added, you can probably determine the correct version to install by reading the LFS list of libraries)&lt;br /&gt;
&lt;br /&gt;
'''DO NOT build the Strigi version for KDE4 TRUNK''' for KDE-4.1&lt;br /&gt;
&lt;br /&gt;
If you have trouble building 4.1.1 or 4.1 BRANCH &amp;gt;= r852727, use the Strigi-0.5.10 release or, if using SVN, make certain that the revision number for the Strigi-0.5 BRANCH is &amp;gt;= 854542&lt;br /&gt;
&lt;br /&gt;
'''DO NOT build the versions for KDE4 TRUNK''' for KDE-4.0&lt;br /&gt;
 &lt;br /&gt;
KDE-4.0: You need to have the correct versions for: Qt, Soprano, &amp;amp; QImageBlitz.&lt;br /&gt;
&lt;br /&gt;
===Create the User Account===&lt;br /&gt;
&lt;br /&gt;
Use whatever method you wish to create a new user account.  Mine is called: &amp;quot;KDE4&amp;quot;.  Then edit or create the user specific login script (.bash_profile for Linux).  There is a lot that goes into this.  Note that this presumes that USER was correctly set by the system login script.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
:&amp;lt;nowiki&amp;gt;#&amp;lt;/nowiki&amp;gt; Redundant setting of HOME as work around for Bash bug&lt;br /&gt;
&lt;br /&gt;
:HOME=/home/KDE4&lt;br /&gt;
:PATH=$HOME/bin:&amp;lt;nowiki&amp;gt;$&amp;lt;/nowiki&amp;gt;PATH &lt;br /&gt;
:export PATH HOME&lt;br /&gt;
&lt;br /&gt;
:XDG_DATA_HOME=&amp;quot;$HOME/.local/share&amp;quot;&lt;br /&gt;
:XDG_CONFIG_HOME=&amp;quot;$HOME/.config&amp;quot;&lt;br /&gt;
:export XDG_DATA_HOME XDG_CONFIG_HOME&lt;br /&gt;
&lt;br /&gt;
:KDEDIR=/usr/local/KDE-4&lt;br /&gt;
:KDEHOME=$HOME/.kde4&lt;br /&gt;
:KDETMP=/tmp/$USER-kde4&lt;br /&gt;
:mkdir -p $KDETMP&lt;br /&gt;
:KDEVARTMP=/var/tmp/$USER-kde4&lt;br /&gt;
:mkdir -p $KDEVARTMP&lt;br /&gt;
:KDEDIRS=$KDEDIR&lt;br /&gt;
:PKG_CONFIG_PATH=/usr/local/KDE-4/lib/pkgconfig:$PKG_CONFIG_PATH&lt;br /&gt;
:export KDEDIR KDEHOME KDETMP KDEVARTMP KDEDIRS PKG_CONFIG_PATH&lt;br /&gt;
&lt;br /&gt;
:QTDIR=/usr/local/Trolltech/Qt-4&lt;br /&gt;
:QT_PLUGIN_PATH=$KDEDIR/lib/kde4/plugins:$QT_PLUGIN_PATH&lt;br /&gt;
:PKG_CONFIG_PATH=$QTDIR/lib/pkgconfig:$PKG_CONFIG_PATH&lt;br /&gt;
:export QTDIR QT_PLUGIN_PATH PKG_CONFIG_PATH&lt;br /&gt;
&lt;br /&gt;
:PATH=$QTDIR/bin:$KDEDIR/bin:$PATH&lt;br /&gt;
:export PATH&lt;br /&gt;
&lt;br /&gt;
:XDG_CONFIG_DIRS=/usr/local/KDE-4/etc/xdg&lt;br /&gt;
:XDG_DATA_DIRS=$KDEDIR/share&lt;br /&gt;
&lt;br /&gt;
:export XDG_CONFIG_DIRS XDG_DATA_DIRS&lt;br /&gt;
&lt;br /&gt;
:LD_LIBRARY_PATH=$QTDIR/lib:$KDEDIR/lib&lt;br /&gt;
:export LD_LIBRARY_PATH&lt;br /&gt;
&lt;br /&gt;
:LIBXCB_ALLOW_SLOPPY_LOCK=&amp;quot;true&amp;quot;&lt;br /&gt;
:export LIBXCB_ALLOW_SLOPPY_LOCK&lt;br /&gt;
&lt;br /&gt;
&amp;lt;nowiki&amp;gt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------8&amp;lt;------&amp;lt;/nowiki&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is in addition to other things that you need in the script which would probably go at the beginning -- this large block of junk is to be added at the end.  The XDG directories might need to be modified for your system.&lt;br /&gt;
&lt;br /&gt;
===Build===&lt;br /&gt;
&lt;br /&gt;
To build, you must be logged on as the new user account (KDE4).  You can 'su' for the whole thing or 'su -C' for each install.&lt;br /&gt;
&lt;br /&gt;
Packages need to be installed with the correct prefixes for this to work:&lt;br /&gt;
&lt;br /&gt;
:If you are building Qt from source, configure it with with --prefix=/usr/local/Trolltech/Qt-4.  If you installed it from a binary, determine the prefix and change: QTDIR in the script above.&lt;br /&gt;
&lt;br /&gt;
:KDE should use: -DCMAKE_INSTALL_PREFIX=/usr/local/KDE-4 when running cmake.&lt;br /&gt;
&lt;br /&gt;
:KDE Support should installed in the same directory as KDE.  This also applies to some of the packages if you are installing the individual packages/modules for a release or BRANCH.  For packages that don't use CMake that would be: --prefix=/usr/local/KDE-4.  The packages that don't install anything in &amp;quot;share&amp;quot; (eigen,eigen2) can be installed in &amp;quot;/usr/local/&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
:Other packages should be installed with the default prefix (/usr/local).&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-11-30T10:25:15Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: finished translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; Hauptunterverzeichnis ist dasjenige, in dem die Hauptentwicklung an KDE stattfindet. Was Sie hier finden, wird als nächstes als KDE und assoziierte Programme veröffentlicht. Hier finden Sie auch das &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; Modul, welches die Webpages rund um KDE beinhaltet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; ist unterteilt in folgende Unterverzeichnisse:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE selber, welches die nächste Veröffentlichung werden wird. Es besteht aus folgenden Modulen:&lt;br /&gt;
**'''kdelibs''' - KDE Hauptbibliotheken, die von allen KDE Programmen benutzt werden&lt;br /&gt;
**'''kdebase''' - KDE Basisprogramme, wie das KDE Control Center, Plasma (die Oberfläche) und Konqueror (der Web Browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility Dateien&lt;br /&gt;
**'''kdeadmin''' - KDE Administrationsprogramme&lt;br /&gt;
**'''kdeartwork''' - Bilder, Themen, Sounds und andere künstlerische Dateien&lt;br /&gt;
**'''kdebindings''' - Bindungen für andere Sprache außer C++&lt;br /&gt;
**'''kdeedu''' - Erzieherische und Wissenschaftliche Programme für KDE&lt;br /&gt;
**'''kdegames''' - KDE Spiele&lt;br /&gt;
**'''kdegraphics''' - KDE Graphikapplicationen&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimediaapplicationen&lt;br /&gt;
**'''kdenetwork''' - KDE Netzwerkapplicationen&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management Applicationen &lt;br /&gt;
**'''kdepimlibs''' - Biblotheken, die von KDE-PIM Applicationen benötigt werden.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit Applicationen&lt;br /&gt;
**'''kdetoys''' - KDE Spielzeug Applicationen&lt;br /&gt;
**'''kdeutils''' - Allgemeine KDE Werkzeuge&lt;br /&gt;
**'''kdevelop''' - Das KDevelop Programm&lt;br /&gt;
**'''kdevplatform''' - Die Entwicklerplatform auf der KDevelop basiert&lt;br /&gt;
**'''kdewebdev''' - Eine KDE Webentwicklungsapplikation&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Allgemeines admin/ Verzeichnis&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] Dateien&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der Inhalt von developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE Programme die sich außerhalb der Haupt KDE Veröffentlichungen aufhalten&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Vorübergehende Heimat für all die KDE Applikationen, von denen geglaubt wird, daß sie reif für eine Veröffentlichung sind. Von hier aus werden die Applikationen entweder nach &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; oder nach &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt; verschoben, sobald die größten Probleme ausgeräumt sind.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Unterstützende Programme und Bibliotheken für KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;Das KDE Office Paket, welches folgende Programme beinhaltet:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, das KDE build Programm&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für die &amp;quot;unstabilen&amp;quot; Module von KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der KDE Spielplatz: Applications die gerade entwickelt werden aber noch keine Veröffentlichungsqualität erreicht haben.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Zu Vereinfachung eine Kopie von  [http://www.trolltech.com/ Trolltechs] Qt Bibliothek, auf welcher KDE basiert.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice und ksvg Testfälle&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Die Valgrind Application, welche im KDE Repository betreut wird jedoch kein Teil von KDE selber ist. Neuere Versionen von Valgrind werden in einem eigenen Repository entwickelt. Das KDE Valgrind Modul beinhaltet nur Valgrind bis zur Version 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages für die KDE Site (und verwandte Sites). Schreibzugriff auf dieses Verzeichnis ist beschränkt.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die offiziellen Veröffentlichung von den Programmen die im KDE Repository verwaltet und entwickelt werden. Jede einzelne Applikation hat hier ein Unterverzeichnis, innerhalb von diesem finden Sie die Release-Nummern.&lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der Code für KDE 3.4.0 unter &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die Zweig-versionen von Applikationen nach einer Hauptveröffentlichung. &lt;br /&gt;
&lt;br /&gt;
Die meisten KDE Applikationen halten sich an die Philosophie, dass neue Features (ebenso wie neue Zeichneketten für den Benutzer) erst im nächsten Veröffentlichungszyklus &amp;amp;#8212; derjenige der in &amp;lt;tt&amp;gt;/trunkg/&amp;lt;/tt&amp;gt; entwickelt wird &amp;amp;#8212; einfließen. Fehlerbereinigungen werden jedoch auf alle Applikationen angewandt, auch nach einer Veröffentlichung.&lt;br /&gt;
&lt;br /&gt;
Um das zu bewerkstelligen, wird ein Zwei in dem Moment der Veröffentlichung erzeugt und zeigt damit den Status dieser Dateien zu diesem Zeitpunkt an. Fehlerbereinigungn werden dann in diese Dateien eingepflegt. Diese Zweige sind dann diejenigen die unter &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt; zu finden sind. &lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der KDE 3.4.x Zweig unter &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
Die Unterverzeichnisse die Sie in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; finden, sie die Unterverzeichnisse der Aplikationen wie &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. Sie finden hier auch ein &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
Unterverzeichnis, welches die offiziellen KDE Veröffentlichung beinhalten.&lt;br /&gt;
&lt;br /&gt;
Es gibt ein spezielles Unterverzeichnis in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; namens &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. Dieses Unterverzeichnis wird als &amp;quot;Arbeitszweig&amp;quot; berzeichnet und beinhaltet Zweige bei denen an neuen Features gearbeitet wird. Manchmal sind diese sehr experimentell. Arbeitszweige für mehrere Applikationen finden sich in &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, doch für einzelne Applikationen finden sich Arbeitszweige im jeweiligen Unterverzeichnis. Diese Entscheidung liegt bei den Entwicklern. &lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
Um entwas aus Subversion auszuchecken benutzt man das Unterkommando &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
'''WARNUNG:''' Wenn Sie trunk/KDE oder branches/KDE/foo auschecken werden Sie auch die komplette kde-i18n herunterladen!&lt;br /&gt;
&lt;br /&gt;
Angenommen Sie wollen nur KDevelop aus dem KDE Repository auschecken, würden Sie folgende Kommandos eingeben:&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
&lt;br /&gt;
CVS Benutzer die einen ssh Zugang besitzen, sollten das Protokoll svn+ssh,&lt;br /&gt;
CVS Benutzer, die einen Passwortzugang benutzen sollten das Protokoll https im folgenden benutzen.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
Um zu aktualisieren, benutzen Sie das &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; Unterkommando.&lt;br /&gt;
&lt;br /&gt;
Hier gibt es keinen Unterschied zu CVS: Sie wechseln in ihre ausgecheckte lokale Kopie (für diejenigen, für die das alles neu ist: die ausgecheckte Kopie sollte sich in Ihrem Heimatordner befinden) und geben ein &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; Kommando (oder kürzer &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
Um herauszufinden welche lokalen Dateien verändert wurden, haben die meisten unter CVS das Kommando cvs up aufgerufen und dann diejenigen Dateien gesucht, die mit einem '''M''' markiert waren. Das funktioniert unter svn nicht, daher müssen Sie das Kommando &amp;lt;tt&amp;gt;svn status&amp;lt;/tt&amp;gt; aufrufen, um den Status der Dateien zu ermitteln.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Um Änderungen hochzuladen ruft man, ähnlich wie bei CVS, die Unterkommandos &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (Kurzversion davon &amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt;) auf.&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Auf diese Weise wird &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; den in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; eingetragenen Texteditor aufrufen, damit Sie das Änderungsprotokoll ausfüllen können. Wenn Sie es vorziehen, können Sie &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; auch über die -m Option eine vollständige Mitteilung übergeben:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion speichert die zu ignorierenden Dateien für jedes Verzeichnis. Um diese Liste für das aktuelle Verzeichnis zu bearbeiten, rufen Sie einfach&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
auf. Damit wird der eingestellte Editor aufgerufen, in dem Sie die Namen der Dateien eintragen können, die ignoriert werden sollen, eine Datei pro Zeile. Wenn Sie fertig sind, einfach ein commit ausführen, damit die Dateien auf dem Server aktualisiert werden.&lt;br /&gt;
&lt;br /&gt;
Eine Menge Dateien wurden bei CVS mit Hilfe der globalen Ignorierliste ignoriert, diese Liste wird von SVN nicht unterstützt. Sie können auf svn 1.3 warten oder Sie müssen die Ignorierliste in die Sammelgruppe in ihrer {{path|~/.subversion/config}} einfügen (alle in einer Zeile):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Mit verschiedenen Revisionen und Branches arbeiten ==&lt;br /&gt;
&lt;br /&gt;
Andes als CVS erzeugt Subversion keine Revisions-Nummer für jede veränderte Datei. Statt dessen wird das gesamte Repository als ganzes mit einer Revisions-Nummer versehen. Auf diese Art bezeichnet eine Revisions-Nummer einen bestimmten Status, den das Repository zu einem bestimmten Zeitpunkt hatte. In anderen Worten: Die Revisions-Nummer ist wie ein Zeitstempel (tatsächlich benutzt der Subversion-Server diesen Umstand, um schneller nach Daten im Repository zu suchen)&lt;br /&gt;
&lt;br /&gt;
Wenn Sie also einen Check-out machen, teilt Ihnen Subversion das folgende (als Beispiel) mit:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
Das bedeutet, dass die letzte verfügbare Revision zu dem Zeitpunkt der Operation die Nummer 403821 ist. Wenn Sie eine Änderung vornehmen und abschicken (per commit), wird Subversion serverseitig die Revision aktualisiert und Sie davon in Kenntnis setzen. Wie in CVS werden nur die veränderten Dateien aktualisiert: Sie müssen &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; aufrufen um den Rest der Dateien zu aktualisieren.&lt;br /&gt;
&lt;br /&gt;
Möchten Sie eine bestimmte Revsision eine Dateie haben, können Sie den &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt; Schalter benutzen. Neben der Revisions-Nummer akzeptiert -r eine Anzahl von weiteren Möglichkeiten:&lt;br /&gt;
  &lt;br /&gt;
* Die Revision-Nummer: Benutzen Sie beispielsweise -r 403819 um diese Version zu erhalten&lt;br /&gt;
* '''BASE''': Die Revision zu der Sie aktualisiert haben&lt;br /&gt;
* '''COMMITTED''': Die Revision an der eine Datei vor BASE zuletzt verändert wurde.&lt;br /&gt;
* '''PREV''': Die Revision des vorigen commits vor COMMITTED&lt;br /&gt;
* '''HEAD''': Die akuellste Revision die auf dem Server verfügbar ist&lt;br /&gt;
* '''{ date }''': Zwischen den geschwungenen Klammern kann ein Datum angegeben werden, damit die daran nähsten Änderungen gesucht werden&lt;br /&gt;
&lt;br /&gt;
Das folgende dienst der Darstellung der verschiedenen Bedeutungen der Schlüsselworte:&lt;br /&gt;
&lt;br /&gt;
# Wenn mann &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; aufruft, aktualisiert man zur neusten Revision. Angenommen Subversion teilt einem mit, dass man auf Revision 403821 aktualisiert hat, dann bedeutet das, dass HEAD und BASE die Revision 403821 haben.&lt;br /&gt;
# Wenn man die Datei README bearbeitet und hochläd (commit), teilt einem Subversion mit, dass man die Revision 403822 hochgeladen hat. Das bedeutet HEAD, BASE und COMMITTED sind 403822.&lt;br /&gt;
# Jetzt wird README erneut bearbeitet und hochgeladen (via commit). Jetzt ist PREV 403822 aber HEAD, BASE und COMMITTED sind zu einem neueren Wert aktualisiert (sagen wir zum Beispiel 403823)&lt;br /&gt;
# Nun verändert jemand anderes das Repsitory und man selber führt ein update der Arbeitskopie durch. Subversion teilt einem mit, dass man auf 403824 aktualisiet hat, das bedeutet, dass HEAD und BASE nun auf 403824 aktualisert wurden (doch PREV und COMMITTED bleiben gleich)&lt;br /&gt;
# Wenn nun jemand README bearbeitet, HEAD wird verändert. Die anderen Schlüsselworte bleiben für einen selber jedoch gleich, bis man ein update durchführt. Zu diesem Zeitpunkt haben wir HEAD bei 403825 (die neuste verfügbare Revision), BASE = 403824 (die Revision, auf die zuletzt aktualisiert wurde), COMMITTED = 403823 (die Revision der letzten Änderung an der Datei als man zuletzt aktualisiert hat) und PREV = 403822 (die Revision der Änderung vor COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Diese Schlüsselworte sind auch nützlich um logs und diffs für Aktualisieirungen des Repositorys zu erhalten.&lt;br /&gt;
&lt;br /&gt;
Wenn man sich den Unterschied zwischen der Arbeitskopie und BASE ansehen möchte, kann man &lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
aufrufen. Das ist eine sehr schnelle Operation, da Subversion eine lokale Kopie von BASE bereithält. Man benötigt keine Netzwerkverbindung um diese Operation durchzuführen.&lt;br /&gt;
&lt;br /&gt;
Möchte man den Unterschied zwischen der lokalen Kopie und der letzten verfügbaren Version auf dem Server betrachten, ruft man&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
auf. Möchte man sehen, was sich seit dem letzten Update am Repository geändert hat, ruft man &lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
auf. Möchte man die letzte Änderung an einer Datei vor BASE sehen, kann man &lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # oder&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
aufrufen. Das gleiche gilt auch für das &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; Kommando.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
Es kann vorkommen, dass man eine Kopie eines Unterverzeichnissen von einem anderen Ort einfügen möchte. Das geschieht dann aus Bequemlichkeit und nicht um in diesem Verzeichnis Code zu schreiben. Natürlich sollte dieses Verzeichnis automatisch aktualisiert werden wann immer das Original sich ändert. Subversion kann einem dabei helfen. Man muss die Eigenschaft &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; des Verzeichnisses bearbeiten und das Verzeichniss sollte hinzugefügt werden. Für das aktuelle Verzeichnisse benutzt man den Befehl &lt;br /&gt;
&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
und gibt die Zeile&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
ein. Ein Update wird nun &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; in das Unterverzeichnis &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt; holen.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Es können jedoch keine Änderungen an der lokalen Kopie des externen Verzeichnisses hochgeladen werden, denn es ist eine nur-lesen Kopie.}}&lt;br /&gt;
&lt;br /&gt;
Man kann &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; und kein anderes Protokoll verwnden, denn &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; ist für jeden zugreifbar. Das &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; Protokoll wird nur für Benutzer funktionieren, die damit arbeiten. Es gibt noch ein paar kleine Nachteile mit &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: &lt;br /&gt;
Es ist nicht immer mit &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt; synchronisiert, daher brauchen aktualisierungen im Originalast eine Zeit bis sie auf &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; erscheinen. Außerdem blockieren eine strenge Firewalls das &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; Protokoll.&lt;br /&gt;
&lt;br /&gt;
Ein spezieller Fall in KDE 3 ist das Unterverzeichnis &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, welches die KDE 3 build Werkzeuge beinhaltet. Es ist mit dem Hauptverzeichnis in allen Modulen verzeichnet und wird in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt; bearbeitet. Für &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; ist der KDE subversion Server so konfiguriert, dass es für alle einen nur-lesen Zugriff gestattet. Wenn man also &lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
sieht, besteht kein Anlass das zu ändern.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4/Providing_Online_Help_(de)</id>
		<title>Development/Architecture/KDE4/Providing Online Help (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4/Providing_Online_Help_(de)"/>
				<updated>2008-11-29T19:08:37Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4/Providing Online Help}}&lt;br /&gt;
&lt;br /&gt;
'''KDE Architecture - Providing online help'''&lt;br /&gt;
&lt;br /&gt;
Ein Programm einfach und intuitiv benutzbar zu machen, umfasst eine weite Bandbreite von Einrichtungen, die man im Allgemeinen als Online Hilfe bezeichnet. Online Hilfe hat meherer teilweise widersprechende Ziele: Auf der einen Seite soll es den Benutzern Antworten auf die Frage &amp;quot;Wie kann ich eine bestimmte Aufgabe erledigen?&amp;quot; geben, auf der anderen seite sollte es dem Benutzer helfen, die Applikation zu erforschen und neue, bisher unbekannte Funktionen zu finden, die er oder sie noch nicht kannten. Es ist wichtig zu erkennen, dass dieses nur erreicht werden kann, indem man mehere Ebenen der Hilfe anbietet:&lt;br /&gt;
&lt;br /&gt;
*Tooltips sind kleine Bezeichner, die erscheinen, wenn sich die Maus einige Zeit über Schnittstellenelementen befindet. Diese sind besonders für Werkzeugleisten wichtig, wo die Icons nicht immer ausreichend erklären, was ein bestimmter Knopf bewirkt. &lt;br /&gt;
*&amp;quot;What's this?&amp;quot; (Was ist das?) Hilfe ist üblicherweise eine längere und ausführlichere Erklärung eines Widget oder eines Menüeintrages. In Dialogen kann es auf zwei Arten aufgerufen werden: Entweder durch Drücken von Shift-F1 oder indem man auf das Fragezeichen in der Titelzeile klickt (letzters ist vom Window Manager abhängig). Der Maus Zeiger verwandelt sich in einen Pfeil mit Fragezeichen und das Hilfefenster erscheint, wenn der Benutzer das ihn interessierende Element anklickt. Die &amp;quot;What's this?&amp;quot; Hilfe für Menüeinträge wird üblicherweise über einen Knopf in der Werkzeugleiste aktiviert. Dieser zeigt einen Pfeil und ein Fragezeichen. &amp;lt;br/&amp;gt;Das Problem bei dieser Herangehensweise ist, dass der Benutzer nicht sehen kann, ob ein Widget eine Hilfe anbietet oder nicht. Wenn der Benutzer den Fragezeichenknopf aktiviert und dann keine Hilfe bekommt, wenn er ein Widget anklickt, wird er schnell frustriert werden.&lt;br /&gt;
&amp;lt;br&amp;gt;&amp;lt;br&amp;gt;&lt;br /&gt;
Der Vorteil der &amp;quot;What's this?&amp;quot; Hilfe, die von Qt und KDE zur Verfügung gestellt wird, ist, dass sie [http://doc.trolltech.com/4.4/richtext.html rich text] beinhalten kann, zum Beispiel verschiedene Schriftarten, Fett- und Kursivschrift und sogar Bilder und Tabellen.&lt;br /&gt;
[[Image:Qt3-whatsthis.png|frame|center|QWhatsThis screenshot]]&lt;br /&gt;
*Zu guter Letzt sollte jedes Programm ein Handbuch haben. Ein Handbuch wird normalerweise im khelpcenter betrachtet und über das Hilfe-Menü aktiviert. Das bedeutet, dass eine komplette zusätzliche Applikation sich öffnet und den Benutzer von seiner Arbeit ablenkt. Konsequenterweise sollte daher das Befragen des Handbuches nur notwednig sein, wenn die Tooltips und &amp;quot;What's this?&amp;quot; Hilfe nicht ausreichen. Natürlich hat ein Handbuch den Vorteil, dass es nicht nur einen einzelnen, isolierter Apsekt der Benutzerschnittstelle erklärt. Statt dessen erklärt es die Aspekte einer Applikation in einem größeren Kontext. Handbücher für KDE werden mit der [http://i18n.kde.org DocBook] markup language geschrieben.&lt;br /&gt;
&lt;br /&gt;
Aus der Sicht des Programmierers, bietet Qt eine einfach zu benutzende API für die Online Hilfe. Um einen Tooltip einem Widget zuzuordnen, benutze einfache die  setToolTip() Methode.&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
widget-&amp;gt;setToolTip(i18n(&amp;quot;This widget does something.&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wenn die Menüs und Werkzeugleisten mit der [[../Action Pattern|action pattern]] erzeugt werden, wird die Zeichenkette für den Tooltip aus dem ersten Argument des [http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKAction.html KAction] Konstruktors abgeleitet:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action = new KAction(i18n(&amp;quot;&amp;amp;Delete&amp;quot;), &amp;quot;editdelete&amp;quot;,&lt;br /&gt;
                     SHIFT+Key_Delete, actionCollection(), &amp;quot;del&amp;quot;)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Hier ist es auch möglich, einen Text zuzuordnen, der in der Statuszeile angezeigt wird, wenn der entsprechende Menüeintrag ausgewählt wird.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action-&amp;gt;setStatusText(i18n(&amp;quot;Deletes the marked file&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die API für die &amp;quot;What's this?&amp;quot; Hilfe ist sehr ähnlich. In Diaglogen, benutze folgenden Code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
widget-&amp;gt;setWhatsThis(i18n(&amp;quot;&amp;lt;qt&amp;gt;This demonstrates &amp;lt;b&amp;gt;Qt&amp;lt;/b&amp;gt;'s&amp;quot;&lt;br /&gt;
                        &amp;quot; rich text engine.&amp;lt;ul&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;li&amp;gt;Foo&amp;lt;/li&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;li&amp;gt;Bar&amp;lt;/li&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;/ul&amp;gt;&amp;lt;/qt&amp;gt;&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für Menüeinträge benutze&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action-&amp;gt;setWhatsThis(i18n(&amp;quot;Deletes the marked file&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Der Aufruf von khelpcenter wird in der&lt;br /&gt;
[http://api.kde.org/4.x-api/kdelibs-apidocs/kdecore/html/classKToolInvocation.html KToolInvocation] Klasse abgekapselt. Um das Handbuch deiner Applikation anzuzeigen, muß nur die statische Methode aufgerufen werden:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
KToolInvocation::invokeHelp()&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Dadurch wird die erste Seite mit dem Inhaltverzeichnis dargestellt. Wenn du nur einen bestimmten Abschnitt des Handbuches anzeigen willst, kannst du ein zusätzliches Argument an invokeHeko() übergeben, welches den Anchor festlegt, zu dem der Browser springen soll. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Ursprünglicher Autor (des englischen Artikels):'' [mailto:bernd@kdevelop.org Bernd Gehrmann]&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4_(de)</id>
		<title>Development/Architecture/KDE4 (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4_(de)"/>
				<updated>2008-11-29T18:36:25Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: fixed some german links&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4}}&lt;br /&gt;
== Development Framework ==&lt;br /&gt;
&lt;br /&gt;
# Desktop&lt;br /&gt;
#* [[Development/Architecture/KDE4/Plasma (de)|Plasma - Der Desktop]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Sonnet|Sonnet - Technik zum Rechtschreib- und Grammatikcheck]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/KParts (de)|KParts - Die KDE Komponentenarchitektur]]&lt;br /&gt;
# Hardware&lt;br /&gt;
#* [[Development/Architecture/KDE4/Solid|Solid - Schnittstelle zur Hardware und Netzwerken]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Phonon|Phonon - Multimedia framework]]&lt;br /&gt;
# Communication&lt;br /&gt;
#* [[Development/Architecture/KDE4/Decibel|Decibel - Framework für Echtzeitkommunikation]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Akonadi|Akonadi - Zentralisierte PIM Speicherlösung]]&lt;br /&gt;
# User Interface&lt;br /&gt;
#* [[Development/Architecture/KDE4/Providing_Online_Help (de)|Online Hilfe verfügmar machen]]&lt;br /&gt;
# Services&lt;br /&gt;
#* [[Development/Architecture/KDE4/Strigi|Strigi - Desktop Suchmaschine]]&lt;br /&gt;
#* [[Projects/KNS2|KNewStuff2 - Gemeinsame Daten benutzen]] (könnte hierher von den Projekten verschoben werden)&lt;br /&gt;
&lt;br /&gt;
== Frameworks in anderen KDE Modulen ==&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/KDE4/KGGZ|KGGZ]]&lt;br /&gt;
: Bietet Zugang zur GGZ Gaming Zone, ein freies Zentrum für Online-Spiele.&lt;br /&gt;
&lt;br /&gt;
KOffice 2.0&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]][[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4/Decibel</id>
		<title>Development/Architecture/KDE4/Decibel</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4/Decibel"/>
				<updated>2008-11-29T18:34:52Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4/Decibel}}&lt;br /&gt;
'''Decibel'''&lt;br /&gt;
&lt;br /&gt;
Communication, as a fundamental part of your daily work and private life, should be integrated into your desktop environment. This integration should transparently handle all the different protocols available to chat, speak or video-conference with your friends and coworkers.&lt;br /&gt;
&lt;br /&gt;
Decibel wants to provide such a framework for real-time communication. It is meant to integrate traditional phone services with VoIP and instant messaging. By providing a component based service architecture, Decibel is meant to make it easy for developers to have their applications offer advanced communication and collaboration features which will allow the user to integrate this technology into their workflows.&lt;br /&gt;
&lt;br /&gt;
Some features:&lt;br /&gt;
* Uses Tapioca -library to implement Telepathy secification&lt;br /&gt;
* Decibel daemon, formerly known as &amp;quot;Houston&amp;quot;&lt;br /&gt;
* pure Qt4 code, independent of other KDE libs.&lt;br /&gt;
&lt;br /&gt;
===Further reading===&lt;br /&gt;
* [http://decibel.kde.org/index.php Decibel homepage]&lt;br /&gt;
* [http://telepathy.freedesktop.org/wiki/ Telepathy]&lt;br /&gt;
* [http://dot.kde.org/1170892771/ Nathan Ogden's introduction to Decibel Part I - Overview]&lt;br /&gt;
* [http://dot.kde.org/1171659655/ Nathan Ogden's introduction to Decibel Part II - Definitions]&lt;br /&gt;
* Nathan Ogden's introduction to Decibel Part III - Benefits for developers&lt;br /&gt;
* Nathan Ogden's introduction to Decibel Part IV - Benefits for users&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4/Solid</id>
		<title>Development/Architecture/KDE4/Solid</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4/Solid"/>
				<updated>2008-11-29T18:32:29Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4/Solid}}&lt;br /&gt;
&lt;br /&gt;
== Seamless Hardware Interaction ==&lt;br /&gt;
With Solid, KDE developers are able to easily write applications with hardware interaction features. The necessary abstraction to support&lt;br /&gt;
cross-platform application development is provided by Solid's clear and comprehensive API.&lt;br /&gt;
&lt;br /&gt;
Its aim is not the control of the devices (Solid doesn't let you syncronize your mobile phone with your local addressbook): Solid *looks for* devices and gives you access to the information it has about them. This way, you could easily look at the functions of the cpu, or at the driver that handles your camera, or the mount point of your usb pen. In sum: it gives you the possibility of &amp;quot;seeing without touching&amp;quot; your devices.&lt;br /&gt;
&lt;br /&gt;
Now you would ask (at least, I asked myself): &amp;quot;Why should I need this library? I want to control the available hardware, not just see it!&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Well, Solid helps you a lot again: for any device interface, it gives you enough information to easily access it using other libraries or stacks. This way, if you want to manage your camera, you can use Solid to recognize it (you can use Solid::Notifier that will let you know when your camera has been plugged in), and then you can ask Solid to give you the information you need to handle it, for example with GPhoto or any other library you can think of. The same applies for any other plugged device: DVB cards (once recognized, Solid gives you the name of the associated device), audio cards (you can use ALSA, OSS or whatever you want: Solid knows the data to access it), portable media players, network cards, et cetera.&lt;br /&gt;
Moreover, it lets you check if you're connected to any network or not, and you can use Solid to tell the system to connect (that is, you can ask Solid: &amp;quot;Give me access to the network, I don't want to care about details&amp;quot;).&lt;br /&gt;
&lt;br /&gt;
Anyway, some other things needs to be said about network devices and Bluetooth. For these two classes of devices, Solid provides the &amp;quot;Control&amp;quot; namespace: that is, it lets you control them directly, without using external libraries. This means that with Solid, you can even handle your wireless or wired network interfaces, associate them to an essid, and choose ip configuration for them. You can even access your phone through Bluetooth, and so on.&lt;br /&gt;
&lt;br /&gt;
The &amp;quot;listing&amp;quot; part of Solid resides in kdelibs, while the Control namespace is in kdebase.&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;br /&gt;
[[Category:Architecture]]&lt;br /&gt;
[[Category:Solid]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4/Providing_Online_Help</id>
		<title>Development/Architecture/KDE4/Providing Online Help</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4/Providing_Online_Help"/>
				<updated>2008-11-29T18:27:56Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4/Providing Online Help}}&lt;br /&gt;
&lt;br /&gt;
'''KDE Architecture - Providing online help'''&lt;br /&gt;
&lt;br /&gt;
Making a program easy and intuitive to use involves a wide range of&lt;br /&gt;
facilities which are usually called online help. Online help has several,&lt;br /&gt;
partially conflicting goals: on the one, it should give the user answers&lt;br /&gt;
to the question &amp;quot;How can I do a certain task?&amp;quot;, on the other hand it&lt;br /&gt;
should help the user exploring the application and finding features he&lt;br /&gt;
doesn't yet know about. It is important to recognize that this can only&lt;br /&gt;
be achieved by offering several levels of help:&lt;br /&gt;
&lt;br /&gt;
*Tooltips are tiny labels that pop up over user interface elements when the mouse remains there longer. They are especially important for tool- bars, where icons are not always sufficient to explain the purpose of a button. &lt;br /&gt;
*&amp;quot;What's this?&amp;quot; help is usually a longer and richer explanation of a widget or a menu item. It is also more clunky to use: In dialogs, it can be invoked in two ways: either by pressing Shift-F1 or by clicking on the question mark in the title bar (where the support of the latter depends on the window manager). The mouse pointer then turns into an arrow with a question mark, and the help window appears when a user interfact element has been clicked. &amp;quot;What's this?&amp;quot; help for menu items is usually activated by a button in the toolbar which contains an arrow and a question mark. &amp;lt;br/&amp;gt;The problem with this approach is that the user can't see whether a widget provides help or not. When the user activates the question mark button and doesn't get any help window when clicking on a user interface element, he will get frustrated very quickly.&amp;lt;br/&amp;gt;&amp;lt;br/&amp;gt; The advantage of &amp;quot;What's this?&amp;quot; help windows as provided by Qt and KDE is that they can contain [http://doc.trolltech.com/4.4/richtext.html rich text], i.e. the may contain different fonts, bold and italic text and even images and tables.&lt;br /&gt;
[[Image:Qt3-whatsthis.png|frame|center|QWhatsThis screenshot]]&lt;br /&gt;
*Finally, every program should have a manual. A manual is normally viewed in khelpcenter by activating the help menu. That means, a complete additional application pops up and diverts the user from his work. Consequently, consulting the manual should only be necessary if other facilities like tooltips and what's this help are not sufficient. Of course, a manual has the advantage that it does not explain single, isolated aspects of the user interface. Instead, it can explain aspects of the application in a greater context. Manuals for KDE are written using the [http://i18n.kde.org DocBook] markup language.&lt;br /&gt;
&lt;br /&gt;
From the programmer's point of view, Qt provides an easy to use API for online&lt;br /&gt;
help. To assign a tooltip to widget, simply use its setToolTip() method.&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
widget-&amp;gt;setToolTip(i18n(&amp;quot;This widget does something.&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
If the menu bars and tool bars are created using the [[../Action Pattern|action pattern]], the string used as tooltip is derived from the first argument&lt;br /&gt;
of the [http://api.kde.org/4.x-api/kdelibs-apidocs/kdeui/html/classKAction.html KAction] constructor:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action = new KAction(i18n(&amp;quot;&amp;amp;Delete&amp;quot;), &amp;quot;editdelete&amp;quot;,&lt;br /&gt;
                     SHIFT+Key_Delete, actionCollection(), &amp;quot;del&amp;quot;)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Here it is also possible to assign a text which is shown in the status bar when the  respective menu item is highlighted:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action-&amp;gt;setStatusText(i18n(&amp;quot;Deletes the marked file&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The API for &amp;quot;What's this?' help is very similar. In dialogs, use the following&lt;br /&gt;
code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
widget-&amp;gt;setWhatsThis(i18n(&amp;quot;&amp;lt;qt&amp;gt;This demonstrates &amp;lt;b&amp;gt;Qt&amp;lt;/b&amp;gt;'s&amp;quot;&lt;br /&gt;
                        &amp;quot; rich text engine.&amp;lt;ul&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;li&amp;gt;Foo&amp;lt;/li&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;li&amp;gt;Bar&amp;lt;/li&amp;gt;&amp;quot;&lt;br /&gt;
                        &amp;quot;&amp;lt;/ul&amp;gt;&amp;lt;/qt&amp;gt;&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For menu items, use&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
action-&amp;gt;setWhatsThis(i18n(&amp;quot;Deletes the marked file&amp;quot;))&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The invocation of khelpcenter is encapsulated in the &lt;br /&gt;
[http://api.kde.org/4.x-api/kdelibs-apidocs/kdecore/html/classKToolInvocation.html KToolInvocation]&lt;br /&gt;
class. In order to show the manual of your application, just use the static method:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt3&amp;gt;&lt;br /&gt;
KToolInvocation::invokeHelp()&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This displays the first page with the table of contents. When&lt;br /&gt;
you want to display only a certain section of the manual, you&lt;br /&gt;
can give an additional argument to invokeHelp() determining&lt;br /&gt;
the anchor which the browser jumps to.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
''Initial Author:'' [mailto:bernd@kdevelop.org Bernd Gehrmann]&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4/KParts_(de)</id>
		<title>Development/Architecture/KDE4/KParts (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4/KParts_(de)"/>
				<updated>2008-11-29T18:24:36Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4/KParts}}&lt;br /&gt;
'''KParts''' ist der Name des Komponenten-Frameworks für KDE: Eine einzelne Komponente wirde '''KPart''' genannt. Beispielsweise ist Konsole als ein KPart verfügbar und kann in Applikationen wie Konqueror oder Kate benutzt werden. Ein guten Beisiel, wie KParts benutzt werden können, ist Konqueror. Dieser benutzt, neben anderen, das KWord-Part um Dokumente darzustellen, den KMPlayer-Part um Multimedia abzuspielen. Ein anderes Beispiel ist Kontact, welches die einzelnen kdepim Appliaktaionen unter einem Dach vereinigt. &lt;br /&gt;
&lt;br /&gt;
===Zum weiterlesen===&lt;br /&gt;
* [http://api.kde.org/4.0-api/kdelibs-apidocs/kparts/html/index.html KParts API Referenz]&lt;br /&gt;
* [http://api.kde.org/4.0-api/kdelibs-apidocs/kparts/html/classKParts_1_1Part.html KParts Klassen Referenz]&lt;br /&gt;
* [http://www-106.ibm.com/developerworks/library/l-kparts/ Coding with KParts] (von IBM, englisch)&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture_(de)</id>
		<title>Development/Architecture (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture_(de)"/>
				<updated>2008-11-29T18:17:13Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Design Dokumente */ Links to german page now&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture}}&lt;br /&gt;
Die folgenden Seiten beinhalten detailierte Dokumentationen über das Design und die Architektur von KDE. Sie ersetzen nicht die anderen Dokumentationen wie [http://api.kde.org API Dokumentation (englisch)], [[../Tutorials|tutorials/howtos]] und [[../Guidelines|standards]], siehe auch das [[Development (de)|Entwickler Portal]] für weitere Informationen.&lt;br /&gt;
&lt;br /&gt;
Für ein besseren Verständnis könnte es helfen sich mit Trolltech's&amp;amp;trade; excellenter [http://doc.trolltech.com/3.3/index.html Qt 3.3] oder [http://doc.trolltech.com/4.3/index.html Qt 4.3] Dokumentation und deren [http://www.trolltech.com/developer/ Entwickler Seiten] zu beschäftigen.&lt;br /&gt;
&lt;br /&gt;
Für mehr Informationen über eine KDE Installtion sehen Sie bitte auch die entsprechenden Kapitel in [[KDE System Administration|System Administration]].&lt;br /&gt;
&lt;br /&gt;
== Design Dokumente ==&lt;br /&gt;
; [[Development/Architecture/KDE4 (de)|Überblick über die KDE 4 Architektur]]&lt;br /&gt;
: Ein Überblick über die KDE 4 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 4.0''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/KDE3|Überblick über die KDE 3 Architektur]] [http://developer.kde.org/documentation/library/kdeqt/kde3arch/ (Original)]&lt;br /&gt;
: Ein Überblick über die KDE 3 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 3.0''.&lt;br /&gt;
&lt;br /&gt;
; [http://developer.kde.org/documentation/library/kdeqt/kde2arch/ Überblick über die KDE 2 Architektur]&lt;br /&gt;
: Ein Überblick über die KDE 2 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 2.2''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/DCOP|DCOP]]&lt;br /&gt;
: Design Dokumente von 1999-2000.&lt;br /&gt;
&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture/KDE4_(de)</id>
		<title>Development/Architecture/KDE4 (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture/KDE4_(de)"/>
				<updated>2008-11-29T18:14:53Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Created and translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture/KDE4}}&lt;br /&gt;
== Development Framework ==&lt;br /&gt;
&lt;br /&gt;
# Desktop&lt;br /&gt;
#* [[Development/Architecture/KDE4/Plasma|Plasma - Der Desktop]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Sonnet|Sonnet - Technik zum Rechtschreib- und Grammatikcheck]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/KParts|KParts - Die KDE Komponentenarchitektur]]&lt;br /&gt;
# Hardware&lt;br /&gt;
#* [[Development/Architecture/KDE4/Solid|Solid - Schnittstelle zur Hardware und Netzwerken]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Phonon|Phonon - Multimedia framework]]&lt;br /&gt;
# Communication&lt;br /&gt;
#* [[Development/Architecture/KDE4/Decibel|Decibel - Framework für Echtzeitkommunikation]]&lt;br /&gt;
#* [[Development/Architecture/KDE4/Akonadi|Akonadi - Zentralisierte PIM Speicherlösung]]&lt;br /&gt;
# User Interface&lt;br /&gt;
#* [[Development/Architecture/KDE4/Providing_Online_Help|Online Hilfe verfügmar machen]]&lt;br /&gt;
# Services&lt;br /&gt;
#* [[Development/Architecture/KDE4/Strigi|Strigi - Desktop Suchmaschine]]&lt;br /&gt;
#* [[Projects/KNS2|KNewStuff2 - Gemeinsame Daten benutzen]] (könnte hierher von den Projekten verschoben werden)&lt;br /&gt;
&lt;br /&gt;
== Frameworks in anderen KDE Modulen ==&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/KDE4/KGGZ|KGGZ]]&lt;br /&gt;
: Bietet Zugang zur GGZ Gaming Zone, ein freies Zentrum für Online-Spiele.&lt;br /&gt;
&lt;br /&gt;
KOffice 2.0&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]][[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development_(de)</id>
		<title>Development (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development_(de)"/>
				<updated>2008-11-29T17:02:37Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Architektur links now to german page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOEDITSECTION__ __NOTOC__ {{Template:I18n/Language Navigation Bar|Development}}&lt;br /&gt;
{| style=&amp;quot;margin: 1em 2.5% 0 2.5%; padding: 0 5px;&amp;quot; cellpadding=&amp;quot;5&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
|colspan=2|[[Image:Discover.png|noframe]]&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;padding-left: 50px;&amp;quot; |[[Image:Action_launch.svg|noframe|left|40px]] ||&lt;br /&gt;
;[[Development/Architecture (de)|KDE Architektur]]&lt;br /&gt;
: Designdokumente der KDE Architektur und Technologien.&lt;br /&gt;
:''Mehr'': [http://api.kde.org API Dokumentation]&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;padding-left: 50px;&amp;quot;|[[Image:Action_configure.svg|noframe|left|40px]] ||&lt;br /&gt;
;[[Development/Tutorials (de)|Programmieranleitung]]&lt;br /&gt;
:Schritt-für-Schritt Anleitung zur KDE Entwicklung.&lt;br /&gt;
:''Mehr:'' [[Development/Tools|Entwicklerwerkzeuge]] | [[Development/FAQs|FAQs]]&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;padding-left: 50px;&amp;quot;|[[Image:Action_rebuild.svg|noframe|left|40px]] ||&lt;br /&gt;
;[[Development/Languages (de)|Sprachbindungen]]&lt;br /&gt;
:Unterstützte Programmiersprachen.&lt;br /&gt;
|-&lt;br /&gt;
| style=&amp;quot;padding-left: 50px;&amp;quot; |[[Image:Action_note.svg|noframe|left|40px]] ||&lt;br /&gt;
;[[Development/Guidelines|Standards &amp;amp; Richtlinien]]&lt;br /&gt;
:Entwicklerrichtlinien und technische Standards die KDE verwendet.&lt;br /&gt;
:''Mehr:'' [[Development/Further Information|Weitere Informationen]] (Links, Bücher, Blogs, usw.)&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-29T16:53:11Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* APIDOX in neuem Code schreiben */ more translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Die Grundlagen von apidox sind einfach und machen Spaß: Man schreibt einfach Kommentare in den Code, die erklären wofür dieser ist. Diese Kommetare sind fast das gleiche wie das, was man sowieso in die header des Codes schreiben muß, so ist das ganze also nicht so schwer. &lt;br /&gt;
&lt;br /&gt;
APIDOX werden in speziellen Kommentaren geschrieben. Diese Kommentare starten mit /** (Schrägstrich, Stern, Stern) -- und das ist es, was sie besonders macht. Der Rest des Kommentars ist einfacher Text, der den Teil des Programms beschreibt. Dieser Text wird vom Doxygen Prozessor interpretiert, damit dadurch passende Beschreibungen der Parameter und Rückgabewerte erfolgen kann. Doch die Dokumentation ist recht unkompliziert: Man schreibt einfach, was eine Methode tut innerhalb von /** und */, so wie folgendes Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für eine vernünftige apidox muß jedes &amp;quot;Ding&amp;quot; des Programms dokumentiert werden. &amp;quot;Dinge&amp;quot; sind hierbei Verzeichnisse, Dateien, Namensräume, Klassen, Methoden, Aufzählungen und Variablen. Man kann eventuell Dateien und Verzeichnisse auslassen und sich nur auf die letzteren Punkte konzentrieren. Komplette apidox sehen ungefähr so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wie man sieht, ist jede Schachtelungsebene der eben erwähnten &amp;quot;Dinge&amp;quot; mit einem Kommentar versehen -- Der Namensraum, die Klasse und die Methode. Private &amp;quot;Dinge&amp;quot; benötigen keine apidox, protected &amp;quot;Dinge&amp;quot; jedoch schon.  &lt;br /&gt;
&lt;br /&gt;
Es ist wichtig, jede einzelne Schachtelungsebene zu dokumentieren, denn läßt man einen Ebene aus, ignoriert Doxygen die inneren ebenso und man findet diese nicht mehr wieder. Angenommen man würde im obigen Beispiel die Klassendokumentation weglassen, dann würde die Dokumentation für die Methode Socket() ebenfalls verschwinden. Das ist eine der typischen Fallen beim Schreiben von apidox.  &lt;br /&gt;
&lt;br /&gt;
Und wenn man nur eine Erklärung für jeden Teil seines Programmes schreibt, hat man schon einen großen Teil des Weges zu einer kompletten apidox hinter sich gelassen. Diese Erklärungen zu schreiben macht das Programm einfacher für andere Entwickler zu verstehen und zeigt einem oft schon sub-optimale Designs oder Namenswahlen. Auf diese Art gewinnen beide Seiten.  &lt;br /&gt;
&lt;br /&gt;
Man findet in der Liste von unterstützen Tags auch Beispiele für ausgefallenere apidox -- Erklärung von Parametern oder wie man die apidox mit Beispielen und Personendaten versieht. Es lohnt sich auch nachzusehen, wie man apidox aktiviert, doch es ist auch möglich die Arbeit aufzuteilen: Du schreibst die apidox selber und fragst den Originalautor (mailto:groot@kde.org), diese für dein Modul zu aktivieren. Er verspricht (zunmindest in der englischsprachigen Originalversion) das dann zu tun.  &lt;br /&gt;
 &lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
Wenn mann neuen Code schreibt und dabei apidox verwenden möchte, sollte man am besten KDevelop benutzen. Vernünftig konfiguriert kann dieses automatisch ein Grundgerüst für apidox einfügen, man muß dann nur noch die eigentlichen Beschreibungen einfügen. Und man muß sich nicht mehr mit apidox kommandos rumärgern. &lt;br /&gt;
&lt;br /&gt;
Wenn man sich nicht in dieser günstigen Lage befindet, sollte die folgende Checkliste einen durch die schlimmsten Untiefen beim Schreiben von apidox führen:&lt;br /&gt;
&lt;br /&gt;
'''1. Schreibe die apidox direkt mit dem Code zusammen'''&lt;br /&gt;
&lt;br /&gt;
Wenn man es mit etwas Disziplin schafft, direkt beim Schreiben einer Funktion foo(), wo man sich sowieso Gedanken über den gewünschten Effekt machen muss, auch gleich an die apidox zu denken, spart man sich diese Zeit sicherlich später, wenn man nicht mehr mühsam herausfinden muss, was die Funktion foo() eigentlich machen soll. &lt;br /&gt;
&lt;br /&gt;
Das heißt nicht, dass man es auf diese Art und Weise machen muss, doch es bietet sich an. Durch die apidox werden auch Entscheidungen bezüglich des Designs dokumentiert. Auch wird dokumentiert, was ein bestimmter Codeabschnitt eigentlich macht, unabhängig davon, was er aktuell tut. Das macht es möglich, unabhängig zu überprüfen, ob der Code das tut, wozu er geschrieben ist. Das liegt daran, dass es bereits in der apidox dokumentiert wurde. &lt;br /&gt;
&lt;br /&gt;
'''2. Dokumentierte deine Header vollständig'''&lt;br /&gt;
&lt;br /&gt;
Die Header sind das, was den Benutzern als erstes vom Code ins Auge springt (in diesem Zusammenhang sind Entwickler Benutzer, die Code wiederverwenden). Aus diesem Grund sollen sie vollständig sein, d.h. jede noch so kleine Struktur sollte im Header dokumentiert werden. Im Einzelnen:&lt;br /&gt;
&lt;br /&gt;
*Jede Datei sollte einen Kommentar haben, der den Nutzen dieser Datei beschreibt. Das wird von den KDE Richtlinien sowieso vorgeschrieben -- am Anfang der Datei sollte einfach vermerkt werden, wofür die Datei gut ist und in groben Zügen, was sie definiert. Das sollte in einem /** @file */ Kommentar erfolgen.&lt;br /&gt;
* Jeder Namensraum (namespace) sollte einen Kommentar haben. Ein bestimmter Namensraum benötigt nur einmal im Quellcodebaum einen Kommentar, doch es kann nicht schaden ihn bei jedem Auftreten erneut zu beschreiben -- nur kurz sollte es sein. Diese Kommentare sind einfache apidox Kommentare zwischen /** und */; keine besonderen Befehle wie bei Dateien das @file Befehl.&amp;lt;br&amp;gt;&lt;br /&gt;
Man sollte nur sicherstellen, dass der Kommentar direkt vor dem Namensraum steht und nichts dazwischen steht. Das folgende Beispiel zeigt, wie es aussehen soll:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:Im nächsten Beispiel hat jemand etwas Extracode zwischen den apidox Kommentar und den Namensraum, der dokumentiert werden soll, gebracht. Das könnte Doxygen zu Fehlern bringen (in diesem Fall ist es einfach den Fehler zu finden) oder die Dokumentation des Namensraum kann sich plötzlich auf etwas ganz anderes beziehen (dann ist der Fehler schwer zu finden).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
Es kann nützlich sein, Beispielcode zur APIDOX einer Klasse hinzuzufügen. Sehr nützlich ist es auf jeden Fall für Leser, die sich fragen, wie man eine Klasse genau zu benutzen hat. Die meisten Klassen in {{path|kdelibs/kdecore}} haben Beispielcode.&lt;br /&gt;
&lt;br /&gt;
Ein Weg, um Beispielcode zu schreiben ist es, @code und @endcode um den Block des Beispielcodes in den Doxygenkommentaren selber zu legen, wie im folgenden Beispiel:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Auf diese Art wird es in den meisten Beispielen in {{path|kdelibs}} gemacht. Das funktioniert auch ganz gut, man kann sich bei den Beispielen aufs wesentliche beschränken.&lt;br /&gt;
&lt;br /&gt;
Ein wichtiges Problem dieser Herangehensweise um Beispielcode zu schreiben ist es, dass der Code niemals geprüft wird, ob er wirklich funktioniert. Die meisten Codebeispiele sind so gepackt, dass es schwer ist, diese in einen funktionsfähigen Code umzuschreiben, der wirklich kompiliert und läuft.&lt;br /&gt;
&lt;br /&gt;
Um dieses Problem zu lösen, kann man ''richtigen Code'' schreiben, der wirklich kompiliert (als Teil dr Test-Suite für den Code, den man sowieso hat) und exakt beschreibt, wie eine Klasse in einem richtigen Programm benutzt werden soll. Man muß jedoch nicht den gesamten Code in die APIDOX übernehmen, sondern braucht nur die interessanten Teile zu markieren. Um das zu bewerkstelligen, wird eine Datei in das &amp;lt;tt&amp;gt;tests&amp;lt;/tt&amp;gt; Unterverzeichnis eingefügt. Dann kann man das Doxygen @include-Tag benutzen, um den Code dieser Datei in die API Dokumentation zu übernehmen.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-11-29T11:38:38Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Working with multiple revisions and branches */ partly translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; Hauptunterverzeichnis ist dasjenige, in dem die Hauptentwicklung an KDE stattfindet. Was Sie hier finden, wird als nächstes als KDE und assoziierte Programme veröffentlicht. Hier finden Sie auch das &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; Modul, welches die Webpages rund um KDE beinhaltet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; ist unterteilt in folgende Unterverzeichnisse:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE selber, welches die nächste Veröffentlichung werden wird. Es besteht aus folgenden Modulen:&lt;br /&gt;
**'''kdelibs''' - KDE Hauptbibliotheken, die von allen KDE Programmen benutzt werden&lt;br /&gt;
**'''kdebase''' - KDE Basisprogramme, wie das KDE Control Center, Plasma (die Oberfläche) und Konqueror (der Web Browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility Dateien&lt;br /&gt;
**'''kdeadmin''' - KDE Administrationsprogramme&lt;br /&gt;
**'''kdeartwork''' - Bilder, Themen, Sounds und andere künstlerische Dateien&lt;br /&gt;
**'''kdebindings''' - Bindungen für andere Sprache außer C++&lt;br /&gt;
**'''kdeedu''' - Erzieherische und Wissenschaftliche Programme für KDE&lt;br /&gt;
**'''kdegames''' - KDE Spiele&lt;br /&gt;
**'''kdegraphics''' - KDE Graphikapplicationen&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimediaapplicationen&lt;br /&gt;
**'''kdenetwork''' - KDE Netzwerkapplicationen&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management Applicationen &lt;br /&gt;
**'''kdepimlibs''' - Biblotheken, die von KDE-PIM Applicationen benötigt werden.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit Applicationen&lt;br /&gt;
**'''kdetoys''' - KDE Spielzeug Applicationen&lt;br /&gt;
**'''kdeutils''' - Allgemeine KDE Werkzeuge&lt;br /&gt;
**'''kdevelop''' - Das KDevelop Programm&lt;br /&gt;
**'''kdevplatform''' - Die Entwicklerplatform auf der KDevelop basiert&lt;br /&gt;
**'''kdewebdev''' - Eine KDE Webentwicklungsapplikation&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Allgemeines admin/ Verzeichnis&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] Dateien&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der Inhalt von developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE Programme die sich außerhalb der Haupt KDE Veröffentlichungen aufhalten&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Vorübergehende Heimat für all die KDE Applikationen, von denen geglaubt wird, daß sie reif für eine Veröffentlichung sind. Von hier aus werden die Applikationen entweder nach &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; oder nach &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt; verschoben, sobald die größten Probleme ausgeräumt sind.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Unterstützende Programme und Bibliotheken für KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;Das KDE Office Paket, welches folgende Programme beinhaltet:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, das KDE build Programm&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für die &amp;quot;unstabilen&amp;quot; Module von KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der KDE Spielplatz: Applications die gerade entwickelt werden aber noch keine Veröffentlichungsqualität erreicht haben.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Zu Vereinfachung eine Kopie von  [http://www.trolltech.com/ Trolltechs] Qt Bibliothek, auf welcher KDE basiert.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice und ksvg Testfälle&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Die Valgrind Application, welche im KDE Repository betreut wird jedoch kein Teil von KDE selber ist. Neuere Versionen von Valgrind werden in einem eigenen Repository entwickelt. Das KDE Valgrind Modul beinhaltet nur Valgrind bis zur Version 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages für die KDE Site (und verwandte Sites). Schreibzugriff auf dieses Verzeichnis ist beschränkt.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die offiziellen Veröffentlichung von den Programmen die im KDE Repository verwaltet und entwickelt werden. Jede einzelne Applikation hat hier ein Unterverzeichnis, innerhalb von diesem finden Sie die Release-Nummern.&lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der Code für KDE 3.4.0 unter &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die Zweig-versionen von Applikationen nach einer Hauptveröffentlichung. &lt;br /&gt;
&lt;br /&gt;
Die meisten KDE Applikationen halten sich an die Philosophie, dass neue Features (ebenso wie neue Zeichneketten für den Benutzer) erst im nächsten Veröffentlichungszyklus &amp;amp;#8212; derjenige der in &amp;lt;tt&amp;gt;/trunkg/&amp;lt;/tt&amp;gt; entwickelt wird &amp;amp;#8212; einfließen. Fehlerbereinigungen werden jedoch auf alle Applikationen angewandt, auch nach einer Veröffentlichung.&lt;br /&gt;
&lt;br /&gt;
Um das zu bewerkstelligen, wird ein Zwei in dem Moment der Veröffentlichung erzeugt und zeigt damit den Status dieser Dateien zu diesem Zeitpunkt an. Fehlerbereinigungn werden dann in diese Dateien eingepflegt. Diese Zweige sind dann diejenigen die unter &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt; zu finden sind. &lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der KDE 3.4.x Zweig unter &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
Die Unterverzeichnisse die Sie in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; finden, sie die Unterverzeichnisse der Aplikationen wie &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. Sie finden hier auch ein &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
Unterverzeichnis, welches die offiziellen KDE Veröffentlichung beinhalten.&lt;br /&gt;
&lt;br /&gt;
Es gibt ein spezielles Unterverzeichnis in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; namens &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. Dieses Unterverzeichnis wird als &amp;quot;Arbeitszweig&amp;quot; berzeichnet und beinhaltet Zweige bei denen an neuen Features gearbeitet wird. Manchmal sind diese sehr experimentell. Arbeitszweige für mehrere Applikationen finden sich in &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, doch für einzelne Applikationen finden sich Arbeitszweige im jeweiligen Unterverzeichnis. Diese Entscheidung liegt bei den Entwicklern. &lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
Um entwas aus Subversion auszuchecken benutzt man das Unterkommando &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
'''WARNUNG:''' Wenn Sie trunk/KDE oder branches/KDE/foo auschecken werden Sie auch die komplette kde-i18n herunterladen!&lt;br /&gt;
&lt;br /&gt;
Angenommen Sie wollen nur KDevelop aus dem KDE Repository auschecken, würden Sie folgende Kommandos eingeben:&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
&lt;br /&gt;
CVS Benutzer die einen ssh Zugang besitzen, sollten das Protokoll svn+ssh,&lt;br /&gt;
CVS Benutzer, die einen Passwortzugang benutzen sollten das Protokoll https im folgenden benutzen.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
Um zu aktualisieren, benutzen Sie das &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; Unterkommando.&lt;br /&gt;
&lt;br /&gt;
Hier gibt es keinen Unterschied zu CVS: Sie wechseln in ihre ausgecheckte lokale Kopie (für diejenigen, für die das alles neu ist: die ausgecheckte Kopie sollte sich in Ihrem Heimatordner befinden) und geben ein &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; Kommando (oder kürzer &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
Um herauszufinden welche lokalen Dateien verändert wurden, haben die meisten unter CVS das Kommando cvs up aufgerufen und dann diejenigen Dateien gesucht, die mit einem '''M''' markiert waren. Das funktioniert unter svn nicht, daher müssen Sie das Kommando &amp;lt;tt&amp;gt;svn status&amp;lt;/tt&amp;gt; aufrufen, um den Status der Dateien zu ermitteln.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Um Änderungen hochzuladen ruft man, ähnlich wie bei CVS, die Unterkommandos &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (Kurzversion davon &amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt;) auf.&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Auf diese Weise wird &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; den in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; eingetragenen Texteditor aufrufen, damit Sie das Änderungsprotokoll ausfüllen können. Wenn Sie es vorziehen, können Sie &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; auch über die -m Option eine vollständige Mitteilung übergeben:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion speichert die zu ignorierenden Dateien für jedes Verzeichnis. Um diese Liste für das aktuelle Verzeichnis zu bearbeiten, rufen Sie einfach&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
auf. Damit wird der eingestellte Editor aufgerufen, in dem Sie die Namen der Dateien eintragen können, die ignoriert werden sollen, eine Datei pro Zeile. Wenn Sie fertig sind, einfach ein commit ausführen, damit die Dateien auf dem Server aktualisiert werden.&lt;br /&gt;
&lt;br /&gt;
Eine Menge Dateien wurden bei CVS mit Hilfe der globalen Ignorierliste ignoriert, diese Liste wird von SVN nicht unterstützt. Sie können auf svn 1.3 warten oder Sie müssen die Ignorierliste in die Sammelgruppe in ihrer {{path|~/.subversion/config}} einfügen (alle in einer Zeile):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Mit verschiedenen Revisionen und Branches arbeiten ==&lt;br /&gt;
&lt;br /&gt;
Andes als CVS erzeugt Subversion keine Revisions-Nummer für jede veränderte Datei. Statt dessen wird das gesamte Repository als ganzes mit einer Revisions-Nummer versehen. Auf diese Art bezeichnet eine Revisions-Nummer einen bestimmten Status, den das Repository zu einem bestimmten Zeitpunkt hatte. In anderen Worten: Die Revisions-Nummer ist wie ein Zeitstempel (tatsächlich benutzt der Subversion-Server diesen Umstand, um schneller nach Daten im Repository zu suchen)&lt;br /&gt;
&lt;br /&gt;
Wenn Sie also einen Check-out machen, teilt Ihnen Subversion das folgende (als Beispiel) mit:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
Das bedeutet, dass die letzte verfügbare Revision zu dem Zeitpunkt der Operation die Nummer 403821 ist. Wenn Sie eine Änderung vornehmen und abschicken (per commit), wird Subversion serverseitig die Revision aktualisiert und Sie davon in Kenntnis setzen. Wie in CVS werden nur die veränderten Dateien aktualisiert: Sie müssen &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; aufrufen um den Rest der Dateien zu aktualisieren.&lt;br /&gt;
&lt;br /&gt;
Möchten Sie eine bestimmte Revsision eine Dateie haben, können Sie den &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt; Schalter benutzen. Neben der Revisions-Nummer akzeptiert -r eine Anzahl von weiteren Möglichkeiten:&lt;br /&gt;
  &lt;br /&gt;
* Die Revision-Nummer: Benutzen Sie beispielsweise -r 403819 um diese Version zu erhalten&lt;br /&gt;
* '''BASE''': Die Revision zu der Sie aktualisiert haben&lt;br /&gt;
* '''COMMITTED''': Die Revision an der eine Datei vor BASE zuletzt verändert wurde.&lt;br /&gt;
* '''PREV''': Die Revision des vorigen commits vor COMMITTED&lt;br /&gt;
* '''HEAD''': Die akuellste Revision die auf dem Server verfügbar ist&lt;br /&gt;
* '''{ date }''': Zwischen den geschwungenen Klammern kann ein Datum angegeben werden, damit die daran nähsten Änderungen gesucht werden&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-11-29T11:21:55Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Dateien ignorieren */ More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; Hauptunterverzeichnis ist dasjenige, in dem die Hauptentwicklung an KDE stattfindet. Was Sie hier finden, wird als nächstes als KDE und assoziierte Programme veröffentlicht. Hier finden Sie auch das &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; Modul, welches die Webpages rund um KDE beinhaltet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; ist unterteilt in folgende Unterverzeichnisse:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE selber, welches die nächste Veröffentlichung werden wird. Es besteht aus folgenden Modulen:&lt;br /&gt;
**'''kdelibs''' - KDE Hauptbibliotheken, die von allen KDE Programmen benutzt werden&lt;br /&gt;
**'''kdebase''' - KDE Basisprogramme, wie das KDE Control Center, Plasma (die Oberfläche) und Konqueror (der Web Browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility Dateien&lt;br /&gt;
**'''kdeadmin''' - KDE Administrationsprogramme&lt;br /&gt;
**'''kdeartwork''' - Bilder, Themen, Sounds und andere künstlerische Dateien&lt;br /&gt;
**'''kdebindings''' - Bindungen für andere Sprache außer C++&lt;br /&gt;
**'''kdeedu''' - Erzieherische und Wissenschaftliche Programme für KDE&lt;br /&gt;
**'''kdegames''' - KDE Spiele&lt;br /&gt;
**'''kdegraphics''' - KDE Graphikapplicationen&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimediaapplicationen&lt;br /&gt;
**'''kdenetwork''' - KDE Netzwerkapplicationen&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management Applicationen &lt;br /&gt;
**'''kdepimlibs''' - Biblotheken, die von KDE-PIM Applicationen benötigt werden.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit Applicationen&lt;br /&gt;
**'''kdetoys''' - KDE Spielzeug Applicationen&lt;br /&gt;
**'''kdeutils''' - Allgemeine KDE Werkzeuge&lt;br /&gt;
**'''kdevelop''' - Das KDevelop Programm&lt;br /&gt;
**'''kdevplatform''' - Die Entwicklerplatform auf der KDevelop basiert&lt;br /&gt;
**'''kdewebdev''' - Eine KDE Webentwicklungsapplikation&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Allgemeines admin/ Verzeichnis&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] Dateien&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der Inhalt von developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE Programme die sich außerhalb der Haupt KDE Veröffentlichungen aufhalten&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Vorübergehende Heimat für all die KDE Applikationen, von denen geglaubt wird, daß sie reif für eine Veröffentlichung sind. Von hier aus werden die Applikationen entweder nach &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; oder nach &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt; verschoben, sobald die größten Probleme ausgeräumt sind.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Unterstützende Programme und Bibliotheken für KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;Das KDE Office Paket, welches folgende Programme beinhaltet:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, das KDE build Programm&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für die &amp;quot;unstabilen&amp;quot; Module von KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der KDE Spielplatz: Applications die gerade entwickelt werden aber noch keine Veröffentlichungsqualität erreicht haben.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Zu Vereinfachung eine Kopie von  [http://www.trolltech.com/ Trolltechs] Qt Bibliothek, auf welcher KDE basiert.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice und ksvg Testfälle&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Die Valgrind Application, welche im KDE Repository betreut wird jedoch kein Teil von KDE selber ist. Neuere Versionen von Valgrind werden in einem eigenen Repository entwickelt. Das KDE Valgrind Modul beinhaltet nur Valgrind bis zur Version 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages für die KDE Site (und verwandte Sites). Schreibzugriff auf dieses Verzeichnis ist beschränkt.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die offiziellen Veröffentlichung von den Programmen die im KDE Repository verwaltet und entwickelt werden. Jede einzelne Applikation hat hier ein Unterverzeichnis, innerhalb von diesem finden Sie die Release-Nummern.&lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der Code für KDE 3.4.0 unter &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die Zweig-versionen von Applikationen nach einer Hauptveröffentlichung. &lt;br /&gt;
&lt;br /&gt;
Die meisten KDE Applikationen halten sich an die Philosophie, dass neue Features (ebenso wie neue Zeichneketten für den Benutzer) erst im nächsten Veröffentlichungszyklus &amp;amp;#8212; derjenige der in &amp;lt;tt&amp;gt;/trunkg/&amp;lt;/tt&amp;gt; entwickelt wird &amp;amp;#8212; einfließen. Fehlerbereinigungen werden jedoch auf alle Applikationen angewandt, auch nach einer Veröffentlichung.&lt;br /&gt;
&lt;br /&gt;
Um das zu bewerkstelligen, wird ein Zwei in dem Moment der Veröffentlichung erzeugt und zeigt damit den Status dieser Dateien zu diesem Zeitpunkt an. Fehlerbereinigungn werden dann in diese Dateien eingepflegt. Diese Zweige sind dann diejenigen die unter &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt; zu finden sind. &lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der KDE 3.4.x Zweig unter &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
Die Unterverzeichnisse die Sie in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; finden, sie die Unterverzeichnisse der Aplikationen wie &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. Sie finden hier auch ein &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
Unterverzeichnis, welches die offiziellen KDE Veröffentlichung beinhalten.&lt;br /&gt;
&lt;br /&gt;
Es gibt ein spezielles Unterverzeichnis in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; namens &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. Dieses Unterverzeichnis wird als &amp;quot;Arbeitszweig&amp;quot; berzeichnet und beinhaltet Zweige bei denen an neuen Features gearbeitet wird. Manchmal sind diese sehr experimentell. Arbeitszweige für mehrere Applikationen finden sich in &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, doch für einzelne Applikationen finden sich Arbeitszweige im jeweiligen Unterverzeichnis. Diese Entscheidung liegt bei den Entwicklern. &lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
Um entwas aus Subversion auszuchecken benutzt man das Unterkommando &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
'''WARNUNG:''' Wenn Sie trunk/KDE oder branches/KDE/foo auschecken werden Sie auch die komplette kde-i18n herunterladen!&lt;br /&gt;
&lt;br /&gt;
Angenommen Sie wollen nur KDevelop aus dem KDE Repository auschecken, würden Sie folgende Kommandos eingeben:&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
&lt;br /&gt;
CVS Benutzer die einen ssh Zugang besitzen, sollten das Protokoll svn+ssh,&lt;br /&gt;
CVS Benutzer, die einen Passwortzugang benutzen sollten das Protokoll https im folgenden benutzen.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
Um zu aktualisieren, benutzen Sie das &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; Unterkommando.&lt;br /&gt;
&lt;br /&gt;
Hier gibt es keinen Unterschied zu CVS: Sie wechseln in ihre ausgecheckte lokale Kopie (für diejenigen, für die das alles neu ist: die ausgecheckte Kopie sollte sich in Ihrem Heimatordner befinden) und geben ein &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; Kommando (oder kürzer &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
Um herauszufinden welche lokalen Dateien verändert wurden, haben die meisten unter CVS das Kommando cvs up aufgerufen und dann diejenigen Dateien gesucht, die mit einem '''M''' markiert waren. Das funktioniert unter svn nicht, daher müssen Sie das Kommando &amp;lt;tt&amp;gt;svn status&amp;lt;/tt&amp;gt; aufrufen, um den Status der Dateien zu ermitteln.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Um Änderungen hochzuladen ruft man, ähnlich wie bei CVS, die Unterkommandos &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (Kurzversion davon &amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt;) auf.&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Auf diese Weise wird &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; den in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; eingetragenen Texteditor aufrufen, damit Sie das Änderungsprotokoll ausfüllen können. Wenn Sie es vorziehen, können Sie &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; auch über die -m Option eine vollständige Mitteilung übergeben:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion speichert die zu ignorierenden Dateien für jedes Verzeichnis. Um diese Liste für das aktuelle Verzeichnis zu bearbeiten, rufen Sie einfach&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
auf. Damit wird der eingestellte Editor aufgerufen, in dem Sie die Namen der Dateien eintragen können, die ignoriert werden sollen, eine Datei pro Zeile. Wenn Sie fertig sind, einfach ein commit ausführen, damit die Dateien auf dem Server aktualisiert werden.&lt;br /&gt;
&lt;br /&gt;
Eine Menge Dateien wurden bei CVS mit Hilfe der globalen Ignorierliste ignoriert, diese Liste wird von SVN nicht unterstützt. Sie können auf svn 1.3 warten oder Sie müssen die Ignorierliste in die Sammelgruppe in ihrer {{path|~/.subversion/config}} einfügen (alle in einer Zeile):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-20T15:40:58Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Code Beispiele in APIDOX */  More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Die Grundlagen von apidox sind einfach und machen Spaß: Man schreibt einfach Kommentare in den Code, die erklären wofür dieser ist. Diese Kommetare sind fast das gleiche wie das, was man sowieso in die header des Codes schreiben muß, so ist das ganze also nicht so schwer. &lt;br /&gt;
&lt;br /&gt;
APIDOX werden in speziellen Kommentaren geschrieben. Diese Kommentare starten mit /** (Schrägstrich, Stern, Stern) -- und das ist es, was sie besonders macht. Der Rest des Kommentars ist einfacher Text, der den Teil des Programms beschreibt. Dieser Text wird vom Doxygen Prozessor interpretiert, damit dadurch passende Beschreibungen der Parameter und Rückgabewerte erfolgen kann. Doch die Dokumentation ist recht unkompliziert: Man schreibt einfach, was eine Methode tut innerhalb von /** und */, so wie folgendes Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für eine vernünftige apidox muß jedes &amp;quot;Ding&amp;quot; des Programms dokumentiert werden. &amp;quot;Dinge&amp;quot; sind hierbei Verzeichnisse, Dateien, Namensräume, Klassen, Methoden, Aufzählungen und Variablen. Man kann eventuell Dateien und Verzeichnisse auslassen und sich nur auf die letzteren Punkte konzentrieren. Komplette apidox sehen ungefähr so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wie man sieht, ist jede Schachtelungsebene der eben erwähnten &amp;quot;Dinge&amp;quot; mit einem Kommentar versehen -- Der Namensraum, die Klasse und die Methode. Private &amp;quot;Dinge&amp;quot; benötigen keine apidox, protected &amp;quot;Dinge&amp;quot; jedoch schon.  &lt;br /&gt;
&lt;br /&gt;
Es ist wichtig, jede einzelne Schachtelungsebene zu dokumentieren, denn läßt man einen Ebene aus, ignoriert Doxygen die inneren ebenso und man findet diese nicht mehr wieder. Angenommen man würde im obigen Beispiel die Klassendokumentation weglassen, dann würde die Dokumentation für die Methode Socket() ebenfalls verschwinden. Das ist eine der typischen Fallen beim Schreiben von apidox.  &lt;br /&gt;
&lt;br /&gt;
Und wenn man nur eine Erklärung für jeden Teil seines Programmes schreibt, hat man schon einen großen Teil des Weges zu einer kompletten apidox hinter sich gelassen. Diese Erklärungen zu schreiben macht das Programm einfacher für andere Entwickler zu verstehen und zeigt einem oft schon sub-optimale Designs oder Namenswahlen. Auf diese Art gewinnen beide Seiten.  &lt;br /&gt;
&lt;br /&gt;
Man findet in der Liste von unterstützen Tags auch Beispiele für ausgefallenere apidox -- Erklärung von Parametern oder wie man die apidox mit Beispielen und Personendaten versieht. Es lohnt sich auch nachzusehen, wie man apidox aktiviert, doch es ist auch möglich die Arbeit aufzuteilen: Du schreibst die apidox selber und fragst den Originalautor (mailto:groot@kde.org), diese für dein Modul zu aktivieren. Er verspricht (zunmindest in der englischsprachigen Originalversion) das dann zu tun.  &lt;br /&gt;
 &lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
Wenn mann neuen Code schreibt und dabei apidox verwenden möchte, sollte man am besten KDevelop benutzen. Vernünftig konfiguriert kann dieses automatisch ein Grundgerüst für apidox einfügen, man muß dann nur noch die eigentlichen Beschreibungen einfügen. Und man muß sich nicht mehr mit apidox kommandos rumärgern. &lt;br /&gt;
&lt;br /&gt;
Wenn man sich nicht in dieser günstigen Lage befindet, sollte die folgende Checkliste einen durch die schlimmsten Untiefen beim Schreiben von apidox führen:&lt;br /&gt;
&lt;br /&gt;
'''1. Schreibe die apidox direkt mit dem Code zusammen'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Dokumentierte deine Header vollständig'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
Es kann nützlich sein, Beispielcode zur APIDOX einer Klasse hinzuzufügen. Sehr nützlich ist es auf jeden Fall für Leser, die sich fragen, wie man eine Klasse genau zu benutzen hat. Die meisten Klassen in {{path|kdelibs/kdecore}} haben Beispielcode.&lt;br /&gt;
&lt;br /&gt;
Ein Weg, um Beispielcode zu schreiben ist es, @code und @endcode um den Block des Beispielcodes in den Doxygenkommentaren selber zu legen, wie im folgenden Beispiel:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Auf diese Art wird es in den meisten Beispielen in {{path|kdelibs}} gemacht. Das funktioniert auch ganz gut, man kann sich bei den Beispielen aufs wesentliche beschränken.&lt;br /&gt;
&lt;br /&gt;
Ein wichtiges Problem dieser Herangehensweise um Beispielcode zu schreiben ist es, dass der Code niemals geprüft wird, ob er wirklich funktioniert. Die meisten Codebeispiele sind so gepackt, dass es schwer ist, diese in einen funktionsfähigen Code umzuschreiben, der wirklich kompiliert und läuft.&lt;br /&gt;
&lt;br /&gt;
Um dieses Problem zu lösen, kann man ''richtigen Code'' schreiben, der wirklich kompiliert (als Teil dr Test-Suite für den Code, den man sowieso hat) und exakt beschreibt, wie eine Klasse in einem richtigen Programm benutzt werden soll. Man muß jedoch nicht den gesamten Code in die APIDOX übernehmen, sondern braucht nur die interessanten Teile zu markieren. Um das zu bewerkstelligen, wird eine Datei in das &amp;lt;tt&amp;gt;tests&amp;lt;/tt&amp;gt; Unterverzeichnis eingefügt. Dann kann man das Doxygen @include-Tag benutzen, um den Code dieser Datei in die API Dokumentation zu übernehmen.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-01T15:39:40Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Die Grundlagen von apidox sind einfach und machen Spaß: Man schreibt einfach Kommentare in den Code, die erklären wofür dieser ist. Diese Kommetare sind fast das gleiche wie das, was man sowieso in die header des Codes schreiben muß, so ist das ganze also nicht so schwer. &lt;br /&gt;
&lt;br /&gt;
APIDOX werden in speziellen Kommentaren geschrieben. Diese Kommentare starten mit /** (Schrägstrich, Stern, Stern) -- und das ist es, was sie besonders macht. Der Rest des Kommentars ist einfacher Text, der den Teil des Programms beschreibt. Dieser Text wird vom Doxygen Prozessor interpretiert, damit dadurch passende Beschreibungen der Parameter und Rückgabewerte erfolgen kann. Doch die Dokumentation ist recht unkompliziert: Man schreibt einfach, was eine Methode tut innerhalb von /** und */, so wie folgendes Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Für eine vernünftige apidox muß jedes &amp;quot;Ding&amp;quot; des Programms dokumentiert werden. &amp;quot;Dinge&amp;quot; sind hierbei Verzeichnisse, Dateien, Namensräume, Klassen, Methoden, Aufzählungen und Variablen. Man kann eventuell Dateien und Verzeichnisse auslassen und sich nur auf die letzteren Punkte konzentrieren. Komplette apidox sehen ungefähr so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Wie man sieht, ist jede Schachtelungsebene der eben erwähnten &amp;quot;Dinge&amp;quot; mit einem Kommentar versehen -- Der Namensraum, die Klasse und die Methode. Private &amp;quot;Dinge&amp;quot; benötigen keine apidox, protected &amp;quot;Dinge&amp;quot; jedoch schon.  &lt;br /&gt;
&lt;br /&gt;
Es ist wichtig, jede einzelne Schachtelungsebene zu dokumentieren, denn läßt man einen Ebene aus, ignoriert Doxygen die inneren ebenso und man findet diese nicht mehr wieder. Angenommen man würde im obigen Beispiel die Klassendokumentation weglassen, dann würde die Dokumentation für die Methode Socket() ebenfalls verschwinden. Das ist eine der typischen Fallen beim Schreiben von apidox.  &lt;br /&gt;
&lt;br /&gt;
Und wenn man nur eine Erklärung für jeden Teil seines Programmes schreibt, hat man schon einen großen Teil des Weges zu einer kompletten apidox hinter sich gelassen. Diese Erklärungen zu schreiben macht das Programm einfacher für andere Entwickler zu verstehen und zeigt einem oft schon sub-optimale Designs oder Namenswahlen. Auf diese Art gewinnen beide Seiten.  &lt;br /&gt;
&lt;br /&gt;
Man findet in der Liste von unterstützen Tags auch Beispiele für ausgefallenere apidox -- Erklärung von Parametern oder wie man die apidox mit Beispielen und Personendaten versieht. Es lohnt sich auch nachzusehen, wie man apidox aktiviert, doch es ist auch möglich die Arbeit aufzuteilen: Du schreibst die apidox selber und fragst den Originalautor (mailto:groot@kde.org), diese für dein Modul zu aktivieren. Er verspricht (zunmindest in der englischsprachigen Originalversion) das dann zu tun.  &lt;br /&gt;
 &lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
Wenn mann neuen Code schreibt und dabei apidox verwenden möchte, sollte man am besten KDevelop benutzen. Vernünftig konfiguriert kann dieses automatisch ein Grundgerüst für apidox einfügen, man muß dann nur noch die eigentlichen Beschreibungen einfügen. Und man muß sich nicht mehr mit apidox kommandos rumärgern. &lt;br /&gt;
&lt;br /&gt;
Wenn man sich nicht in dieser günstigen Lage befindet, sollte die folgende Checkliste einen durch die schlimmsten Untiefen beim Schreiben von apidox führen:&lt;br /&gt;
&lt;br /&gt;
'''1. Schreibe die apidox direkt mit dem Code zusammen'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Dokumentierte deine Header vollständig'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
It can be useful to put example code in the APIDOX for a class.&lt;br /&gt;
Very useful, in fact, for the reader who is wondering&lt;br /&gt;
how exactly to use the class in a straightforward way.&lt;br /&gt;
Most classes in {{path|kdelibs/kdecore}} have example code.&lt;br /&gt;
&lt;br /&gt;
One way to write example code is to use @code and @endcode around&lt;br /&gt;
blocks of example code in the Doxygen comments themselves, like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is how most of the examples in {{path|kdelibs}}&lt;br /&gt;
are done, actually. It works reasonably well, you can pare the&lt;br /&gt;
example down to something really minimal and leave out all the&lt;br /&gt;
boilerplate.&lt;br /&gt;
&lt;br /&gt;
An important drawback of this approach to writing example code is that&lt;br /&gt;
the code is never checked to see if it actually works.&lt;br /&gt;
The code is also ''so'' terse, usually, that it's hard&lt;br /&gt;
to expand into a complete example that actually compiles and runs.&lt;br /&gt;
&lt;br /&gt;
To solve this problem, you can write ''real code'' that&lt;br /&gt;
actually compiles (as part of the test suite for the code&lt;br /&gt;
that you have anyway) and that illustrates exactly &lt;br /&gt;
how to use the class under consideration in an actual program.&lt;br /&gt;
Better yet, you do not need to include ''all'' the code&lt;br /&gt;
in the APIDOX, just the interesting bits.&lt;br /&gt;
The way to do this is to put the code in a file in the&lt;br /&gt;
&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt; subdirectory of your code.&lt;br /&gt;
Then use Doxygen's @include tag to include the&lt;br /&gt;
code from that file into the API documentation.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-01T11:20:50Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Die eigentliche Beispieldokumentation auf dieser Seite wird nicht übersetzt, da API Dokumentation in der Regel auf englisch verfasst werden, um eine internationale Mitarbeit zu ermöglichen}}&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX werden durch das [http://www.doxygen.org Doxygen] Dokumentationswerkzeug verarbeitet. Dieses Werkzeug liest den Quellcode der Applikation (oder Bibliothek) und erzeugt schön formatierte Dokumentation daraus. Es gibt ein gutes [http://www.stack.nl/~dimitri/doxygen/manual.html Referenz Handbuch (auf englisch)] -- doch für die Grundlagen muß dieses nicht vollständig gelesen werden.&lt;br /&gt;
&lt;br /&gt;
{{Tip|Doxygen muß für die Arbeit an apidox der Applikation nicht installiert sein. Alle paar Stunden erzeugt das [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] apidox für alle bekannten KDE Module. Logfiles und die eigentlichen Apidox werden ebenfalls bereitgestellt, um Fehlermeldungen zu entdecken und diese zu beheben. Das ist zwar nicht die schellste Methode apidox zu schreiben und zu korrigieren, doch es erledigt diese Aufgabe. Ein paar Stunden Arbeit am Tag, um an der apidox zu arbeiten, reichen aus.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|Hast du Doxygen installiert und möchtest die apidox erzeugen, benutze das kdedoxygen.sh Skript wie es in [[Development/Tools/apidox|apidox (englisch)]] beschrieben ist.}}&lt;br /&gt;
&lt;br /&gt;
Basic apidox are fun and simple: you write comments in your code explaining what things are supposed to be for. These comments are nearly indistinguishable from stuff you would be writing in the headers of your code ''anyway'', so that's not hard to do.&lt;br /&gt;
&lt;br /&gt;
APIDOX are written in special comments. These comments start with /** (slash, star, star) -- that's what makes them special. The rest of the content of the comment is just plain text describing a part of your program. The plain text is interpreted by the Doxygen processor, so that you can write accurate descriptions of parameters, return types, and do some basic text markup. But documentation can be very straighforward: just write down what a method does, surrounded by /** and */, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For proper apidox, you need to document every &amp;quot;thing&amp;quot; in your program. &amp;quot;Things&amp;quot; here are directories, files, namespaces, classes, methods, enums, and member variables. You can actually leave out files and directories, and concentrate on the latter. Complete apidox looks something like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can see here that each nesting level of &amp;quot;things&amp;quot; is documented with a comment -- the namespace, the class and the method. Things that are private do not need apidox, but things that are protected do.&lt;br /&gt;
&lt;br /&gt;
It is important to document each level of nesting, because if you leave one level out, Doxygen will ignore the documentation in inner nesting levels, and you will be left wondering where it has gone. For instance, if we leave out the class documentation, then the method documentation for Socket() will vanish as well. This is one of the common pitfalls to writing apidox.&lt;br /&gt;
&lt;br /&gt;
If you just do this -- write an explanation for every part of your program -- then you're already a long way on the road to having complete apidox. Writing all those explanations makes your program more accessible to other developers -- and often shows you where the design or choice of names is sub-optimal. So it's a win for you both ways.&lt;br /&gt;
 &lt;br /&gt;
You can consult the list of supported tags for examples of more fancy apidox -- explaining parameters, for instance, and annotating the apidox with credits and examples. It's also worthwhile to take a look at the section on enabling apidox, but it's also fine to divide the work: you write the apidox themselves, and ask me (mailto:groot@kde.org) to enable apidox generation for your module. And I will.&lt;br /&gt;
&lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
If you are writing new code and want to write apidox, use KDevelop. Really. Properly configured, it can automatically set up all the skeletons for apidox that you need, and what you do is write the descriptions. No messing with apidox commands.&lt;br /&gt;
&lt;br /&gt;
If you're not in that fortunate position, the following little checklist should get you through the worst of writing apidox. &lt;br /&gt;
&lt;br /&gt;
'''1. Write apidox as you code'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Document your headers completely'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
It can be useful to put example code in the APIDOX for a class.&lt;br /&gt;
Very useful, in fact, for the reader who is wondering&lt;br /&gt;
how exactly to use the class in a straightforward way.&lt;br /&gt;
Most classes in {{path|kdelibs/kdecore}} have example code.&lt;br /&gt;
&lt;br /&gt;
One way to write example code is to use @code and @endcode around&lt;br /&gt;
blocks of example code in the Doxygen comments themselves, like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is how most of the examples in {{path|kdelibs}}&lt;br /&gt;
are done, actually. It works reasonably well, you can pare the&lt;br /&gt;
example down to something really minimal and leave out all the&lt;br /&gt;
boilerplate.&lt;br /&gt;
&lt;br /&gt;
An important drawback of this approach to writing example code is that&lt;br /&gt;
the code is never checked to see if it actually works.&lt;br /&gt;
The code is also ''so'' terse, usually, that it's hard&lt;br /&gt;
to expand into a complete example that actually compiles and runs.&lt;br /&gt;
&lt;br /&gt;
To solve this problem, you can write ''real code'' that&lt;br /&gt;
actually compiles (as part of the test suite for the code&lt;br /&gt;
that you have anyway) and that illustrates exactly &lt;br /&gt;
how to use the class under consideration in an actual program.&lt;br /&gt;
Better yet, you do not need to include ''all'' the code&lt;br /&gt;
in the APIDOX, just the interesting bits.&lt;br /&gt;
The way to do this is to put the code in a file in the&lt;br /&gt;
&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt; subdirectory of your code.&lt;br /&gt;
Then use Doxygen's @include tag to include the&lt;br /&gt;
code from that file into the API documentation.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-01T11:05:02Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') Dokumentation''' ist die Dokumentation eines ''Programmes'' und seiner Schnittstellen. Durch Dokumentation wird einem Entwickler, der mit oder an dem Programm arbeitet, erklärt, wie Dinge funktionieren und wie und welche Methoden aufzurufen sind.  &lt;br /&gt;
&lt;br /&gt;
API Dokumentation wird machmal auch API Referenz Handbuch (API reference manual) genannt. Es muß nicht ''nur'' ein Referenz Handbuch sein, obwohl es umfangreiches zusätzliches Material, wie Anleitungen, Zeitleisten, etc., enthalten kann. Auf dieser Seite wird alles Material welches die API eines Codes dokumentiert und erklärt &amp;quot;apidox&amp;quot; genannt. &lt;br /&gt;
&lt;br /&gt;
Gute apidox benötigt etwas Mühe zum schreiben -- doch sicherlich weniger Mühe als gute ''Benutzer'' Dokumentation, da du als Entwickler für andere Entwickler schreibst und eklärst wie Code funktioniert und was er tun soll. So dein Publikum ist bereit damit zu arbeiten. Der Vorteil von apidox zeigt sich, wenn jemand anderes (oder sogar du selbst einige Monate später) den Code (wieder)verwenden oder erweitern möchte. Gute apidox bedeutet, dass jemand neues kommen kann, den Code schnell versteht und nützliche Patches erstellen kann. Gerade für Bibliotheken kann apidox es ermöglichen, diese wie eine Black Box zu benutzen (und so sollte es auch sein), da die benötigte Dokumentation vorliegt und die Dokumentation sich nicht in den tiefen des (vielleicht gar nicht vorliegenden) C codes befindet.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX are processed by the [http://www.doxygen.org Doxygen] documentation tool. This tool reads source code for your application (or library) and produces nicely formatted documentation from it. There is a good [http://www.stack.nl/~dimitri/doxygen/manual.html reference manual] available -- but let's hope to make it unnecessary to read, for basic use anyway.&lt;br /&gt;
&lt;br /&gt;
{{Tip|You don't even need to have Doxygen installed to work on apidox for your application. Every few hours, the [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] compiles apidox for all of the KDE modules we know about. Logfiles are kept and you can see your apidox on the site, or read the error messages and fix those. ...it might not be the fastest way to write and fix apidox, but it gets the job done, and if you spend just an hour at the end of the day writing some apidox, it's sufficiently useful.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|If you do have Doxygen installed and want to build the apidox, use the kdedoxygen.sh script as described in [[Development/Tools/apidox|apidox]].}}&lt;br /&gt;
&lt;br /&gt;
Basic apidox are fun and simple: you write comments in your code explaining what things are supposed to be for. These comments are nearly indistinguishable from stuff you would be writing in the headers of your code ''anyway'', so that's not hard to do.&lt;br /&gt;
&lt;br /&gt;
APIDOX are written in special comments. These comments start with /** (slash, star, star) -- that's what makes them special. The rest of the content of the comment is just plain text describing a part of your program. The plain text is interpreted by the Doxygen processor, so that you can write accurate descriptions of parameters, return types, and do some basic text markup. But documentation can be very straighforward: just write down what a method does, surrounded by /** and */, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For proper apidox, you need to document every &amp;quot;thing&amp;quot; in your program. &amp;quot;Things&amp;quot; here are directories, files, namespaces, classes, methods, enums, and member variables. You can actually leave out files and directories, and concentrate on the latter. Complete apidox looks something like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can see here that each nesting level of &amp;quot;things&amp;quot; is documented with a comment -- the namespace, the class and the method. Things that are private do not need apidox, but things that are protected do.&lt;br /&gt;
&lt;br /&gt;
It is important to document each level of nesting, because if you leave one level out, Doxygen will ignore the documentation in inner nesting levels, and you will be left wondering where it has gone. For instance, if we leave out the class documentation, then the method documentation for Socket() will vanish as well. This is one of the common pitfalls to writing apidox.&lt;br /&gt;
&lt;br /&gt;
If you just do this -- write an explanation for every part of your program -- then you're already a long way on the road to having complete apidox. Writing all those explanations makes your program more accessible to other developers -- and often shows you where the design or choice of names is sub-optimal. So it's a win for you both ways.&lt;br /&gt;
 &lt;br /&gt;
You can consult the list of supported tags for examples of more fancy apidox -- explaining parameters, for instance, and annotating the apidox with credits and examples. It's also worthwhile to take a look at the section on enabling apidox, but it's also fine to divide the work: you write the apidox themselves, and ask me (mailto:groot@kde.org) to enable apidox generation for your module. And I will.&lt;br /&gt;
&lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
If you are writing new code and want to write apidox, use KDevelop. Really. Properly configured, it can automatically set up all the skeletons for apidox that you need, and what you do is write the descriptions. No messing with apidox commands.&lt;br /&gt;
&lt;br /&gt;
If you're not in that fortunate position, the following little checklist should get you through the worst of writing apidox. &lt;br /&gt;
&lt;br /&gt;
'''1. Write apidox as you code'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Document your headers completely'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
It can be useful to put example code in the APIDOX for a class.&lt;br /&gt;
Very useful, in fact, for the reader who is wondering&lt;br /&gt;
how exactly to use the class in a straightforward way.&lt;br /&gt;
Most classes in {{path|kdelibs/kdecore}} have example code.&lt;br /&gt;
&lt;br /&gt;
One way to write example code is to use @code and @endcode around&lt;br /&gt;
blocks of example code in the Doxygen comments themselves, like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is how most of the examples in {{path|kdelibs}}&lt;br /&gt;
are done, actually. It works reasonably well, you can pare the&lt;br /&gt;
example down to something really minimal and leave out all the&lt;br /&gt;
boilerplate.&lt;br /&gt;
&lt;br /&gt;
An important drawback of this approach to writing example code is that&lt;br /&gt;
the code is never checked to see if it actually works.&lt;br /&gt;
The code is also ''so'' terse, usually, that it's hard&lt;br /&gt;
to expand into a complete example that actually compiles and runs.&lt;br /&gt;
&lt;br /&gt;
To solve this problem, you can write ''real code'' that&lt;br /&gt;
actually compiles (as part of the test suite for the code&lt;br /&gt;
that you have anyway) and that illustrates exactly &lt;br /&gt;
how to use the class under consideration in an actual program.&lt;br /&gt;
Better yet, you do not need to include ''all'' the code&lt;br /&gt;
in the APIDOX, just the interesting bits.&lt;br /&gt;
The way to do this is to put the code in a file in the&lt;br /&gt;
&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt; subdirectory of your code.&lt;br /&gt;
Then use Doxygen's @include tag to include the&lt;br /&gt;
code from that file into the API documentation.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-01T10:48:12Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Vorwort */ translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') documentation''' is documentation that applies to ''a program'' and its interfaces. It is documentation that explains to a developer who is going to work with the program, or a developer who is going to work on a program, how things work and what methods are there to call.&lt;br /&gt;
&lt;br /&gt;
API documentation is sometimes called an API reference manual. It needn't ''just'' be a reference manual, though, there can be extensive additional material, like tutorials, histories, etc. In this page, we will refer to all the material that documents and explains the API of a piece of code as &amp;quot;apidox.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Good apidox take some effort to write -- but I would say less than good ''user'' documentation, since you as a developer are writing for another developer, and explaining how code works and what it is supposed to do. So your audience is clear to start with. The benefits of apidox come when someone else (or maybe even you several months later) needs to (re)use the code, or extend it. Good apidox means that someone new can show up, understand your code, and produce meaningful patches (that is, ''help'') all the more quickly. Especially for libraries, good apidox make the library usable as a black box (and that's how they should be) because all the needed documentation is available in the apidox and not hidden in the (perhaps inaccessible) C code.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
Mit APIDOX wird es anderen Entwicklern ermöglicht, auf ein Programm zuzugreifen. Sie sind nicht unbedingt notwenig doch sie helfen neuen Leuten, die an dem Programm arebeiten möchten oder den Code ohne große Änderungen wiederverwenden möchten, sicherlich eine Menge. &lt;br /&gt;
&lt;br /&gt;
Ein Blick auf [http://doc.trolltech.com/latest/ die Qt Dokumentation (englisch)] ermöglicht es, einen Eindruck von guter apidox Dokumentation zu bekommen. Dort sieht man eine Stilkonsistenz, die sich durch die gesamte Dokumentation zieht. Dadurch kann man eine Menge über Qt lernen, nur indem man die Dokumentation liest. Es ist nicht notwendig, die Anleitungsprogramme auszuführen oder den Quellcode zu lesen um herauszufinden, was ein Parameter in einer bestimmten Methode einer Bibliothek macht. Es wird alles bereits erläutert.  &lt;br /&gt;
&lt;br /&gt;
Apidox zu schreiben besteht aus zwei Teilen. Der erste Teil ist technischer Natur: Man muß den Code verstehen, der dokumentiert werden soll, oder zumindest wissen, was er tun soll und wie er benutzt werden muss. Der andere Teil ist reine Disziplin: apidox ist am nützlichsten, wenn es sorgfältig und ausführlich benutzt wird.   &lt;br /&gt;
&lt;br /&gt;
Dieses Dokument versucht den apidox Prozess nicht zu ausführlich werden zu lassen, indem es einige dirkekte Tips gibt, wie man apidox schreibt. Es gibt dann doch die [[Policies/Library Documentation Policy|library apidox policies (englisch)]], die sehr viel strenger sind. Es schadet nicht, auch dort mal einen Blick reinzuwerfen.&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX are processed by the [http://www.doxygen.org Doxygen] documentation tool. This tool reads source code for your application (or library) and produces nicely formatted documentation from it. There is a good [http://www.stack.nl/~dimitri/doxygen/manual.html reference manual] available -- but let's hope to make it unnecessary to read, for basic use anyway.&lt;br /&gt;
&lt;br /&gt;
{{Tip|You don't even need to have Doxygen installed to work on apidox for your application. Every few hours, the [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] compiles apidox for all of the KDE modules we know about. Logfiles are kept and you can see your apidox on the site, or read the error messages and fix those. ...it might not be the fastest way to write and fix apidox, but it gets the job done, and if you spend just an hour at the end of the day writing some apidox, it's sufficiently useful.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|If you do have Doxygen installed and want to build the apidox, use the kdedoxygen.sh script as described in [[Development/Tools/apidox|apidox]].}}&lt;br /&gt;
&lt;br /&gt;
Basic apidox are fun and simple: you write comments in your code explaining what things are supposed to be for. These comments are nearly indistinguishable from stuff you would be writing in the headers of your code ''anyway'', so that's not hard to do.&lt;br /&gt;
&lt;br /&gt;
APIDOX are written in special comments. These comments start with /** (slash, star, star) -- that's what makes them special. The rest of the content of the comment is just plain text describing a part of your program. The plain text is interpreted by the Doxygen processor, so that you can write accurate descriptions of parameters, return types, and do some basic text markup. But documentation can be very straighforward: just write down what a method does, surrounded by /** and */, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For proper apidox, you need to document every &amp;quot;thing&amp;quot; in your program. &amp;quot;Things&amp;quot; here are directories, files, namespaces, classes, methods, enums, and member variables. You can actually leave out files and directories, and concentrate on the latter. Complete apidox looks something like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can see here that each nesting level of &amp;quot;things&amp;quot; is documented with a comment -- the namespace, the class and the method. Things that are private do not need apidox, but things that are protected do.&lt;br /&gt;
&lt;br /&gt;
It is important to document each level of nesting, because if you leave one level out, Doxygen will ignore the documentation in inner nesting levels, and you will be left wondering where it has gone. For instance, if we leave out the class documentation, then the method documentation for Socket() will vanish as well. This is one of the common pitfalls to writing apidox.&lt;br /&gt;
&lt;br /&gt;
If you just do this -- write an explanation for every part of your program -- then you're already a long way on the road to having complete apidox. Writing all those explanations makes your program more accessible to other developers -- and often shows you where the design or choice of names is sub-optimal. So it's a win for you both ways.&lt;br /&gt;
 &lt;br /&gt;
You can consult the list of supported tags for examples of more fancy apidox -- explaining parameters, for instance, and annotating the apidox with credits and examples. It's also worthwhile to take a look at the section on enabling apidox, but it's also fine to divide the work: you write the apidox themselves, and ask me (mailto:groot@kde.org) to enable apidox generation for your module. And I will.&lt;br /&gt;
&lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
If you are writing new code and want to write apidox, use KDevelop. Really. Properly configured, it can automatically set up all the skeletons for apidox that you need, and what you do is write the descriptions. No messing with apidox commands.&lt;br /&gt;
&lt;br /&gt;
If you're not in that fortunate position, the following little checklist should get you through the worst of writing apidox. &lt;br /&gt;
&lt;br /&gt;
'''1. Write apidox as you code'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Document your headers completely'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
It can be useful to put example code in the APIDOX for a class.&lt;br /&gt;
Very useful, in fact, for the reader who is wondering&lt;br /&gt;
how exactly to use the class in a straightforward way.&lt;br /&gt;
Most classes in {{path|kdelibs/kdecore}} have example code.&lt;br /&gt;
&lt;br /&gt;
One way to write example code is to use @code and @endcode around&lt;br /&gt;
blocks of example code in the Doxygen comments themselves, like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is how most of the examples in {{path|kdelibs}}&lt;br /&gt;
are done, actually. It works reasonably well, you can pare the&lt;br /&gt;
example down to something really minimal and leave out all the&lt;br /&gt;
boilerplate.&lt;br /&gt;
&lt;br /&gt;
An important drawback of this approach to writing example code is that&lt;br /&gt;
the code is never checked to see if it actually works.&lt;br /&gt;
The code is also ''so'' terse, usually, that it's hard&lt;br /&gt;
to expand into a complete example that actually compiles and runs.&lt;br /&gt;
&lt;br /&gt;
To solve this problem, you can write ''real code'' that&lt;br /&gt;
actually compiles (as part of the test suite for the code&lt;br /&gt;
that you have anyway) and that illustrates exactly &lt;br /&gt;
how to use the class under consideration in an actual program.&lt;br /&gt;
Better yet, you do not need to include ''all'' the code&lt;br /&gt;
in the APIDOX, just the interesting bits.&lt;br /&gt;
The way to do this is to put the code in a file in the&lt;br /&gt;
&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt; subdirectory of your code.&lt;br /&gt;
Then use Doxygen's @include tag to include the&lt;br /&gt;
code from that file into the API documentation.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)</id>
		<title>Development/Tutorials/API Documentation (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/API_Documentation_(de)"/>
				<updated>2008-11-01T10:31:59Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and first little translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/API Documentation}}&lt;br /&gt;
__TOC__&lt;br /&gt;
{{Box|Definition|&lt;br /&gt;
'''API (''Application Programming Interface'') documentation''' is documentation that applies to ''a program'' and its interfaces. It is documentation that explains to a developer who is going to work with the program, or a developer who is going to work on a program, how things work and what methods are there to call.&lt;br /&gt;
&lt;br /&gt;
API documentation is sometimes called an API reference manual. It needn't ''just'' be a reference manual, though, there can be extensive additional material, like tutorials, histories, etc. In this page, we will refer to all the material that documents and explains the API of a piece of code as &amp;quot;apidox.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
Good apidox take some effort to write -- but I would say less than good ''user'' documentation, since you as a developer are writing for another developer, and explaining how code works and what it is supposed to do. So your audience is clear to start with. The benefits of apidox come when someone else (or maybe even you several months later) needs to (re)use the code, or extend it. Good apidox means that someone new can show up, understand your code, and produce meaningful patches (that is, ''help'') all the more quickly. Especially for libraries, good apidox make the library usable as a black box (and that's how they should be) because all the needed documentation is available in the apidox and not hidden in the (perhaps inaccessible) C code.|100%}}&lt;br /&gt;
&lt;br /&gt;
== Vorwort ==&lt;br /&gt;
&lt;br /&gt;
APIDOX are what make a program accessible to other contributors. They are not essential, but they certainly help a great deal for new people who want to work on your code, or better yet, re-use it elsewhere with a minimum of modification.&lt;br /&gt;
&lt;br /&gt;
Look at the [http://doc.trolltech.com/latest/ Qt documentation] to get a feeling of what good apidox look like. There is a consistency of style, a thoroughness which permeates all the documentation. It is possible to learn a lot about Qt just from reading the documentation. You do not necessarily need to run the tutorial programs or read the source code of the library to find out what a parameter flags does in some method of the library. It is all spelled out for you. &lt;br /&gt;
&lt;br /&gt;
Writing apidox is a two-part process. One part is technical: you need to understand the code you are documenting -- or at least know what it is supposed to do and how it is meant to be used. The other part is plain discipline: apidox are most useful when they are exhaustive.&lt;br /&gt;
&lt;br /&gt;
This document is going to try to prevent the apidox process from becoming exhausting, by giving straightforward tips about how to write apidox. There are also the [[Policies/Library Documentation Policy|library apidox policies]], which are much stricter, which provide measurable properties that apidox must adhere to. It does not hurt to glance at them now.&lt;br /&gt;
&lt;br /&gt;
== APIDOX Basics ==&lt;br /&gt;
&lt;br /&gt;
APIDOX are processed by the [http://www.doxygen.org Doxygen] documentation tool. This tool reads source code for your application (or library) and produces nicely formatted documentation from it. There is a good [http://www.stack.nl/~dimitri/doxygen/manual.html reference manual] available -- but let's hope to make it unnecessary to read, for basic use anyway.&lt;br /&gt;
&lt;br /&gt;
{{Tip|You don't even need to have Doxygen installed to work on apidox for your application. Every few hours, the [http://www.englishbreakfastnetwork.org/ EnglishBreakfastNetwork] compiles apidox for all of the KDE modules we know about. Logfiles are kept and you can see your apidox on the site, or read the error messages and fix those. ...it might not be the fastest way to write and fix apidox, but it gets the job done, and if you spend just an hour at the end of the day writing some apidox, it's sufficiently useful.}}&lt;br /&gt;
&lt;br /&gt;
{{Tip|If you do have Doxygen installed and want to build the apidox, use the kdedoxygen.sh script as described in [[Development/Tools/apidox|apidox]].}}&lt;br /&gt;
&lt;br /&gt;
Basic apidox are fun and simple: you write comments in your code explaining what things are supposed to be for. These comments are nearly indistinguishable from stuff you would be writing in the headers of your code ''anyway'', so that's not hard to do.&lt;br /&gt;
&lt;br /&gt;
APIDOX are written in special comments. These comments start with /** (slash, star, star) -- that's what makes them special. The rest of the content of the comment is just plain text describing a part of your program. The plain text is interpreted by the Doxygen processor, so that you can write accurate descriptions of parameters, return types, and do some basic text markup. But documentation can be very straighforward: just write down what a method does, surrounded by /** and */, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method increases the sexyness of Kontact and should as&lt;br /&gt;
 * such be called whenever possible (i.e. instead of having idle&lt;br /&gt;
 * time, you might think of calling this method and helping&lt;br /&gt;
 * Kontact gain even more popularity). You might even insert it&lt;br /&gt;
 * into your own event loop to ensure it is called as often as&lt;br /&gt;
 * possible. If these calls decrease the number of new features,&lt;br /&gt;
 * it's still no problem to call it. &lt;br /&gt;
 */&lt;br /&gt;
void incSexyness(KInstance *instance);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
For proper apidox, you need to document every &amp;quot;thing&amp;quot; in your program. &amp;quot;Things&amp;quot; here are directories, files, namespaces, classes, methods, enums, and member variables. You can actually leave out files and directories, and concentrate on the latter. Complete apidox looks something like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Namespace for KDE network-related classes */&lt;br /&gt;
namespace KDENetwork {&lt;br /&gt;
  /** Wrapper for a TCP/IP socket */&lt;br /&gt;
  class Socket {&lt;br /&gt;
  public:&lt;br /&gt;
    /** Constructor. Calls listen() on some random high port. */&lt;br /&gt;
    Socket();&lt;br /&gt;
  private:&lt;br /&gt;
    int fd;&lt;br /&gt;
  };&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You can see here that each nesting level of &amp;quot;things&amp;quot; is documented with a comment -- the namespace, the class and the method. Things that are private do not need apidox, but things that are protected do.&lt;br /&gt;
&lt;br /&gt;
It is important to document each level of nesting, because if you leave one level out, Doxygen will ignore the documentation in inner nesting levels, and you will be left wondering where it has gone. For instance, if we leave out the class documentation, then the method documentation for Socket() will vanish as well. This is one of the common pitfalls to writing apidox.&lt;br /&gt;
&lt;br /&gt;
If you just do this -- write an explanation for every part of your program -- then you're already a long way on the road to having complete apidox. Writing all those explanations makes your program more accessible to other developers -- and often shows you where the design or choice of names is sub-optimal. So it's a win for you both ways.&lt;br /&gt;
 &lt;br /&gt;
You can consult the list of supported tags for examples of more fancy apidox -- explaining parameters, for instance, and annotating the apidox with credits and examples. It's also worthwhile to take a look at the section on enabling apidox, but it's also fine to divide the work: you write the apidox themselves, and ask me (mailto:groot@kde.org) to enable apidox generation for your module. And I will.&lt;br /&gt;
&lt;br /&gt;
== APIDOX in neuem Code schreiben ==&lt;br /&gt;
&lt;br /&gt;
If you are writing new code and want to write apidox, use KDevelop. Really. Properly configured, it can automatically set up all the skeletons for apidox that you need, and what you do is write the descriptions. No messing with apidox commands.&lt;br /&gt;
&lt;br /&gt;
If you're not in that fortunate position, the following little checklist should get you through the worst of writing apidox. &lt;br /&gt;
&lt;br /&gt;
'''1. Write apidox as you code'''&lt;br /&gt;
&lt;br /&gt;
The discipline it takes to write down the apidox for function foo() now as you are thinking of foo() and what it needs to do more than compensates the effort later where you have to remember what foo() was supposed to do, anyway.&lt;br /&gt;
&lt;br /&gt;
This isn't to say you have to do it this way, but it is convenient. The apidox also document design decisions. They also document what you want a particular piece of code to do, regardless of what it actually does. That makes it possible to independently check that the code does what it's supposed to: because it's written down. &lt;br /&gt;
&lt;br /&gt;
'''2. Document your headers completely'''&lt;br /&gt;
&lt;br /&gt;
The headers are what's most visible to users (in this context, users are developers who are re-using) of your code, and they should be complete. Document each structural bit of the headers as you go along. This means:&lt;br /&gt;
&lt;br /&gt;
*Every file should have a file-level comment. This is suggested in the KDE guidelines anyway -- near the top of your file, write down what the file is for, vaguely what it defines. Wrap this up in a /** @file */ comment and you are set.&lt;br /&gt;
*Every namespace should have a comment. A given namespace only needs a comment once in your source tree (or within one bunch of files that generate apidox together), but it can't hurt to repeat the description on each occasion -- just make it brief. These comments are just plain apidox comments wrapped up in /** */ ; there are no special markups needed like the @file for file comments.&amp;lt;br /&amp;gt;Do make sure the comment is just before the namespace and doesn't get distanced from the namespace it documents. The following is fine:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:In the next example, someone has snuck in some extra stuff between the apidox comment and the namespace it is documenting. This may cause Doxygen errors (so then it is easy to spot) or it may cause the namespace documentation to attach to something wildly different (and then it's hard to spot).&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** The Ungulate namespace collects classes and methods&lt;br /&gt;
pertaining to hooved animals. */&lt;br /&gt;
class Mammal;&lt;br /&gt;
namespace Ungulate {&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
:There is not much you can do about this except to be watching when you insert code -- don't separate apidox from the thing they are documenting.&lt;br /&gt;
*Every class should have a comment. Classes are the important building blocks of your application or library, so this is one place where writing lots helps. Write down why the class exists. Write down what it is supposed to do. Give an example of how to use it. Explain how not to use it, or what prerequisites it has (for instance, lots of classes need a KInstance object, but don't document that explicitly).&amp;lt;br /&amp;gt;The same caveats apply as with namespace apidox: make sure the class follows its apidox immediately.&lt;br /&gt;
*Every method should have a comment explaining what it does and what the parameters are for. Method parameters should be documented using @param. Don't rely on the name of the method or the parameters to be fully self-documenting. Besides, writing these things down properly will trigger Doxygen errors if you change them in an incompatible way later -- and that is going to save you lots of time in finding source and binary incompatibilities and explaining to users why their code suddenly doesn't do what they expect (assuming it compiles at all). So good method apidox is an additional insurance against making bad changes. Same caveats apply.&lt;br /&gt;
*Every enumeration type should have a comment explaining what the enumeration is for, even if it's just /** Various constants */.&lt;br /&gt;
*Every enumeration value should have a comment too, to explain what it represents. Don't rely on the name of the enumeration value being sufficiently expressive.&amp;lt;br /&amp;gt;For the purposes of readability, I suggest that you document enumeration values after the value, as opposed to the documentation format for namespaces, classes and methods where you write the documentation in front of the thing you are documenting. The format of the documentation is slightly different. Instead of writing /** Documentation */ in front, you write /**&amp;lt; Documentation afterards */, where the &amp;lt; denotes that the documentation applies to the thing just past.&amp;lt;br /&amp;gt;It looks like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
enum State {&lt;br /&gt;
  none,    /**&amp;lt; No bracket seen */&lt;br /&gt;
  bracket, /**&amp;lt; Found a ( for grouping */&lt;br /&gt;
  squote,  /**&amp;lt; Found a single quote */&lt;br /&gt;
  dquote   /**&amp;lt; Found double quotes */&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''3. Watch this space!'''&lt;br /&gt;
&lt;br /&gt;
Watch the [http://www.englishbreakfastnetwork.org/ English Breakfast Network] for the [http://www.englishbreakfastnetwork.org/apidocs/ results] of your apidox work. Check the log files for errors -- Doxygen can complain quite loudly. &lt;br /&gt;
&lt;br /&gt;
'''4. Write a main page for your application.'''&lt;br /&gt;
&lt;br /&gt;
This is usually done in a separate file {{path|Mainpage.dox}} in the top-level of a library or application. The file's content is just a single apidox comment that starts with /** @mainpage title ; the rest of the file is just a long comment about what the library or application is for.&lt;br /&gt;
&lt;br /&gt;
==  APIDOX in altem Code korrigieren ==&lt;br /&gt;
&lt;br /&gt;
Writing apidox in old code is a lot like writing the same apidox in new code, except that there is more cruft in the way. The number 1 tip to follow is: watch the logs on English Breakfast Network. Those will show you what errors there are in the apidox. However, Doxygen can't catch everything that is wrong with the documentation on its own, so you will have to do some reading yourself. The other tips for new apidox apply equally here: you want to document everything, in a consistent style. If methods show up on the generated apidox pages with no documentation, you know that you have more apidox to write. (Doxygen may provide an error message, but doesn't do that everywhere in the current setup because there would just be too many.)&lt;br /&gt;
&lt;br /&gt;
In old apidox, you are more likely to suffer from the following symptoms:&lt;br /&gt;
&lt;br /&gt;
*Missing parameter documentation (because parameters were renamed, or added, or removed, or something).&lt;br /&gt;
*Missing method documentation.&lt;br /&gt;
*Missing class documentation.&lt;br /&gt;
*Documentation that has wandered off on its own and is attached to the wrong thing now.&lt;br /&gt;
&lt;br /&gt;
The first of these can be fixed by correcting the parameter documentation. See the examples section. The next two -- missing documentation that you can see is there in the source files but that does not show up in the generated HTML pages, is usually a matter of missing documentation on surrounding blocks. See the common pitfalls section, and make sure that the surrounding classes, namespaces and files all have documentation.&lt;br /&gt;
&lt;br /&gt;
The last problem can best be fixed by moving the offending documentation back to where it belongs (really, it's not the documentation that is at fault, it's whatever has squeezed in -- the home-breaker -- between the documentation and the thing it was originally attached to). You could use some Doxygen special tags to avoid moving stuff around like that, but it does not help the understandability of the source much.&lt;br /&gt;
&lt;br /&gt;
== Beispiel APIDOX ==&lt;br /&gt;
&lt;br /&gt;
So what does documentation look like in the headers? How do you write a method documenation that describes the parameters as well? This section contains boilerplate for most common situations. Doxygen does not require a strict style -- it will ignore whitespace and asterisks at the beginning of a line, so you can make the documentation ASCII-pretty.&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a file:''' The newline after @file is significant! The text after @author is listed in a special Authors section of the apidox; you can list multiple authors.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** @file&lt;br /&gt;
 * This file is part of AnApplication and defines&lt;br /&gt;
 * classes Ungulate and Moose.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Mostly by me&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a namespace:'''&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This namespace collects functions related to&lt;br /&gt;
 * counting and enumeration of mammals and their limbs.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Documentation for a class:''' Some Doxygen special commands are used here to provide additional information. @author (as with files) identifies authors of the code; these are collected in a special ''Authors:'' section of the apidox. You can list more than one author. The @since tag tells users since when the class has existed. It is usual to put a KDE release number here.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose in the woodland&lt;br /&gt;
 * simulator. A single Moose object can be created,&lt;br /&gt;
 * but it is more useful to instantiate Moose::Factory&lt;br /&gt;
 * by calling Moose::factory(), and then calling spawn()&lt;br /&gt;
 * for each new Moose, since that maintains the ecological&lt;br /&gt;
 * balance far better.&lt;br /&gt;
 *&lt;br /&gt;
 * @author Adriaan de Groot &amp;lt;degroot@kde.org&amp;gt;&lt;br /&gt;
 * @since  3.5&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Method documentation:''' We can use @author and @since just like we do for classes. In addition, there are the parameters of the method that can be described. @p is used to refer to them in running text, and @param is used to construct a list of parameter descriptions that is specially formatted. Finally, @return entries describe the values that may be returned by the method. &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This method names a particular Moose and as a side effect&lt;br /&gt;
 * sets whether or not the Moose is treated as a Reindeer.&lt;br /&gt;
 * When @p santa is @c true, the name of the moose is set to&lt;br /&gt;
 * the next of the available Reindeer (if possible).&lt;br /&gt;
 *&lt;br /&gt;
 * @param name name to assign to the Moose, which is only&lt;br /&gt;
 *             relevant if the moose is not a Reindeer.&lt;br /&gt;
 * @param santa is this Moose assigned to Santa? if so, the&lt;br /&gt;
 *              name is irrelevant.&lt;br /&gt;
 *&lt;br /&gt;
 * @return @c true if naming the Moose succeeded&lt;br /&gt;
 * @return @c false if naming the Moose failed. This only&lt;br /&gt;
 *            happens if the Moose is assigned to Santa duty&lt;br /&gt;
 *            but there are already eight named Reindeer.&lt;br /&gt;
 */&lt;br /&gt;
bool name(const QString &amp;amp;name, bool santa = false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Enum documentation is described in the section on writing new apidox. The same kind of documentation as for classes applies, with the addition of the documentation for each enumerated value which belongs inline.&lt;br /&gt;
&lt;br /&gt;
== Beliebte Fehler ==&lt;br /&gt;
&lt;br /&gt;
This section lists common pitfalls in writing apidox. Typically, they are easily&lt;br /&gt;
overlooked mistakes that produce weird error messages, but I will also include&lt;br /&gt;
some stylistic pitfalls that should be avoided.&lt;br /&gt;
&lt;br /&gt;
'''Missing APIDOX''': You ''know'' you wrote dox for class Moose, but after&lt;br /&gt;
generation they are not visible. You ''know'' that the file-scope function int&lt;br /&gt;
foo() is documented, but it's not there either! What is going on?&lt;br /&gt;
&lt;br /&gt;
The most common pitfall, the one that leads to &amp;quot;missing&amp;quot; apidox, is forgetting&lt;br /&gt;
to document surrounding structure. The &amp;quot;structure&amp;quot; in the source comes from&lt;br /&gt;
files, namespaces, classes and methods. In order to document a class you must&lt;br /&gt;
document the namespace it is in (if there is one) and the file that it is in.&lt;br /&gt;
In order to document a method, you must document the class it is in (and thus&lt;br /&gt;
the namespace and file). So the easiest rule of thumb is to&lt;br /&gt;
document ''everything''.&lt;br /&gt;
{{note (de)|This hard-and-fast rule is not quite accurate:&lt;br /&gt;
classes do not need the file to be documented,&lt;br /&gt;
so you can leave out the /** @file */ comment for&lt;br /&gt;
source files containing only classes (and namespaces).&lt;br /&gt;
Note that classes in a namespace require the namespace&lt;br /&gt;
to be documented, but classes in the :: namespace&lt;br /&gt;
don't need extra documentation.&lt;br /&gt;
I'm not sure about anonymous namespaces.&lt;br /&gt;
&lt;br /&gt;
For file-scoped functions -- that is, functions&lt;br /&gt;
that are defined in a file, not in a namespace&lt;br /&gt;
and not in a class,&lt;br /&gt;
you ''must'' document the file&lt;br /&gt;
they are in. This applies mostly&lt;br /&gt;
to files which collect a bunch of non-method utility functions.}}&lt;br /&gt;
&lt;br /&gt;
'''Broken parameter documentation:''' Documenting parameters to methods can be done two ways: you can document &amp;lt;em&amp;gt;none&amp;lt;/em&amp;gt; of them, or you can document&lt;br /&gt;
''all'' of them for a given method. There is no middle ground (that doesn't&lt;br /&gt;
generate gobs of errors that you should fix).&lt;br /&gt;
&lt;br /&gt;
If you document ''all'' of your parameters (which is a good thing to do,&lt;br /&gt;
and generates things in a nicely formatted fashion), then your method&lt;br /&gt;
apidox consists first of a general description of the method and then a&lt;br /&gt;
bunch of @param tags which describe each individual parameter. The @param&lt;br /&gt;
tag is followed by the name of the parameter -- watch out for spelling&lt;br /&gt;
and case-sensitivity! -- and then the description. The description can&lt;br /&gt;
span multiple lines.&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the&lt;br /&gt;
 * origin to the given integral coordinate.&lt;br /&gt;
 *&lt;br /&gt;
 * @param y y-coordinate, which is on an axis perpendicular to the&lt;br /&gt;
 *        x-axis, yet still in the same plane.&lt;br /&gt;
 * @param x x-coordinate&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
When you document all the parameters like this, Doxygen will complain if&lt;br /&gt;
you misspell parameter names, or forget some, or mention parameters that&lt;br /&gt;
are not there. This will force you to update the documentation if you&lt;br /&gt;
change the method signature. And that's a good thing.&lt;br /&gt;
&lt;br /&gt;
Additional pitfalls are putting the type of the parameter in the list,&lt;br /&gt;
like @param int x, which makes &amp;quot;int&amp;quot; the name of the parameter. Another&lt;br /&gt;
pitfall is that @param should come &amp;lt;em&amp;gt;after&amp;lt;/em&amp;gt; the general description.&lt;br /&gt;
Once the @param list starts, nothing can stop it except for other&lt;br /&gt;
list-style Doxygen tags like @since, @author or @return. So write @param&lt;br /&gt;
after the story and before, say, @return.&lt;br /&gt;
&lt;br /&gt;
If you document ''none'' of the parameters, you do not use the @param tag&lt;br /&gt;
at all. You can talk about your parameters by writing @p before the name&lt;br /&gt;
of a parameter (or anything else, really, but it only makes sense in front&lt;br /&gt;
of a name of a parameter). Like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** Calculate the root-mean-square distance from the origin to&lt;br /&gt;
 * the given integral coordinate which is given as a pair @p x,&lt;br /&gt;
 * @p y. If @p nonFree is true, use ESR instead of RMS in the&lt;br /&gt;
 * computation.&lt;br /&gt;
 */&lt;br /&gt;
double distance(int x, int y, bool nonFree=false);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''Misuse of tags in running text:''' This boils down to the warning&lt;br /&gt;
above about where to put @param: not every Doxygen tag can go anywhere.&lt;br /&gt;
Some start lists or basically end the general description part of a&lt;br /&gt;
description, so you need to avoid using them in running text.&lt;br /&gt;
&lt;br /&gt;
'''Chosing between Doxygen errors and compiler warnings:''' If you are&lt;br /&gt;
going to document your parameters, you need to name them. If you are&lt;br /&gt;
defining a stub method, this can lead to compiler warnings.&lt;br /&gt;
&lt;br /&gt;
'''Accidental tags:''' It can be easy to accidentally use Doxygen tags&lt;br /&gt;
in running text -- email addresses, backslash escapes, those are the&lt;br /&gt;
easy ones. Watch the Doxygen logs and escape that at sign with a backslash&lt;br /&gt;
when needed (i.e.&amp;amp;nbsp;write \@ to get an at sign). It's probably a good&lt;br /&gt;
idea to avoid the backslash style of apidox entirely; at the same time, if&lt;br /&gt;
you happen to write \moose, Doxygen will complain that that is an invalid&lt;br /&gt;
tag.&lt;br /&gt;
&lt;br /&gt;
'''Accidental HTML:''' If you use &amp;amp;lt; and &amp;amp;gt; in your apidox, these may&lt;br /&gt;
confuse Doxygen -- especially if you write things like &amp;amp;lt;service&amp;amp;gt;&lt;br /&gt;
which look like HTML tags. This is a common way of writing some kind of&lt;br /&gt;
element that may be replaced in a method call or string or something, so&lt;br /&gt;
it crops up all the time. You know, you write some thing like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/** This method connects to a database. The connection string is&lt;br /&gt;
 * composed of a username, password, host and database name as&lt;br /&gt;
 * follows:&lt;br /&gt;
 * &amp;lt;username&amp;gt;:&amp;lt;password&amp;gt;@&amp;lt;host&amp;gt;//&amp;lt;database&amp;gt;&lt;br /&gt;
 *&lt;br /&gt;
 * @return true if the connection succeeded.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This bit of dox is terribly broken, because the whole sample connection&lt;br /&gt;
string will be interpreted as (bad) HTML and ignored. There are two&lt;br /&gt;
solutions:&lt;br /&gt;
&amp;lt;ol&amp;gt;&lt;br /&gt;
*Write \&amp;amp;lt; instead of just &amp;amp;lt; to escape the &amp;amp;lt; and make Doxygen output it normally. Doxygen is smart enough to turn this into &amp;amp;amp;lt; in HTML output. This has only a minimal impact on readability of the dox in the header files themselves.&lt;br /&gt;
*Use the HTML formatting that Doxygen makes available, and write &amp;amp;lt;i&amp;amp;gt;''foo''&amp;amp;lt;/i&amp;amp;gt; instead of &amp;amp;lt;&amp;lt;i&amp;gt;foo&amp;lt;/i&amp;gt;&amp;amp;gt;. This produces nicer output with italics instead of plain text, so it is easier to spot what is the replaceable part of the text. The downside is that it has a larger visible impact on the apidox in the headers.&lt;br /&gt;
&amp;lt;/ol&amp;gt;&lt;br /&gt;
&lt;br /&gt;
;Superfluous @ref&lt;br /&gt;
:It can be tempting -- certainly if you've written dox for other projects -- to use #method or @ref method to force a reference to another method somewhere. Relax, it's not needed and usually causes Doxygen warnings to boot. Just name the method normally, make apidox and watch the references appear naturally.&lt;br /&gt;
&lt;br /&gt;
== KDE spezifische Tags ==&lt;br /&gt;
'''@bc''': This tag indicated binary compatibility, much like ''@since'' does. The argument after ''@bc'' is the scope of binary compatibility (for instance, KDE4). Classes that are not marked with ''@bc'' may, in some modules, be flagged as incompatible so that they can be avoided.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @bc KDE4.2 Compatibility is expected to break &lt;br /&gt;
 *     with next-generation mooses.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
'''@libs''': Use this tag to indicate what libraries should be linked in for the given class. Although this is usually the name of the directory the class lives in, this is not always the case.&lt;br /&gt;
&lt;br /&gt;
Example:&lt;br /&gt;
&amp;lt;code cpp&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class emulates a Moose.&lt;br /&gt;
 * @libs&lt;br /&gt;
 *     @a -lkdeui or use \$(LIB_KDEUI) in the KDE build framework.&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Code Beispiele in APIDOX ==&lt;br /&gt;
&lt;br /&gt;
It can be useful to put example code in the APIDOX for a class.&lt;br /&gt;
Very useful, in fact, for the reader who is wondering&lt;br /&gt;
how exactly to use the class in a straightforward way.&lt;br /&gt;
Most classes in {{path|kdelibs/kdecore}} have example code.&lt;br /&gt;
&lt;br /&gt;
One way to write example code is to use @code and @endcode around&lt;br /&gt;
blocks of example code in the Doxygen comments themselves, like this:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
/**&lt;br /&gt;
 * This class represents a Moose.&lt;br /&gt;
 * The correct way of generating Meese is to use the factory:&lt;br /&gt;
 *&lt;br /&gt;
 * @code&lt;br /&gt;
 * Moose::Factory outlet = Moose::factory();&lt;br /&gt;
 * Moose *m = outlet.spawn();&lt;br /&gt;
 * @endcode&lt;br /&gt;
 */&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This is how most of the examples in {{path|kdelibs}}&lt;br /&gt;
are done, actually. It works reasonably well, you can pare the&lt;br /&gt;
example down to something really minimal and leave out all the&lt;br /&gt;
boilerplate.&lt;br /&gt;
&lt;br /&gt;
An important drawback of this approach to writing example code is that&lt;br /&gt;
the code is never checked to see if it actually works.&lt;br /&gt;
The code is also ''so'' terse, usually, that it's hard&lt;br /&gt;
to expand into a complete example that actually compiles and runs.&lt;br /&gt;
&lt;br /&gt;
To solve this problem, you can write ''real code'' that&lt;br /&gt;
actually compiles (as part of the test suite for the code&lt;br /&gt;
that you have anyway) and that illustrates exactly &lt;br /&gt;
how to use the class under consideration in an actual program.&lt;br /&gt;
Better yet, you do not need to include ''all'' the code&lt;br /&gt;
in the APIDOX, just the interesting bits.&lt;br /&gt;
The way to do this is to put the code in a file in the&lt;br /&gt;
&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt; subdirectory of your code.&lt;br /&gt;
Then use Doxygen's @include tag to include the&lt;br /&gt;
code from that file into the API documentation.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Benutze nicht @example! Es macht etwas total anderes als was du erwarten könntest (zum Beispiel fügt es keinen Beispiel-Code ein).}}&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
[http://www.stack.nl/~dimitri/doxygen/commands.html englische Liste der unterstützen Doxygen Tags]&lt;br /&gt;
:Hier ist eine Liste von allen verfügbaren Dokumentations-Tags von Doxygen von der offiziellen Seite. Beachte, das diese Seite ein Backslash vor einem Tag benutzt, während diese Seite immer das At-Zeichen benutzt. Beides ist erlaubt, doch in KDE sollte zu Gunsten der Konsistenz das At-Zeichen benutzt werden. &lt;br /&gt;
&lt;br /&gt;
[[Category:Documentation]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Services/Plugins</id>
		<title>Development/Tutorials/Services/Plugins</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Services/Plugins"/>
				<updated>2008-11-01T10:14:51Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: +language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Services/Plugins}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
&lt;br /&gt;
series=Services|&lt;br /&gt;
&lt;br /&gt;
name=Creating and Loading Plugins Using KService|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Traders|Traders: Querying the System]]&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
Before starting with the code let's see which advantages we can undertake&lt;br /&gt;
developing a plugin structured application. First of all an application capable &lt;br /&gt;
of managing plugins can extend its features with apparently no limits. Anyway, rather than developing a plugin structured application because &amp;quot;it's so coool!!&amp;quot; the developer should think about the real advantages of this kind of development. For instance we can think about an archive manager application: the main program can delegate the creation/extraction/editing of each type of archive to specific plugins. This way we give modularity to the application so that supporting brand new archive types in the future will simply consist in writing the specific plugin and not rewriting the whole application. Ok, then let's stop talking.. and start coding =).&lt;br /&gt;
&lt;br /&gt;
== The Text Editor Example ==&lt;br /&gt;
So, even if an archiving application would be nicer to look at, here we will examine a simple text editing application capable of plugin loading.&lt;br /&gt;
Each plugin will simply give a specific text editing feature.&lt;br /&gt;
&lt;br /&gt;
== Creating a Plugin Interface Class ==&lt;br /&gt;
The main step to create a plugin structure is to define its base class.&lt;br /&gt;
This class will be inherited by every plugin and shuld give access to the key resources of the main application. In this example the main plugin class will inherit a KXMLGUIClient since every plugin will give access to its features through a gui element (a KAction in this case).&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;kdemacros.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kxmlguiclient.h&amp;gt;&lt;br /&gt;
#include &amp;lt;QObject&amp;gt;&lt;br /&gt;
&lt;br /&gt;
class KTextEdit;&lt;br /&gt;
&lt;br /&gt;
class KDE_EXPORT Plugin : public QObject , public KXMLGUIClient&lt;br /&gt;
{&lt;br /&gt;
    Q_OBJECT&lt;br /&gt;
&lt;br /&gt;
    public:&lt;br /&gt;
        Plugin(QObject *parent);&lt;br /&gt;
        virtual ~Plugin();&lt;br /&gt;
&lt;br /&gt;
        /**&lt;br /&gt;
         * @return KTextEdit pointing to the main application editor widget&lt;br /&gt;
         */&lt;br /&gt;
        KTextEdit* editorInterface();&lt;br /&gt;
&lt;br /&gt;
        /**&lt;br /&gt;
         * @internal Used by the main application to correctly set the editor.&lt;br /&gt;
         * Do not call from within the reimplementation.&lt;br /&gt;
         */&lt;br /&gt;
        void setEditorInterface(KTextEdit *);&lt;br /&gt;
&lt;br /&gt;
    private:&lt;br /&gt;
        class PluginPrivate;&lt;br /&gt;
        PluginPrivate *d;&lt;br /&gt;
&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== The Plugin Factory Macro ==&lt;br /&gt;
&lt;br /&gt;
== Registering a Plugin Type ==&lt;br /&gt;
&lt;br /&gt;
== Registering a Plugin With the SyCoCa ==&lt;br /&gt;
&lt;br /&gt;
== Finding Plugins ==&lt;br /&gt;
&lt;br /&gt;
== Instantiating Plugins ==&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Using_KParts_(de)</id>
		<title>Development/Tutorials/Using KParts (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Using_KParts_(de)"/>
				<updated>2008-09-23T14:59:42Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Translated the rest&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Using_KParts}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Plugins und KParts|&lt;br /&gt;
&lt;br /&gt;
name=Wie man KParts benutzt|&lt;br /&gt;
&lt;br /&gt;
pre=[[Development/Tutorials/KCmdLineArgs (de)|Anleitung 5 - Kommandozeilenargumente]]|&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
reading=[http://api.kde.org/4.x-api/kdelibs-apidocs/kparts/html/index.html KParts Dokumentation (englisch)]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Einführung ==&lt;br /&gt;
&lt;br /&gt;
Die KPart Technologie wird in KDE benutzt, um GUI Komponenten wiederzuverwerten. Der Vorteile eines KParts sind dabei die vordefinierte Aktionen, wie Werkzeugleistenknöpfe. Indem man kparts in Applikationen benutzt, braucht ein Entwickler weniger Zeit in die Implementation eines Texteditors oder Kommandozeilenaktionen investieren und statt dessen einfach ein katepart oder ein konsolepart benutzen. KParts werden auch mit der Plugin Technologie benutzt, um Applikationen in andere einzubetten, wie es zum Beispiel die PIM Applikationen in Kontact machen.&lt;br /&gt;
&lt;br /&gt;
Diese Anleitung zeigt, wie man ein KPart in der eigenen Applikation einsetzt und wie man sein eigenes KPart erzeugt.&lt;br /&gt;
&lt;br /&gt;
== Katepart benutzen ==&lt;br /&gt;
&lt;br /&gt;
Einfache KDE Applikationen benutzen ein MainWindow welches von KMainWindow abgeleitet wird (so wie in den vorigen Anleitungen). Um ein KPart in einer Applikation verwenden zu können, muß das MainWindows statt dessen von KParts::MainWindow abgeleitet werden. Dadurch wird sichergestellt, dass die Integration von Werkzeugleiste und Menüeintragen und dem KPart vernünftig funktioniert. &lt;br /&gt;
&lt;br /&gt;
Der folgende Code erzeugt ein KParts::MainWindow mit einem kpart darin. &lt;br /&gt;
&lt;br /&gt;
=== main.cpp ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
#include &amp;lt;KApplication&amp;gt;&lt;br /&gt;
#include &amp;lt;KAboutData&amp;gt;&lt;br /&gt;
#include &amp;lt;KCmdLineArgs&amp;gt;&lt;br /&gt;
#include &amp;lt;KUrl&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
int main (int argc, char *argv[])&lt;br /&gt;
{&lt;br /&gt;
    KAboutData aboutData( &amp;quot;kparttutorial1&amp;quot;, &amp;quot;kparttutorial1&amp;quot;,&lt;br /&gt;
        ki18n(&amp;quot;KPart Tutorial 1&amp;quot;), &amp;quot;0.1&amp;quot;,&lt;br /&gt;
        ki18n(&amp;quot;A MainWindow for a KatePart.&amp;quot;),&lt;br /&gt;
        KAboutData::License_GPL,&lt;br /&gt;
        ki18n(&amp;quot;Copyright (c) 2007 Developer&amp;quot;) );&lt;br /&gt;
    KCmdLineArgs::init( argc, argv, &amp;amp;aboutData );&lt;br /&gt;
 &lt;br /&gt;
    KCmdLineOptions options;&lt;br /&gt;
    options.add(&amp;quot;+[file]&amp;quot;, ki18n(&amp;quot;Document to open&amp;quot;));&lt;br /&gt;
    KCmdLineArgs::addCmdLineOptions(options);&lt;br /&gt;
 &lt;br /&gt;
    KApplication app;&lt;br /&gt;
 &lt;br /&gt;
    MainWindow* window = new MainWindow();&lt;br /&gt;
    window-&amp;gt;show();&lt;br /&gt;
&lt;br /&gt;
    KCmdLineArgs *args = KCmdLineArgs::parsedArgs();&lt;br /&gt;
    if(args-&amp;gt;count())&lt;br /&gt;
    {&lt;br /&gt;
        window-&amp;gt;load(args-&amp;gt;url(0).url());&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    return app.exec();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die main.cpp Datei ist die gleiche die in [[Development/Tutorials/KCmdLineArgs (de)|Anleitung 5 - Kommandozeilenargumente]] benutzt wurde. Der einzige Unterschied liegt in den Details von KAboutData.&lt;br /&gt;
&lt;br /&gt;
=== mainwindow.h ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#ifndef KPARTTUTORIAL1_H&lt;br /&gt;
#define KPARTTUTORIAL1_H&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;kparts/mainwindow.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * This is the application &amp;quot;Shell&amp;quot;.  It has a menubar, toolbar, and&lt;br /&gt;
 * statusbar but relies on the &amp;quot;Part&amp;quot; to do all the real work.&lt;br /&gt;
 *&lt;br /&gt;
 * @short Application Shell&lt;br /&gt;
 * @author Developer &amp;lt;developer@kde.org&amp;gt;&lt;br /&gt;
 * @version 0.1&lt;br /&gt;
 */&lt;br /&gt;
class MainWindow : public KParts::MainWindow&lt;br /&gt;
{&lt;br /&gt;
    Q_OBJECT&lt;br /&gt;
public:&lt;br /&gt;
    /**&lt;br /&gt;
     * Default Constructor&lt;br /&gt;
     */&lt;br /&gt;
    MainWindow();&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Default Destructor&lt;br /&gt;
     */&lt;br /&gt;
    virtual ~MainWindow();&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Use this method to load whatever file/URL you have&lt;br /&gt;
     */&lt;br /&gt;
    void load(const KUrl&amp;amp; url);&lt;br /&gt;
&lt;br /&gt;
private:&lt;br /&gt;
    void setupActions();&lt;br /&gt;
&lt;br /&gt;
private:&lt;br /&gt;
    KParts::ReadWritePart *m_part;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif // KPARTTUT1_H&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die mainwindow.h Datei ist sehr einfach. Das wichtigste darin ist, dass die MainWindo Klasse von KParts::MainWindow abgeleitet wird.&lt;br /&gt;
&lt;br /&gt;
=== mainwindow.cpp ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;kaction.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kactioncollection.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kconfig.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kedittoolbar.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kfiledialog.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kshortcutsdialog.h&amp;gt;&lt;br /&gt;
#include &amp;lt;klibloader.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kmessagebox.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kstandardaction.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kstatusbar.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kurl.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;QApplication&amp;gt;&lt;br /&gt;
&lt;br /&gt;
MainWindow::MainWindow()&lt;br /&gt;
    : KParts::MainWindow( )&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // Setup our actions&lt;br /&gt;
    setupActions();&lt;br /&gt;
&lt;br /&gt;
    // this routine will find and load our Part.  &lt;br /&gt;
    KLibFactory *factory = KLibLoader::self()-&amp;gt;factory(&amp;quot;katepart&amp;quot;);&lt;br /&gt;
    if (factory)&lt;br /&gt;
    {&lt;br /&gt;
        // now that the Part is loaded, we cast it to a Part to get&lt;br /&gt;
        // our hands on it&lt;br /&gt;
        m_part = static_cast&amp;lt;KParts::ReadWritePart *&amp;gt;&lt;br /&gt;
                 (factory-&amp;gt;create(this, &amp;quot;KatePart&amp;quot; ));&lt;br /&gt;
&lt;br /&gt;
        if (m_part)&lt;br /&gt;
        {&lt;br /&gt;
            // tell the KParts::MainWindow that this is indeed&lt;br /&gt;
            // the main widget&lt;br /&gt;
            setCentralWidget(m_part-&amp;gt;widget());&lt;br /&gt;
&lt;br /&gt;
            setupGUI(ToolBar | Keys | StatusBar | Save);&lt;br /&gt;
&lt;br /&gt;
            // and integrate the part's GUI with the shell's&lt;br /&gt;
            createGUI(m_part);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
        // if we couldn't find our Part, we exit since the Shell by&lt;br /&gt;
        // itself can't do anything useful&lt;br /&gt;
        KMessageBox::error(this, &amp;quot;Could not find our Part!&amp;quot;);&lt;br /&gt;
        qApp-&amp;gt;quit();&lt;br /&gt;
        // we return here, cause qApp-&amp;gt;quit() only means &amp;quot;exit the&lt;br /&gt;
        // next time we enter the event loop...&lt;br /&gt;
        return;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
MainWindow::~MainWindow()&lt;br /&gt;
{&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::load(const KUrl&amp;amp; url)&lt;br /&gt;
{&lt;br /&gt;
    m_part-&amp;gt;openUrl( url );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::setupActions()&lt;br /&gt;
{&lt;br /&gt;
    KStandardAction::open(this, SLOT(fileOpen()), &lt;br /&gt;
        actionCollection());&lt;br /&gt;
    KStandardAction::quit(qApp, SLOT(closeAllWindows()),&lt;br /&gt;
        actionCollection());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::load()&lt;br /&gt;
{&lt;br /&gt;
    load(KFileDialog::getOpenUrl());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die mainwindow.cpp Datei enthält die Implementation von MainWindow. Der Konstruktor dieser Klasse enthält den gesamten Code um das KPart zu laden.&lt;br /&gt;
&lt;br /&gt;
Als erstes werden hier die Aktionen des Hautfensters (Öffnen und Beenden) aufgesezt, und dann die Gui-Elemente aufgesetzt, die damit arbeiten sollen (Werkzeugleisten, Menüenträge, Tastenkürzel). Als nächstes kommt der Standardcode, um das KPart zu laden. Die createGUI Methode ist verantwortlich dafür, die Werkzeugleisten und Menüs des KParts mit denen der restlichen Applikation zu vermischen. &lt;br /&gt;
&lt;br /&gt;
=== kparttut1ui.rc ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code xml n&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE kpartgui SYSTEM &amp;quot;kpartgui.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;kpartgui name=&amp;quot;kparttut1&amp;quot; version=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;MenuBar&amp;gt;&lt;br /&gt;
  &amp;lt;Menu noMerge=&amp;quot;1&amp;quot; name=&amp;quot;file&amp;quot;&amp;gt;&amp;lt;text&amp;gt;&amp;amp;amp;File&amp;lt;/text&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;file_open&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;Separator/&amp;gt;&lt;br /&gt;
    &amp;lt;Merge/&amp;gt;&lt;br /&gt;
    &amp;lt;Separator/&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;file_quit&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/Menu&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;Merge /&amp;gt;&lt;br /&gt;
&amp;lt;/MenuBar&amp;gt;&lt;br /&gt;
&amp;lt;ToolBar noMerge=&amp;quot;1&amp;quot; name=&amp;quot;mainToolBar&amp;quot;&amp;gt;&amp;lt;text&amp;gt;Main Toolbar&amp;lt;/text&amp;gt;&lt;br /&gt;
  &amp;lt;Action name=&amp;quot;file_open&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;Merge/&amp;gt;&lt;br /&gt;
&amp;lt;/ToolBar&amp;gt;&lt;br /&gt;
&amp;lt;/kpartgui&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die kparttut1ui.rc Datei wird benutzt, um zu definieren, wie die Aktionen im KPart und im Hauptfenster zusammengesmischt werden sollen. Die &amp;lt;tt&amp;gt;&amp;lt;Merge /&amp;gt;&amp;lt;/tt&amp;gt; Elemente im Dateimenü zeigen zum Beispiel an, dass jeder Part, der Aktionen für das Dateimenü liefert, diese nach file_open und vor file_quit einfügen soll. &lt;br /&gt;
&lt;br /&gt;
=== CMakeLists.txt ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
project(kparttut1)&lt;br /&gt;
&lt;br /&gt;
FIND_PACKAGE(KDE4 REQUIRED)&lt;br /&gt;
INCLUDE_DIRECTORIES( ${KDE4_INCLUDES} . )&lt;br /&gt;
&lt;br /&gt;
set(kparttut1_SRCS&lt;br /&gt;
   main.cpp&lt;br /&gt;
   mainwindow.cpp&lt;br /&gt;
 )&lt;br /&gt;
&lt;br /&gt;
kde4_add_executable(kparttut1 ${kparttut1_SRCS})&lt;br /&gt;
&lt;br /&gt;
target_link_libraries(kparttut1 ${KDE4_KDEUI_LIBS} ${KDE4_KPARTS_LIBS})&lt;br /&gt;
&lt;br /&gt;
########### install files ###############&lt;br /&gt;
install(TARGETS kparttut1 DESTINATION ${BIN_INSTALL_DIR} )&lt;br /&gt;
install( FILES kparttut1ui.rc &lt;br /&gt;
    DESTINATION  ${DATA_INSTALL_DIR}/kparttut1 )&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Die CMakeLists.txt Datei ist in diesem Fall sehr einfach.&lt;br /&gt;
&lt;br /&gt;
== Die Applikation ausführen ==&lt;br /&gt;
&lt;br /&gt;
Nach dem Kompilieren der Appikation kann diese mit&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
kparttut1 filename&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
ausgeführt werden. filename ist dabei eine Textdatei, die geladen werden soll. Eine der Quellcodedateien wäre ein gutes Beispiel dafür.&lt;br /&gt;
&lt;br /&gt;
Wenn die Datei geladen wird, steht einem ein kompletter kate-Editor in seinem eigenen Fenster zu Verfügung. Alle Features des Editors sind über die Werkzeugleiste und Menüs verfügbar.&lt;br /&gt;
&lt;br /&gt;
Weiterhin fällt die 'Öffnen' Aktion auf, welche in der MainWindow class definiert wurde und auch in der Werkzeugleiste und im Menü neben der 'Beenden' Aktion erscheint.&lt;br /&gt;
&lt;br /&gt;
Die nächste Anleitung wird sich mit dem Erzeugen eigener kparts für die Benutzung in anderen Applikationen beschäftigen.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Using_KParts_(de)</id>
		<title>Development/Tutorials/Using KParts (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Using_KParts_(de)"/>
				<updated>2008-09-23T14:47:10Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and initial translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Using_KParts}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Plugins und KParts|&lt;br /&gt;
&lt;br /&gt;
name=Wie man KParts benutzt|&lt;br /&gt;
&lt;br /&gt;
pre=[[Development/Tutorials/KCmdLineArgs (de)|Anleitung 5 - Kommandozeilenargumente]]|&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
reading=[http://api.kde.org/4.x-api/kdelibs-apidocs/kparts/html/index.html KParts Dokumentation (englisch)]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Einführung ==&lt;br /&gt;
&lt;br /&gt;
Die KPart Technologie wird in KDE benutzt, um GUI Komponenten wiederzuverwerten. Der Vorteile eines KParts sind dabei die vordefinierte Aktionen, wie Werkzeugleistenknöpfe. Indem man kparts in Applikationen benutzt, braucht ein Entwickler weniger Zeit in die Implementation eines Texteditors oder Kommandozeilenaktionen investieren und statt dessen einfach ein katepart oder ein konsolepart benutzen. KParts werden auch mit der Plugin Technologie benutzt, um Applikationen in andere einzubetten, wie es zum Beispiel die PIM Applikationen in Kontact machen.&lt;br /&gt;
&lt;br /&gt;
Diese Anleitung zeigt, wie man ein KPart in der eigenen Applikation einsetzt und wie man sein eigenes KPart erzeugt.&lt;br /&gt;
&lt;br /&gt;
== Katepart benutzen ==&lt;br /&gt;
&lt;br /&gt;
Simple KDE applications use a MainWindow derived from KMainWindow (such as in previous tutorials). To use a KPart in an application, the MainWindow must instead be derived from KParts::MainWindow. This will then take care of integrating the toolbar and menu items of the kpart together.&lt;br /&gt;
&lt;br /&gt;
The following code creates a KParts::MainWindow with a kpart inside it.&lt;br /&gt;
&lt;br /&gt;
=== main.cpp ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
#include &amp;lt;KApplication&amp;gt;&lt;br /&gt;
#include &amp;lt;KAboutData&amp;gt;&lt;br /&gt;
#include &amp;lt;KCmdLineArgs&amp;gt;&lt;br /&gt;
#include &amp;lt;KUrl&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
 &lt;br /&gt;
int main (int argc, char *argv[])&lt;br /&gt;
{&lt;br /&gt;
    KAboutData aboutData( &amp;quot;kparttutorial1&amp;quot;, &amp;quot;kparttutorial1&amp;quot;,&lt;br /&gt;
        ki18n(&amp;quot;KPart Tutorial 1&amp;quot;), &amp;quot;0.1&amp;quot;,&lt;br /&gt;
        ki18n(&amp;quot;A MainWindow for a KatePart.&amp;quot;),&lt;br /&gt;
        KAboutData::License_GPL,&lt;br /&gt;
        ki18n(&amp;quot;Copyright (c) 2007 Developer&amp;quot;) );&lt;br /&gt;
    KCmdLineArgs::init( argc, argv, &amp;amp;aboutData );&lt;br /&gt;
 &lt;br /&gt;
    KCmdLineOptions options;&lt;br /&gt;
    options.add(&amp;quot;+[file]&amp;quot;, ki18n(&amp;quot;Document to open&amp;quot;));&lt;br /&gt;
    KCmdLineArgs::addCmdLineOptions(options);&lt;br /&gt;
 &lt;br /&gt;
    KApplication app;&lt;br /&gt;
 &lt;br /&gt;
    MainWindow* window = new MainWindow();&lt;br /&gt;
    window-&amp;gt;show();&lt;br /&gt;
&lt;br /&gt;
    KCmdLineArgs *args = KCmdLineArgs::parsedArgs();&lt;br /&gt;
    if(args-&amp;gt;count())&lt;br /&gt;
    {&lt;br /&gt;
        window-&amp;gt;load(args-&amp;gt;url(0).url());&lt;br /&gt;
    }&lt;br /&gt;
&lt;br /&gt;
    return app.exec();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The main.cpp file is the same as that used in [[Development/Tutorials/KCmdLineArgs|Tutorial 5 - Command line arguments]].The only difference is in the details of the KAboutData.&lt;br /&gt;
&lt;br /&gt;
=== mainwindow.h ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#ifndef KPARTTUTORIAL1_H&lt;br /&gt;
#define KPARTTUTORIAL1_H&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;kparts/mainwindow.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * This is the application &amp;quot;Shell&amp;quot;.  It has a menubar, toolbar, and&lt;br /&gt;
 * statusbar but relies on the &amp;quot;Part&amp;quot; to do all the real work.&lt;br /&gt;
 *&lt;br /&gt;
 * @short Application Shell&lt;br /&gt;
 * @author Developer &amp;lt;developer@kde.org&amp;gt;&lt;br /&gt;
 * @version 0.1&lt;br /&gt;
 */&lt;br /&gt;
class MainWindow : public KParts::MainWindow&lt;br /&gt;
{&lt;br /&gt;
    Q_OBJECT&lt;br /&gt;
public:&lt;br /&gt;
    /**&lt;br /&gt;
     * Default Constructor&lt;br /&gt;
     */&lt;br /&gt;
    MainWindow();&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Default Destructor&lt;br /&gt;
     */&lt;br /&gt;
    virtual ~MainWindow();&lt;br /&gt;
&lt;br /&gt;
    /**&lt;br /&gt;
     * Use this method to load whatever file/URL you have&lt;br /&gt;
     */&lt;br /&gt;
    void load(const KUrl&amp;amp; url);&lt;br /&gt;
&lt;br /&gt;
private:&lt;br /&gt;
    void setupActions();&lt;br /&gt;
&lt;br /&gt;
private:&lt;br /&gt;
    KParts::ReadWritePart *m_part;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif // KPARTTUT1_H&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The mainwindow.h file is very simple. The important thing to notice here is that the MainWindow class inherits from KParts::MainWindow.&lt;br /&gt;
&lt;br /&gt;
=== mainwindow.cpp ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;kaction.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kactioncollection.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kconfig.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kedittoolbar.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kfiledialog.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kshortcutsdialog.h&amp;gt;&lt;br /&gt;
#include &amp;lt;klibloader.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kmessagebox.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kstandardaction.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kstatusbar.h&amp;gt;&lt;br /&gt;
#include &amp;lt;kurl.h&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;QApplication&amp;gt;&lt;br /&gt;
&lt;br /&gt;
MainWindow::MainWindow()&lt;br /&gt;
    : KParts::MainWindow( )&lt;br /&gt;
{&lt;br /&gt;
&lt;br /&gt;
    // Setup our actions&lt;br /&gt;
    setupActions();&lt;br /&gt;
&lt;br /&gt;
    // this routine will find and load our Part.  &lt;br /&gt;
    KLibFactory *factory = KLibLoader::self()-&amp;gt;factory(&amp;quot;katepart&amp;quot;);&lt;br /&gt;
    if (factory)&lt;br /&gt;
    {&lt;br /&gt;
        // now that the Part is loaded, we cast it to a Part to get&lt;br /&gt;
        // our hands on it&lt;br /&gt;
        m_part = static_cast&amp;lt;KParts::ReadWritePart *&amp;gt;&lt;br /&gt;
                 (factory-&amp;gt;create(this, &amp;quot;KatePart&amp;quot; ));&lt;br /&gt;
&lt;br /&gt;
        if (m_part)&lt;br /&gt;
        {&lt;br /&gt;
            // tell the KParts::MainWindow that this is indeed&lt;br /&gt;
            // the main widget&lt;br /&gt;
            setCentralWidget(m_part-&amp;gt;widget());&lt;br /&gt;
&lt;br /&gt;
            setupGUI(ToolBar | Keys | StatusBar | Save);&lt;br /&gt;
&lt;br /&gt;
            // and integrate the part's GUI with the shell's&lt;br /&gt;
            createGUI(m_part);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    else&lt;br /&gt;
    {&lt;br /&gt;
        // if we couldn't find our Part, we exit since the Shell by&lt;br /&gt;
        // itself can't do anything useful&lt;br /&gt;
        KMessageBox::error(this, &amp;quot;Could not find our Part!&amp;quot;);&lt;br /&gt;
        qApp-&amp;gt;quit();&lt;br /&gt;
        // we return here, cause qApp-&amp;gt;quit() only means &amp;quot;exit the&lt;br /&gt;
        // next time we enter the event loop...&lt;br /&gt;
        return;&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
MainWindow::~MainWindow()&lt;br /&gt;
{&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::load(const KUrl&amp;amp; url)&lt;br /&gt;
{&lt;br /&gt;
    m_part-&amp;gt;openUrl( url );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::setupActions()&lt;br /&gt;
{&lt;br /&gt;
    KStandardAction::open(this, SLOT(fileOpen()), &lt;br /&gt;
        actionCollection());&lt;br /&gt;
    KStandardAction::quit(qApp, SLOT(closeAllWindows()),&lt;br /&gt;
        actionCollection());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::load()&lt;br /&gt;
{&lt;br /&gt;
    load(KFileDialog::getOpenUrl());&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The mainwindow.cpp file contains the implementation of MainWindow. The constructor of this class contains all the code used to load the KPart.&lt;br /&gt;
&lt;br /&gt;
First it sets up the actions used by the main window (Open and Quit), and then sets up the gui elements to go with these items (toolbar items, menu items, keyboard shortcuts). Next is the standard code used to load the KPart. The createGUI method is responsible for merging the toolbars and menus of the KPart with the rest of the application.&lt;br /&gt;
&lt;br /&gt;
=== kparttut1ui.rc ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code xml n&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE kpartgui SYSTEM &amp;quot;kpartgui.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;kpartgui name=&amp;quot;kparttut1&amp;quot; version=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;MenuBar&amp;gt;&lt;br /&gt;
  &amp;lt;Menu noMerge=&amp;quot;1&amp;quot; name=&amp;quot;file&amp;quot;&amp;gt;&amp;lt;text&amp;gt;&amp;amp;amp;File&amp;lt;/text&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;file_open&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;Separator/&amp;gt;&lt;br /&gt;
    &amp;lt;Merge/&amp;gt;&lt;br /&gt;
    &amp;lt;Separator/&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;file_quit&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;/Menu&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;Merge /&amp;gt;&lt;br /&gt;
&amp;lt;/MenuBar&amp;gt;&lt;br /&gt;
&amp;lt;ToolBar noMerge=&amp;quot;1&amp;quot; name=&amp;quot;mainToolBar&amp;quot;&amp;gt;&amp;lt;text&amp;gt;Main Toolbar&amp;lt;/text&amp;gt;&lt;br /&gt;
  &amp;lt;Action name=&amp;quot;file_open&amp;quot;/&amp;gt;&lt;br /&gt;
  &amp;lt;Merge/&amp;gt;&lt;br /&gt;
&amp;lt;/ToolBar&amp;gt;&lt;br /&gt;
&amp;lt;/kpartgui&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The kparttut1ui.rc file is used to define how the actions in the part and the actions in the main window will be merged together. The &amp;lt;tt&amp;gt;&amp;lt;Merge /&amp;gt;&amp;lt;/tt&amp;gt; element in the file menu for example indicates that any part containing actions in a file menu should list its parts after the file_open action and before the file_quit action.&lt;br /&gt;
&lt;br /&gt;
=== CMakeLists.txt ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini n&amp;gt;&lt;br /&gt;
&lt;br /&gt;
project(kparttut1)&lt;br /&gt;
&lt;br /&gt;
FIND_PACKAGE(KDE4 REQUIRED)&lt;br /&gt;
INCLUDE_DIRECTORIES( ${KDE4_INCLUDES} . )&lt;br /&gt;
&lt;br /&gt;
set(kparttut1_SRCS&lt;br /&gt;
   main.cpp&lt;br /&gt;
   mainwindow.cpp&lt;br /&gt;
 )&lt;br /&gt;
&lt;br /&gt;
kde4_add_executable(kparttut1 ${kparttut1_SRCS})&lt;br /&gt;
&lt;br /&gt;
target_link_libraries(kparttut1 ${KDE4_KDEUI_LIBS} ${KDE4_KPARTS_LIBS})&lt;br /&gt;
&lt;br /&gt;
########### install files ###############&lt;br /&gt;
install(TARGETS kparttut1 DESTINATION ${BIN_INSTALL_DIR} )&lt;br /&gt;
install( FILES kparttut1ui.rc &lt;br /&gt;
    DESTINATION  ${DATA_INSTALL_DIR}/kparttut1 )&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Die CMakeLists.txt Datei ist in diesem Fall sehr einfach.&lt;br /&gt;
&lt;br /&gt;
== Die Applikation ausführen ==&lt;br /&gt;
&lt;br /&gt;
Nach dem Kompilieren der Appikation kann diese mit&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
kparttut1 filename&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
ausgeführt werden. filename ist dabei eine Textdatei, die geladen werden soll. Eine der Quellcodedateien wäre ein gutes Beispiel dafür.&lt;br /&gt;
&lt;br /&gt;
Wenn die Datei geladen wird, steht einem ein kompletter kate-Editor in seinem eigenen Fenster zu Verfügung. Alle Features des Editors sind über die Werkzeugleiste und Menüs verfügbar.&lt;br /&gt;
&lt;br /&gt;
Weiterhin fällt die 'Öffnen' Aktion auf, welche in der MainWindow class definiert wurde und auch in der Werkzeugleiste und im Menü neben der 'Beenden' Aktion erscheint.&lt;br /&gt;
&lt;br /&gt;
Die nächste Anleitung wird sich mit dem Erzeugen eigener kparts für die Benutzung in anderen Applikationen beschäftigen.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-05-05T18:03:46Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Even some more translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; Hauptunterverzeichnis ist dasjenige, in dem die Hauptentwicklung an KDE stattfindet. Was Sie hier finden, wird als nächstes als KDE und assoziierte Programme veröffentlicht. Hier finden Sie auch das &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; Modul, welches die Webpages rund um KDE beinhaltet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; ist unterteilt in folgende Unterverzeichnisse:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE selber, welches die nächste Veröffentlichung werden wird. Es besteht aus folgenden Modulen:&lt;br /&gt;
**'''kdelibs''' - KDE Hauptbibliotheken, die von allen KDE Programmen benutzt werden&lt;br /&gt;
**'''kdebase''' - KDE Basisprogramme, wie das KDE Control Center, Plasma (die Oberfläche) und Konqueror (der Web Browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility Dateien&lt;br /&gt;
**'''kdeadmin''' - KDE Administrationsprogramme&lt;br /&gt;
**'''kdeartwork''' - Bilder, Themen, Sounds und andere künstlerische Dateien&lt;br /&gt;
**'''kdebindings''' - Bindungen für andere Sprache außer C++&lt;br /&gt;
**'''kdeedu''' - Erzieherische und Wissenschaftliche Programme für KDE&lt;br /&gt;
**'''kdegames''' - KDE Spiele&lt;br /&gt;
**'''kdegraphics''' - KDE Graphikapplicationen&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimediaapplicationen&lt;br /&gt;
**'''kdenetwork''' - KDE Netzwerkapplicationen&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management Applicationen &lt;br /&gt;
**'''kdepimlibs''' - Biblotheken, die von KDE-PIM Applicationen benötigt werden.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit Applicationen&lt;br /&gt;
**'''kdetoys''' - KDE Spielzeug Applicationen&lt;br /&gt;
**'''kdeutils''' - Allgemeine KDE Werkzeuge&lt;br /&gt;
**'''kdevelop''' - Das KDevelop Programm&lt;br /&gt;
**'''kdevplatform''' - Die Entwicklerplatform auf der KDevelop basiert&lt;br /&gt;
**'''kdewebdev''' - Eine KDE Webentwicklungsapplikation&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Allgemeines admin/ Verzeichnis&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] Dateien&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der Inhalt von developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE Programme die sich außerhalb der Haupt KDE Veröffentlichungen aufhalten&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Vorübergehende Heimat für all die KDE Applikationen, von denen geglaubt wird, daß sie reif für eine Veröffentlichung sind. Von hier aus werden die Applikationen entweder nach &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; oder nach &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt; verschoben, sobald die größten Probleme ausgeräumt sind.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Unterstützende Programme und Bibliotheken für KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;Das KDE Office Paket, welches folgende Programme beinhaltet:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, das KDE build Programm&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für die &amp;quot;unstabilen&amp;quot; Module von KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der KDE Spielplatz: Applications die gerade entwickelt werden aber noch keine Veröffentlichungsqualität erreicht haben.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Zu Vereinfachung eine Kopie von  [http://www.trolltech.com/ Trolltechs] Qt Bibliothek, auf welcher KDE basiert.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice und ksvg Testfälle&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Die Valgrind Application, welche im KDE Repository betreut wird jedoch kein Teil von KDE selber ist. Neuere Versionen von Valgrind werden in einem eigenen Repository entwickelt. Das KDE Valgrind Modul beinhaltet nur Valgrind bis zur Version 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages für die KDE Site (und verwandte Sites). Schreibzugriff auf dieses Verzeichnis ist beschränkt.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die offiziellen Veröffentlichung von den Programmen die im KDE Repository verwaltet und entwickelt werden. Jede einzelne Applikation hat hier ein Unterverzeichnis, innerhalb von diesem finden Sie die Release-Nummern.&lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der Code für KDE 3.4.0 unter &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die Zweig-versionen von Applikationen nach einer Hauptveröffentlichung. &lt;br /&gt;
&lt;br /&gt;
Die meisten KDE Applikationen halten sich an die Philosophie, dass neue Features (ebenso wie neue Zeichneketten für den Benutzer) erst im nächsten Veröffentlichungszyklus &amp;amp;#8212; derjenige der in &amp;lt;tt&amp;gt;/trunkg/&amp;lt;/tt&amp;gt; entwickelt wird &amp;amp;#8212; einfließen. Fehlerbereinigungen werden jedoch auf alle Applikationen angewandt, auch nach einer Veröffentlichung.&lt;br /&gt;
&lt;br /&gt;
Um das zu bewerkstelligen, wird ein Zwei in dem Moment der Veröffentlichung erzeugt und zeigt damit den Status dieser Dateien zu diesem Zeitpunkt an. Fehlerbereinigungn werden dann in diese Dateien eingepflegt. Diese Zweige sind dann diejenigen die unter &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt; zu finden sind. &lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der KDE 3.4.x Zweig unter &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
Die Unterverzeichnisse die Sie in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; finden, sie die Unterverzeichnisse der Aplikationen wie &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. Sie finden hier auch ein &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
Unterverzeichnis, welches die offiziellen KDE Veröffentlichung beinhalten.&lt;br /&gt;
&lt;br /&gt;
Es gibt ein spezielles Unterverzeichnis in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; namens &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. Dieses Unterverzeichnis wird als &amp;quot;Arbeitszweig&amp;quot; berzeichnet und beinhaltet Zweige bei denen an neuen Features gearbeitet wird. Manchmal sind diese sehr experimentell. Arbeitszweige für mehrere Applikationen finden sich in &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, doch für einzelne Applikationen finden sich Arbeitszweige im jeweiligen Unterverzeichnis. Diese Entscheidung liegt bei den Entwicklern. &lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
Um entwas aus Subversion auszuchecken benutzt man das Unterkommando &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
'''WARNUNG:''' Wenn Sie trunk/KDE oder branches/KDE/foo auschecken werden Sie auch die komplette kde-i18n herunterladen!&lt;br /&gt;
&lt;br /&gt;
Angenommen Sie wollen nur KDevelop aus dem KDE Repository auschecken, würden Sie folgende Kommandos eingeben:&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
&lt;br /&gt;
CVS Benutzer die einen ssh Zugang besitzen, sollten das Protokoll svn+ssh,&lt;br /&gt;
CVS Benutzer, die einen Passwortzugang benutzen sollten das Protokoll https im folgenden benutzen.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
Um zu aktualisieren, benutzen Sie das &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; Unterkommando.&lt;br /&gt;
&lt;br /&gt;
Hier gibt es keinen Unterschied zu CVS: Sie wechseln in ihre ausgecheckte lokale Kopie (für diejenigen, für die das alles neu ist: die ausgecheckte Kopie sollte sich in Ihrem Heimatordner befinden) und geben ein &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; Kommando (oder kürzer &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
Um herauszufinden welche lokalen Dateien verändert wurden, haben die meisten unter CVS das Kommando cvs up aufgerufen und dann diejenigen Dateien gesucht, die mit einem '''M''' markiert waren. Das funktioniert unter svn nicht, daher müssen Sie das Kommando &amp;lt;tt&amp;gt;svn status&amp;lt;/tt&amp;gt; aufrufen, um den Status der Dateien zu ermitteln.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Um Änderungen hochzuladen ruft man, ähnlich wie bei CVS, die Unterkommandos &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (Kurzversion davon &amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt;) auf.&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # oder&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci&lt;br /&gt;
 # oder&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Auf diese Weise wird &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; den in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; eingetragenen Texteditor aufrufen, damit Sie das Änderungsprotokoll ausfüllen können. Wenn Sie es vorziehen, können Sie &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; auch über die -m Option eine vollständige Mitteilung übergeben:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-03-09T15:55:13Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Some more translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; Hauptunterverzeichnis ist dasjenige, in dem die Hauptentwicklung an KDE stattfindet. Was Sie hier finden, wird als nächstes als KDE und assoziierte Programme veröffentlicht. Hier finden Sie auch das &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; Modul, welches die Webpages rund um KDE beinhaltet.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; ist unterteilt in folgende Unterverzeichnisse:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE selber, welches die nächste Veröffentlichung werden wird. Es besteht aus folgenden Modulen:&lt;br /&gt;
**'''kdelibs''' - KDE Hauptbibliotheken, die von allen KDE Programmen benutzt werden&lt;br /&gt;
**'''kdebase''' - KDE Basisprogramme, wie das KDE Control Center, Plasma (die Oberfläche) und Konqueror (der Web Browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility Dateien&lt;br /&gt;
**'''kdeadmin''' - KDE Administrationsprogramme&lt;br /&gt;
**'''kdeartwork''' - Bilder, Themen, Sounds und andere künstlerische Dateien&lt;br /&gt;
**'''kdebindings''' - Bindungen für andere Sprache außer C++&lt;br /&gt;
**'''kdeedu''' - Erzieherische und Wissenschaftliche Programme für KDE&lt;br /&gt;
**'''kdegames''' - KDE Spiele&lt;br /&gt;
**'''kdegraphics''' - KDE Graphikapplicationen&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimediaapplicationen&lt;br /&gt;
**'''kdenetwork''' - KDE Netzwerkapplicationen&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management Applicationen &lt;br /&gt;
**'''kdepimlibs''' - Biblotheken, die von KDE-PIM Applicationen benötigt werden.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit Applicationen&lt;br /&gt;
**'''kdetoys''' - KDE Spielzeug Applicationen&lt;br /&gt;
**'''kdeutils''' - Allgemeine KDE Werkzeuge&lt;br /&gt;
**'''kdevelop''' - Das KDevelop Programm&lt;br /&gt;
**'''kdevplatform''' - Die Entwicklerplatform auf der KDevelop basiert&lt;br /&gt;
**'''kdewebdev''' - Eine KDE Webentwicklungsapplikation&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Allgemeines admin/ Verzeichnis&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] Dateien&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der Inhalt von developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE Programme die sich außerhalb der Haupt KDE Veröffentlichungen aufhalten&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Vorübergehende Heimat für all die KDE Applikationen, von denen geglaubt wird, daß sie reif für eine Veröffentlichung sind. Von hier aus werden die Applikationen entweder nach &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; oder nach &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt; verschoben, sobald die größten Probleme ausgeräumt sind.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Unterstützende Programme und Bibliotheken für KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;Das KDE Office Paket, welches folgende Programme beinhaltet:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, das KDE build Programm&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für die &amp;quot;unstabilen&amp;quot; Module von KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Übersetzungen für KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Der KDE Spielplatz: Applications die gerade entwickelt werden aber noch keine Veröffentlichungsqualität erreicht haben.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Zu Vereinfachung eine Kopie von  [http://www.trolltech.com/ Trolltechs] Qt Bibliothek, auf welcher KDE basiert.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice und ksvg Testfälle&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Die Valgrind Application, welche im KDE Repository betreut wird jedoch kein Teil von KDE selber ist. Neuere Versionen von Valgrind werden in einem eigenen Repository entwickelt. Das KDE Valgrind Modul beinhaltet nur Valgrind bis zur Version 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages für die KDE Site (und verwandte Sites). Schreibzugriff auf dieses Verzeichnis ist beschränkt.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die offiziellen Veröffentlichung von den Programmen die im KDE Repository verwaltet und entwickelt werden. Jede einzelne Applikation hat hier ein Unterverzeichnis, innerhalb von diesem finden Sie die Release-Nummern.&lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der Code für KDE 3.4.0 unter &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
Dieses Verzeichnis beinhaltet die Zweig-versionen von Applikationen nach einer Hauptveröffentlichung. &lt;br /&gt;
&lt;br /&gt;
Die meisten KDE Applikationen halten sich an die Philosophie, dass neue Features (ebenso wie neue Zeichneketten für den Benutzer) erst im nächsten Veröffentlichungszyklus &amp;amp;#8212; derjenige der in &amp;lt;tt&amp;gt;/trunkg/&amp;lt;/tt&amp;gt; entwickelt wird &amp;amp;#8212; einfließen. Fehlerbereinigungen werden jedoch auf alle Applikationen angewandt, auch nach einer Veröffentlichung.&lt;br /&gt;
&lt;br /&gt;
Um das zu bewerkstelligen, wird ein Zwei in dem Moment der Veröffentlichung erzeugt und zeigt damit den Status dieser Dateien zu diesem Zeitpunkt an. Fehlerbereinigungn werden dann in diese Dateien eingepflegt. Diese Zweige sind dann diejenigen die unter &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt; zu finden sind. &lt;br /&gt;
&lt;br /&gt;
So kann zum Beispiel der KDE 3.4.x Zweig unter &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt; gefunden werden.&lt;br /&gt;
&lt;br /&gt;
Die Unterverzeichnisse die Sie in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; finden, sie die Unterverzeichnisse der Aplikationen wie &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. Sie finden hier auch ein &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
Unterverzeichnis, welches die offiziellen KDE Veröffentlichung beinhalten.&lt;br /&gt;
&lt;br /&gt;
Es gibt ein spezielles Unterverzeichnis in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; namens &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. Dieses Unterverzeichnis wird als &amp;quot;Arbeitszweig&amp;quot; berzeichnet und beinhaltet Zweige bei denen an neuen Features gearbeitet wird. Manchmal sind diese sehr experimentell. Arbeitszweige für mehrere Applikationen finden sich in &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, doch für einzelne Applikationen finden sich Arbeitszweige im jeweiligen Unterverzeichnis. Diese Entscheidung liegt bei den Entwicklern. &lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
Um entwas aus Subversion auszuchecken benutzt man das Unterkommando &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt;:&lt;br /&gt;
&lt;br /&gt;
'''WARNUNG:''' Wenn Sie trunk/KDE oder branches/KDE/foo auschecken werden Sie auch die komplette kde-i18n herunterladen!&lt;br /&gt;
&lt;br /&gt;
Angenommen Sie wollen nur KDevelop aus dem KDE Repository auschecken, würden Sie folgende Kommandos eingeben:&lt;br /&gt;
&lt;br /&gt;
CVS Kommando:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion Kommando:&lt;br /&gt;
&lt;br /&gt;
CVS Benutzer die einen ssh Zugang besitzen, sollten das Protokoll svn+ssh,&lt;br /&gt;
CVS Benutzer, die einen Passwortzugang benutzen sollten das Protokoll https im folgenden benutzen.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-01-31T16:02:44Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Some more translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
Um das KDE Subversion Repository benutzen zu können, benötigen Sie zwei Dinge:&lt;br /&gt;
&lt;br /&gt;
# Ein Subversion Client Programm&lt;br /&gt;
# Einen Zugang zu unserem Repository&lt;br /&gt;
&lt;br /&gt;
Beachte: Für einen anonymen nur-lesen Zugriff benutzen Sie das Protokoll &amp;quot;svn&amp;quot;, kein &amp;quot;yourname@&amp;quot; den Server &amp;quot;anonsvn.kde.org&amp;quot; statt dem unten genannten.&lt;br /&gt;
&lt;br /&gt;
'''Subversion installieren:''' Eine Anleitung zur Installtion des Client Programms wird hier nicht gegeben. Sehen Sie in den Installtionsanleitungen Ihres Systems nach, um herauszufinden, wie man Subversion installiert. Sie benötigen mindesten Version 1.1. Wenn Sie Subversion selber compilieren und Sie auf das Repository per https (und nicht über svn+ssh) zugreifen wollen, benötigen Sie SSL und ZLIB Unterstützung und müssen daher die &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; Option übergeben. &lt;br /&gt;
&lt;br /&gt;
Alternativ können Sie auch einen der zahlreich vefügbaren graphischen Clients installieren. Diese Anleitung wendet sich an personen, die nur das &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; Programm benutzen und bezieht sich dabei auf Dinge die mit dem alten &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; Programm erledigt wurden.&lt;br /&gt;
&lt;br /&gt;
'''Ein Benutzerkonto bekommen:''' Hatten Sie vorher ein CVS Benutzerkonto, wurde dieses zum neuen Subversion Client migriert. Wenn nicht, sehen Sie in der  [[Contribute/Get_a_SVN_Account|entsprechenden Anleitung]] nach, wie man eines bekommt. &lt;br /&gt;
&lt;br /&gt;
{{Note (de)|Wenn Sie ihr CVS Passwort verloren haben, gibt es einfache Wege, dieses zu ermitteln. Benutzen Sie [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] pder [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
ist die Adresse des KDE Subversion Repositorys. Das Repository wird über das HTTPS oder SVN-SSH Protokoll angesrochen, was bedeutet, dass Ihr Passwort sicher gegenüber Abhörversuche dritter ist. &lt;br /&gt;
&lt;br /&gt;
Der SSL certificate md5 fingerprint für die Repositorys ist:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
Der SSL certificate sha1 fingerprint für die Repositorys ist:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
Für Personen, die svn+ssh benutzen ist hier der Fingerprint des RSA Schlüssels des Servers:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
Das Repository ist in Hauptverzeichnisse organisiert:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
Man kann das Repository durchforgsten über [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt;&lt;br /&gt;
top-level subdirectory is where the main development for KDE occurs.&lt;br /&gt;
What you will find here is what will become the next KDE release, and&lt;br /&gt;
its associated programs. Here you will also find the &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; module,&lt;br /&gt;
which contains webpages for KDE's site and related ones.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; is further subdivided into these sub-directories:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE itself, what will become the next public release. It contains the following modules:&lt;br /&gt;
**'''kdelibs''' - KDE basic libraries, used by all KDE programs&lt;br /&gt;
**'''kdebase''' - KDE base programs, like the KDE Control Center, Kicker (the panel) and Konqueror (the web browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility files&lt;br /&gt;
**'''kdeadmin''' - KDE Administration applications&lt;br /&gt;
**'''kdeartwork''' - Images, themes, sounds and other art files&lt;br /&gt;
**'''kdebindings''' - Bindings for languages other than C++&lt;br /&gt;
**'''kdeedu''' - KDE Educational applications&lt;br /&gt;
**'''kdegames''' - KDE Games&lt;br /&gt;
**'''kdegraphics''' - KDE Graphical applications&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimedia applications&lt;br /&gt;
**'''kdenetwork''' - KDE Networking applications&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management applications&lt;br /&gt;
**'''kdepimlibs''' - Libraries used by KDE-PIM applications.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit applications&lt;br /&gt;
**'''kdetoys''' - KDE toy applications&lt;br /&gt;
**'''kdeutils''' - KDE General utilities&lt;br /&gt;
**'''kdevelop''' - The KDevelop program&lt;br /&gt;
**'''kdevplatform''' - The development platform which KDevelop is based on&lt;br /&gt;
**'''kdewebdev''' - KDE Web development applications&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Common admin/ directory&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] files&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The content of developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE programs outside the main KDE releases.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Temporary home for KDE applications that are believed to have reached release-quality. From here, once all major issues are resolved, applications are moved either to &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; or to &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Supporting applications and libraries for KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;The KDE Office suite, containing the programs:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, the KDE build program&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for the &amp;quot;unstable&amp;quot; modules of KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The KDE playground: applications being developed, but not having yet reached release-quality.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The convenience copy of [http://www.trolltech.com/ Trolltech's] Qt library, which KDE is based upon.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice and ksvg testcases&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The Valgrind application, which is hosted on the KDE repository, but that is not part of KDE itself.  Note that newer versions of Valgrind are developed on their own repository.  The KDE Valgrind modules only holds up to Valgrind 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages for the KDE site (and related sites). Write access to this directory is restricted.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This&lt;br /&gt;
directory contains the official releases of the programs maintained and&lt;br /&gt;
developed in the KDE repository. Each individual application has a&lt;br /&gt;
subdirectory here. Inside it, you will find the release numbers.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.0 code can be found under &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This directory contains the branch versions of the applications after a major release.&lt;br /&gt;
&lt;br /&gt;
Most&lt;br /&gt;
KDE applications adhere to the philosphy that new features (as well as&lt;br /&gt;
new user-visible strings) are added only to the next release cycle &amp;amp;#8212;&lt;br /&gt;
the one that lives in &amp;lt;tt&amp;gt;/trunk/&amp;lt;/tt&amp;gt;. However, bugfixes are applied to all&lt;br /&gt;
applications, even after release.&lt;br /&gt;
&lt;br /&gt;
In&lt;br /&gt;
order to do that, a branch is created at the moment of the release,&lt;br /&gt;
indicating the state of the files at that time. Bugfixes are then&lt;br /&gt;
checked in to those files. Those branches are the ones in &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.x branch can be found under &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The subdirectories you will find inside &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; are the&lt;br /&gt;
application subdirs, like &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. You will also find a &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
subdir, containing the official KDE releases since time immemorial.&lt;br /&gt;
&lt;br /&gt;
One special subdir is found in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt;: &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. This&lt;br /&gt;
subdir contains the so-called &amp;quot;work branches&amp;quot;, that is, branches containing&lt;br /&gt;
features being worked on, sometimes highly experimental. Multi-application&lt;br /&gt;
work branches always are checked in to &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, but&lt;br /&gt;
single-application branches may be found in each application's subdir. That&lt;br /&gt;
is a decision left to the developers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
In order to check out something with Subversion, you use the &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
'''WARNING:''' If you checkout trunk/KDE/ or branches/KDE/foo/ you will download complete kde-i18n!&lt;br /&gt;
&lt;br /&gt;
Suppose you wanted to check out only KDevelop from the KDE repository. You would do:&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
&lt;br /&gt;
CVS users currently using ssh access, should use protocol svn+ssh,&lt;br /&gt;
CVS users currently using password access, should use protocol https&lt;br /&gt;
in the following.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
Siehe auch [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] für mehr Informationen über Subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-01-19T06:43:09Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Zusammenfassung */ Typo&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt, um auf Dateien und Software im KDE Repository zuzugreifen. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
In order to use the KDE Subversion repository, you will need two things:&lt;br /&gt;
&lt;br /&gt;
# A Subversion client program&lt;br /&gt;
# An account in our repository&lt;br /&gt;
&lt;br /&gt;
Note: For anonymous read-only access use protocol &amp;quot;svn&amp;quot;, no &amp;quot;yourname@&amp;quot; and server &amp;quot;anonsvn.kde.org&amp;quot; instead below.&lt;br /&gt;
&lt;br /&gt;
'''Installing Subversion:''' instructions on installing the client are not&lt;br /&gt;
presented here. Refer to your system installation instructions to find out how&lt;br /&gt;
you can install Subversion. You will need version 1.1 at least. If you are&lt;br /&gt;
compiling from sources and want to access the KDE repository by https&lt;br /&gt;
(and not by svn+ssh), you will need SSL and ZLIB support,&lt;br /&gt;
so you will need the &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; options.&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can install one of the many graphical clients out there.&lt;br /&gt;
This tutorial is intended for people using the &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; program only, referring&lt;br /&gt;
to tasks accomplished with the usual &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; program.&lt;br /&gt;
&lt;br /&gt;
'''Getting an account:''' if you had a CVS&lt;br /&gt;
account before, it has been migrated to the new Subversion client. If&lt;br /&gt;
you didn't, refer to the [[Contribute/Get_a_SVN_Account|corresponding tutorial]] how to get one.&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|If you have lost your CVS password, there are simple ways to retrieve&lt;br /&gt;
it. Use [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] or [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
That's the address of the KDE Subversion repository. The repository is served by&lt;br /&gt;
HTTPS or SVN+SSH protocol, which means your password is secure against third-party&lt;br /&gt;
eavesdropping.&lt;br /&gt;
&lt;br /&gt;
The SSL certificate md5 fingerprint for the repositories:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
The SSL certificate sha1 fingerprint for the repositories:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
For people using svn+ssh, here's the fingerprint of the server's RSA key:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
The repository is organised in main directories:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
You can explore the repository structure at [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt;&lt;br /&gt;
top-level subdirectory is where the main development for KDE occurs.&lt;br /&gt;
What you will find here is what will become the next KDE release, and&lt;br /&gt;
its associated programs. Here you will also find the &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; module,&lt;br /&gt;
which contains webpages for KDE's site and related ones.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; is further subdivided into these sub-directories:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE itself, what will become the next public release. It contains the following modules:&lt;br /&gt;
**'''kdelibs''' - KDE basic libraries, used by all KDE programs&lt;br /&gt;
**'''kdebase''' - KDE base programs, like the KDE Control Center, Kicker (the panel) and Konqueror (the web browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility files&lt;br /&gt;
**'''kdeadmin''' - KDE Administration applications&lt;br /&gt;
**'''kdeartwork''' - Images, themes, sounds and other art files&lt;br /&gt;
**'''kdebindings''' - Bindings for languages other than C++&lt;br /&gt;
**'''kdeedu''' - KDE Educational applications&lt;br /&gt;
**'''kdegames''' - KDE Games&lt;br /&gt;
**'''kdegraphics''' - KDE Graphical applications&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimedia applications&lt;br /&gt;
**'''kdenetwork''' - KDE Networking applications&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management applications&lt;br /&gt;
**'''kdepimlibs''' - Libraries used by KDE-PIM applications.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit applications&lt;br /&gt;
**'''kdetoys''' - KDE toy applications&lt;br /&gt;
**'''kdeutils''' - KDE General utilities&lt;br /&gt;
**'''kdevelop''' - The KDevelop program&lt;br /&gt;
**'''kdevplatform''' - The development platform which KDevelop is based on&lt;br /&gt;
**'''kdewebdev''' - KDE Web development applications&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Common admin/ directory&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] files&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The content of developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE programs outside the main KDE releases.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Temporary home for KDE applications that are believed to have reached release-quality. From here, once all major issues are resolved, applications are moved either to &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; or to &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Supporting applications and libraries for KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;The KDE Office suite, containing the programs:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, the KDE build program&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for the &amp;quot;unstable&amp;quot; modules of KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The KDE playground: applications being developed, but not having yet reached release-quality.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The convenience copy of [http://www.trolltech.com/ Trolltech's] Qt library, which KDE is based upon.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice and ksvg testcases&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The Valgrind application, which is hosted on the KDE repository, but that is not part of KDE itself.  Note that newer versions of Valgrind are developed on their own repository.  The KDE Valgrind modules only holds up to Valgrind 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages for the KDE site (and related sites). Write access to this directory is restricted.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This&lt;br /&gt;
directory contains the official releases of the programs maintained and&lt;br /&gt;
developed in the KDE repository. Each individual application has a&lt;br /&gt;
subdirectory here. Inside it, you will find the release numbers.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.0 code can be found under &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This directory contains the branch versions of the applications after a major release.&lt;br /&gt;
&lt;br /&gt;
Most&lt;br /&gt;
KDE applications adhere to the philosphy that new features (as well as&lt;br /&gt;
new user-visible strings) are added only to the next release cycle &amp;amp;#8212;&lt;br /&gt;
the one that lives in &amp;lt;tt&amp;gt;/trunk/&amp;lt;/tt&amp;gt;. However, bugfixes are applied to all&lt;br /&gt;
applications, even after release.&lt;br /&gt;
&lt;br /&gt;
In&lt;br /&gt;
order to do that, a branch is created at the moment of the release,&lt;br /&gt;
indicating the state of the files at that time. Bugfixes are then&lt;br /&gt;
checked in to those files. Those branches are the ones in &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.x branch can be found under &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The subdirectories you will find inside &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; are the&lt;br /&gt;
application subdirs, like &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. You will also find a &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
subdir, containing the official KDE releases since time immemorial.&lt;br /&gt;
&lt;br /&gt;
One special subdir is found in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt;: &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. This&lt;br /&gt;
subdir contains the so-called &amp;quot;work branches&amp;quot;, that is, branches containing&lt;br /&gt;
features being worked on, sometimes highly experimental. Multi-application&lt;br /&gt;
work branches always are checked in to &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, but&lt;br /&gt;
single-application branches may be found in each application's subdir. That&lt;br /&gt;
is a decision left to the developers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
In order to check out something with Subversion, you use the &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
'''WARNING:''' If you checkout trunk/KDE/ or branches/KDE/foo/ you will download complete kde-i18n!&lt;br /&gt;
&lt;br /&gt;
Suppose you wanted to check out only KDevelop from the KDE repository. You would do:&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
&lt;br /&gt;
CVS users currently using ssh access, should use protocol svn+ssh,&lt;br /&gt;
CVS users currently using password access, should use protocol https&lt;br /&gt;
in the following.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
See [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] for more&lt;br /&gt;
information about subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-01-18T16:41:53Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Zusammenfassung */ Translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Der folgende Text ist eine schnelle kde-spezifische Einführung, wie man Subversion benutzt um auf Dateien und Software im KDE Repository zugreift. Für einen vollständigen Überblick über die Fähigkeiten von Subversion verweisen wir auf das Buch &amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion (englisch)]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
In order to use the KDE Subversion repository, you will need two things:&lt;br /&gt;
&lt;br /&gt;
# A Subversion client program&lt;br /&gt;
# An account in our repository&lt;br /&gt;
&lt;br /&gt;
Note: For anonymous read-only access use protocol &amp;quot;svn&amp;quot;, no &amp;quot;yourname@&amp;quot; and server &amp;quot;anonsvn.kde.org&amp;quot; instead below.&lt;br /&gt;
&lt;br /&gt;
'''Installing Subversion:''' instructions on installing the client are not&lt;br /&gt;
presented here. Refer to your system installation instructions to find out how&lt;br /&gt;
you can install Subversion. You will need version 1.1 at least. If you are&lt;br /&gt;
compiling from sources and want to access the KDE repository by https&lt;br /&gt;
(and not by svn+ssh), you will need SSL and ZLIB support,&lt;br /&gt;
so you will need the &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; options.&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can install one of the many graphical clients out there.&lt;br /&gt;
This tutorial is intended for people using the &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; program only, referring&lt;br /&gt;
to tasks accomplished with the usual &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; program.&lt;br /&gt;
&lt;br /&gt;
'''Getting an account:''' if you had a CVS&lt;br /&gt;
account before, it has been migrated to the new Subversion client. If&lt;br /&gt;
you didn't, refer to the [[Contribute/Get_a_SVN_Account|corresponding tutorial]] how to get one.&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|If you have lost your CVS password, there are simple ways to retrieve&lt;br /&gt;
it. Use [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] or [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
That's the address of the KDE Subversion repository. The repository is served by&lt;br /&gt;
HTTPS or SVN+SSH protocol, which means your password is secure against third-party&lt;br /&gt;
eavesdropping.&lt;br /&gt;
&lt;br /&gt;
The SSL certificate md5 fingerprint for the repositories:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
The SSL certificate sha1 fingerprint for the repositories:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
For people using svn+ssh, here's the fingerprint of the server's RSA key:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
The repository is organised in main directories:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
You can explore the repository structure at [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt;&lt;br /&gt;
top-level subdirectory is where the main development for KDE occurs.&lt;br /&gt;
What you will find here is what will become the next KDE release, and&lt;br /&gt;
its associated programs. Here you will also find the &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; module,&lt;br /&gt;
which contains webpages for KDE's site and related ones.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; is further subdivided into these sub-directories:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE itself, what will become the next public release. It contains the following modules:&lt;br /&gt;
**'''kdelibs''' - KDE basic libraries, used by all KDE programs&lt;br /&gt;
**'''kdebase''' - KDE base programs, like the KDE Control Center, Kicker (the panel) and Konqueror (the web browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility files&lt;br /&gt;
**'''kdeadmin''' - KDE Administration applications&lt;br /&gt;
**'''kdeartwork''' - Images, themes, sounds and other art files&lt;br /&gt;
**'''kdebindings''' - Bindings for languages other than C++&lt;br /&gt;
**'''kdeedu''' - KDE Educational applications&lt;br /&gt;
**'''kdegames''' - KDE Games&lt;br /&gt;
**'''kdegraphics''' - KDE Graphical applications&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimedia applications&lt;br /&gt;
**'''kdenetwork''' - KDE Networking applications&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management applications&lt;br /&gt;
**'''kdepimlibs''' - Libraries used by KDE-PIM applications.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit applications&lt;br /&gt;
**'''kdetoys''' - KDE toy applications&lt;br /&gt;
**'''kdeutils''' - KDE General utilities&lt;br /&gt;
**'''kdevelop''' - The KDevelop program&lt;br /&gt;
**'''kdevplatform''' - The development platform which KDevelop is based on&lt;br /&gt;
**'''kdewebdev''' - KDE Web development applications&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Common admin/ directory&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] files&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The content of developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE programs outside the main KDE releases.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Temporary home for KDE applications that are believed to have reached release-quality. From here, once all major issues are resolved, applications are moved either to &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; or to &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Supporting applications and libraries for KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;The KDE Office suite, containing the programs:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, the KDE build program&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for the &amp;quot;unstable&amp;quot; modules of KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The KDE playground: applications being developed, but not having yet reached release-quality.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The convenience copy of [http://www.trolltech.com/ Trolltech's] Qt library, which KDE is based upon.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice and ksvg testcases&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The Valgrind application, which is hosted on the KDE repository, but that is not part of KDE itself.  Note that newer versions of Valgrind are developed on their own repository.  The KDE Valgrind modules only holds up to Valgrind 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages for the KDE site (and related sites). Write access to this directory is restricted.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This&lt;br /&gt;
directory contains the official releases of the programs maintained and&lt;br /&gt;
developed in the KDE repository. Each individual application has a&lt;br /&gt;
subdirectory here. Inside it, you will find the release numbers.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.0 code can be found under &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This directory contains the branch versions of the applications after a major release.&lt;br /&gt;
&lt;br /&gt;
Most&lt;br /&gt;
KDE applications adhere to the philosphy that new features (as well as&lt;br /&gt;
new user-visible strings) are added only to the next release cycle &amp;amp;#8212;&lt;br /&gt;
the one that lives in &amp;lt;tt&amp;gt;/trunk/&amp;lt;/tt&amp;gt;. However, bugfixes are applied to all&lt;br /&gt;
applications, even after release.&lt;br /&gt;
&lt;br /&gt;
In&lt;br /&gt;
order to do that, a branch is created at the moment of the release,&lt;br /&gt;
indicating the state of the files at that time. Bugfixes are then&lt;br /&gt;
checked in to those files. Those branches are the ones in &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.x branch can be found under &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The subdirectories you will find inside &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; are the&lt;br /&gt;
application subdirs, like &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. You will also find a &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
subdir, containing the official KDE releases since time immemorial.&lt;br /&gt;
&lt;br /&gt;
One special subdir is found in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt;: &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. This&lt;br /&gt;
subdir contains the so-called &amp;quot;work branches&amp;quot;, that is, branches containing&lt;br /&gt;
features being worked on, sometimes highly experimental. Multi-application&lt;br /&gt;
work branches always are checked in to &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, but&lt;br /&gt;
single-application branches may be found in each application's subdir. That&lt;br /&gt;
is a decision left to the developers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
In order to check out something with Subversion, you use the &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
'''WARNING:''' If you checkout trunk/KDE/ or branches/KDE/foo/ you will download complete kde-i18n!&lt;br /&gt;
&lt;br /&gt;
Suppose you wanted to check out only KDevelop from the KDE repository. You would do:&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
&lt;br /&gt;
CVS users currently using ssh access, should use protocol svn+ssh,&lt;br /&gt;
CVS users currently using password access, should use protocol https&lt;br /&gt;
in the following.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
See [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] for more&lt;br /&gt;
information about subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture_(de)</id>
		<title>Development/Architecture (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture_(de)"/>
				<updated>2008-01-18T16:39:22Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Design Dokumente */ Translated titles&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture}}&lt;br /&gt;
Die folgenden Seiten beinhalten detailierte Dokumentationen über das Design und die Architektur von KDE. Sie ersetzen nicht die anderen Dokumentationen wie [http://api.kde.org API Dokumentation (englisch)], [[../Tutorials|tutorials/howtos]] und [[../Guidelines|standards]], siehe auch das [[Development (de)|Entwickler Portal]] für weitere Informationen.&lt;br /&gt;
&lt;br /&gt;
Für ein besseren Verständnis könnte es helfen sich mit Trolltech's&amp;amp;trade; excellenter [http://doc.trolltech.com/3.3/index.html Qt 3.3] oder [http://doc.trolltech.com/4.3/index.html Qt 4.3] Dokumentation und deren [http://www.trolltech.com/developer/ Entwickler Seiten] zu beschäftigen.&lt;br /&gt;
&lt;br /&gt;
Für mehr Informationen über eine KDE Installtion sehen Sie bitte auch die entsprechenden Kapitel in [[KDE System Administration|System Administration]].&lt;br /&gt;
&lt;br /&gt;
== Design Dokumente ==&lt;br /&gt;
; [[Development/Architecture/KDE4|Überblick über die KDE 4 Architektur]]&lt;br /&gt;
: Ein Überblick über die KDE 4 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 4.0''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/KDE3|Überblick über die KDE 3 Architektur]] [http://developer.kde.org/documentation/library/kdeqt/kde3arch/ (Original)]&lt;br /&gt;
: Ein Überblick über die KDE 3 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 3.0''.&lt;br /&gt;
&lt;br /&gt;
; [http://developer.kde.org/documentation/library/kdeqt/kde2arch/ Überblick über die KDE 2 Architektur]&lt;br /&gt;
: Ein Überblick über die KDE 2 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 2.2''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/DCOP|DCOP]]&lt;br /&gt;
: Design Dokumente von 1999-2000.&lt;br /&gt;
&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Contribute_(de)</id>
		<title>Contribute (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Contribute_(de)"/>
				<updated>2008-01-18T16:35:03Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Neuigkeiten und Post Quellen */ Changed translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Contribute}}&lt;br /&gt;
Diese Seite versucht einen Überblick über die verschiedenen Aspekte der KDE-Entwicklung, insbesondere der Programmierung zu bieten. '''Das KDE-Projekt heißt jeden willkommen der helfen möchte'''.&lt;br /&gt;
&lt;br /&gt;
{{note|Es gibt viele Wege um sich in der KDE-Entwicklung zu engagieren, welche in folgende Kategorien gegliedert werden können:&lt;br /&gt;
:''Dokumentation, Übersetzung, Entwicklung, Benutzerfreundlichkeit, Barrierefreiheit, Künstlerische Arbeit, Vermarktung&lt;br /&gt;
'''Besonders für Aufgaben neben der Entwicklung (Programmierung) geben die KDE-Seiten [http://kde.org/getinvolved/ wie man sich beteiligt] einen guten Überblick.'''&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Neuigkeiten und eMail Quellen ==&lt;br /&gt;
Die generelle Richtung des KDE-Projektes wird von denen bestimmt, die die Arbeit machen - es existiert kein übergeordneter Plan der festlegt wie KDE in der Zukunft aussehen soll.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie sich über das gegenwärtige Geschehen informieren möchten, können sie folgende Quellen nutzen:&lt;br /&gt;
; [http://www.kde.org/mailinglists/ Mailinglisten]&lt;br /&gt;
: Wahrscheinlich der beste Weg um herauszufinden was sich in der KDE-Entwicklung ereignet. Archive sind [http://lists.kde.org hier] verfügbar.&lt;br /&gt;
&lt;br /&gt;
; [http://commitfilter.kde.org/ CommitFilter]&lt;br /&gt;
: Hier erhalten Sie Benachrichtigungen über [http://de.wikipedia.org/wiki/Subversion_(Software) SVN]-Transaktionen die Sie interessieren.&lt;br /&gt;
&lt;br /&gt;
; [http://commit-digest.org/ KDE Commit-Digest]&lt;br /&gt;
: Eine wöchentliche Zusammenfassung der SVN-Transaktionen.&lt;br /&gt;
&lt;br /&gt;
; [http://dot.kde.org/ The Dot]&lt;br /&gt;
: Die KDE-Nachrichtenseite.&lt;br /&gt;
&lt;br /&gt;
== Mit dem Programmieren beginnen ==&lt;br /&gt;
Mit dem Programmieren beginnen heißt, etwas zum Ausbessern zu finden und es auszubessern. Um zu finden was Sie suchen, können Sie die Modul-Übersicht zur Hilfe nehmen. Sobald Sie etwas ausgebessert haben, können Sie einen Patch zuschicken. Nachdem Sie es einige Male gemacht haben, können Sie einen SVN-Account beantragen, so dass Sie die Dinge direkt verändern können.&lt;br /&gt;
* [[Contribute/List of KDE Modules|Modul-Übersicht]]&lt;br /&gt;
* [[Contribute/Send Patches|Patches zuschicken]]&lt;br /&gt;
* [[Contribute/Get a SVN Account|Einen KDE-SVN-Account beantragen]]&lt;br /&gt;
* [[Contribute/First Steps with your KDE SVN Account|Erste Schritte mit Ihren neuen SVN-Account]]&lt;br /&gt;
&lt;br /&gt;
Gegenwärtig existieren zwei Möglichkeiten der KDE-Entwicklung - Sie können an KDE 3 oder KDE 4 arbeiten. KDE 3 ist eine gute Wahl um Fehler zu beseitigen, die Hauptentwicklung (mit den neuen Features) findet jedoch in KDE 4 statt. Dieses Dokument bezieht sich hauptsächlich auf die Unterstützung von KDE 4.&lt;br /&gt;
&lt;br /&gt;
=== C++ ===&lt;br /&gt;
KDE ist hauptsächlich in C++ geschrieben. Wenn Sie nicht mit C++ vertraut sind, sollten Sie sich etwas einarbeiten. Es gibt eine Anzahl an guten Büchern für C++ - eine ausgezeichnete Quelle ist [http://mindview.net/Books/TICPP/ThinkingInCPP2e.html Bruce Eckel's &amp;quot;Thinking in C++&amp;quot;], welches als freier Download und in gedruckter Form erhältlich ist. Es ist nicht nötig alles zu verstehen bevor man an KDE beginnt, aber Sie müssen die grundlegende Syntax und den Arbeitsablauf verstehen.&lt;br /&gt;
&lt;br /&gt;
=== Qt ===&lt;br /&gt;
Um in der KDE-Programmierung Kompetenz zu erlangen, sollten Sie das Qt-Toolkit beherrschen. Wenn Sie nicht mit Qt vertraut sind, sollten Sie die in Qt ([http://doc.trolltech.com/latest/examples.html Version 4], [http://doc.trolltech.com/3.3/tutorial.html Version 3]) enthaltenen Übungen durchgehen.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie mehr zu Multimedia und Videos neigen, möchten Sie vielleicht zum Start zwei erstaunliche Minuten mit dem Video  [http://www.trolltech.com/trolltech/products/qt/learnmore/video/demos/browser Building a Simple Help Documentation Browser with Qt4 Designer] verbringen. Wenn es Ihre Aufmerksamkeit errang, können Sie auch die Video-Einführung [http://www.trolltechvideo.com/video/day1/room_a/a_1_1/video.html Hello Qt] von Mark Summerfield ansehen, welches ein Teil der  [http://www.trolltech.com/company/newsroom/events/allevents/devdays2006/videolinks Trolltech Developer Days 2006 presentations] ist.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie eine genauere Qt-Einführung oder nur eine alternative Sichtweise benötigen, dann können Sie einen Blick auf [http://qt4.digitalfanatics.org/tiqt/ The Independent Qt Tutorial] werfen (zurzeit offline wegen eines Buchvertrages).&lt;br /&gt;
&lt;br /&gt;
Mehr Anregungen wie man mit Qt 4 vertraut wird &lt;br /&gt;
[http://doc.trolltech.com/latest/how-to-learn-qt.html gibt es auch hier]. Eine Kopie des Dokumentes wird auch in Qt 4 bereitgestellt.&lt;br /&gt;
&lt;br /&gt;
=== KDE ===&lt;br /&gt;
Eine Auswahl an Informationen über die KDE-Techniken ist erhältlich in dem  [[Development/Tutorials|Einleitungsabschnitt]]. Beachten Sie dass einige der dortigen Einleitungen immer noch KDE 3 betreffen, welche jedoch zumindest teilweise übertragbar sind.&lt;br /&gt;
&lt;br /&gt;
Sie werden auch nützliche Informationen in dem [[Development/FAQs|FAQs]]-Abschnitt finden. Diese Informationen könnten für KDE 4 überholt sein, aber vieles ist allgemein anwendbar, sogar außerhalb von KDE.&lt;br /&gt;
&lt;br /&gt;
Sie können auch die [[Development/Further Information|KDE-Programmierungs-Bücher]] lesen.&lt;br /&gt;
&lt;br /&gt;
Als letztes, aber nicht minder wichtig: KDE kommt mit einer umfangreichen Klassen-Dokumentation (API, Application Programmer Interface). Diese ist im Abschnitt [[Development/Tutorials/API Documentation|KDE API Referenz Manuals]] erhältlich, welche auch eine Menge an nützlichen Verweisen über das Schreiben oder Aktualisieren einer Klassen-Dokumentation beinhaltet. Sie können diese auch entweder selber auf Ihrer eigenen Maschine herstellen oder auf eine aktuellere Online-Version des  [http://www.englishbreakfastnetwork.org/apidocs/apidox-kde-4.0/kdelibs-apidocs/ English Breakfast Network] zugreifen.&lt;br /&gt;
&lt;br /&gt;
Eine detailliertere Beschreibung der oben genannten Schritte ist erhältlich in unserem &lt;br /&gt;
[http://quality.kde.org/develop/howto/howtohack.php Programmierungs-Leitfaden].&lt;br /&gt;
&lt;br /&gt;
== Beteiligung an der Fehlerjagd und der Anwendungs-Qualität ==&lt;br /&gt;
&lt;br /&gt;
Es existieren eine Reihe Anwendungen innerhalb KDE und nicht alle haben einen zugeordneten Maintainer, der sich um Fehler und die allgemeinen Aufgaben, die das Umwandeln des funktionierenden Codes in eine ausgefeilte Anwendung kümmert.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie an einer Mitarbeit an KDE interessiert sind, aber nicht wissen wo Sie anfangen sollen, könnte Ihnen eine Mitgliedschaft in dem KDE-Qualitäts-Team gefallen - für weitere Informationen, sehen Sie dazu die [http://quality.kde.org Qualitäts-Team-Webseite] an. Sie brauchen keine Programmierfähigkeiten um sich zu beteiligen.&lt;br /&gt;
&lt;br /&gt;
Natürlich können Sie sich an der Fehlerjagd beteiligen ohne ein Teil des KDE-Qualitäts-Teams zu sein - erstellen Sie dazu einfach einen Account im [http://bugs.kde.org Fehlerverfolger], und starten Sie das Aussortieren / Suchen durch die Fehlermeldungen. &lt;br /&gt;
Nochmals, Sie brauchen keine Programmierfähigkeiten - es hilft den Programmierern enorm eine Vorgehensweise zu haben um einen Fehler reproduzieren zu können.&lt;br /&gt;
&lt;br /&gt;
Die [[Contribute/Bugsquad|Fehlertruppe]] versucht, den Fehlermeldungen zu folgen, und stellt sicher dass gültige Fehler von den Programmierern wahrgenommen werden. Sie brauchen kein Programmierwissen um in der Fehlertruppe zu sein; in der Tat, es ist ein großartiger Weg um der KDE-Gemeinschaft etwas zurückzugeben, wenn Sie nicht programmieren können.&lt;br /&gt;
&lt;br /&gt;
== Historische Quellen ==&lt;br /&gt;
&lt;br /&gt;
; [http://www.kerneltraffic.org/kde/ Kernel Cousin KDE]&lt;br /&gt;
: Eine Zusammenfassung der Entwicklungs-Mailinglisten. Der Kernel Cousin KDE erschien mit 76 Ausgaben vom 10 März 2001 bis zum 16 April 2004. Der KDE-Commit-Digest (oben beschrieben) ist sein logischer Nachfolger.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Architecture_(de)</id>
		<title>Development/Architecture (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Architecture_(de)"/>
				<updated>2008-01-18T14:15:35Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Architecture}}&lt;br /&gt;
Die folgenden Seiten beinhalten detailierte Dokumentationen über das Design und die Architektur von KDE. Sie ersetzen nicht die anderen Dokumentationen wie [http://api.kde.org API Dokumentation (englisch)], [[../Tutorials|tutorials/howtos]] und [[../Guidelines|standards]], siehe auch das [[Development (de)|Entwickler Portal]] für weitere Informationen.&lt;br /&gt;
&lt;br /&gt;
Für ein besseren Verständnis könnte es helfen sich mit Trolltech's&amp;amp;trade; excellenter [http://doc.trolltech.com/3.3/index.html Qt 3.3] oder [http://doc.trolltech.com/4.3/index.html Qt 4.3] Dokumentation und deren [http://www.trolltech.com/developer/ Entwickler Seiten] zu beschäftigen.&lt;br /&gt;
&lt;br /&gt;
Für mehr Informationen über eine KDE Installtion sehen Sie bitte auch die entsprechenden Kapitel in [[KDE System Administration|System Administration]].&lt;br /&gt;
&lt;br /&gt;
== Design Dokumente ==&lt;br /&gt;
; [[Development/Architecture/KDE4|KDE 4 Architecture Overview]]&lt;br /&gt;
: Ein Überblick über die KDE 4 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 4.0''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/KDE3|KDE 3 Architecture Overview]] [http://developer.kde.org/documentation/library/kdeqt/kde3arch/ (Original)]&lt;br /&gt;
: Ein Überblick über die KDE 3 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 3.0''.&lt;br /&gt;
&lt;br /&gt;
; [http://developer.kde.org/documentation/library/kdeqt/kde2arch/ KDE 2 Architecture Overview]&lt;br /&gt;
: Ein Überblick über die KDE 2 Architektur einschließlich Diskussionen über allgemeine Techniken, Bibliotheksklassen und allgemeine Entwicklerfragen. Gilt für ''KDE 2.2''.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Architecture/DCOP|DCOP]]&lt;br /&gt;
: Design Dokumente von 1999-2000.&lt;br /&gt;
&lt;br /&gt;
[[Category:Architecture]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)</id>
		<title>Getting Started/Sources/Subversion (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion_(de)"/>
				<updated>2008-01-18T13:59:54Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page copy from english version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anfang|&lt;br /&gt;
&lt;br /&gt;
name=Subversion mit KDE benutzen|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
This is a quick KDE-specific introduction for using subversion to access files and software in KDE's repositories. For comprehensive coverage of Subversion we recommend reading the book&lt;br /&gt;
&amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Am Anfang ==&lt;br /&gt;
&lt;br /&gt;
In order to use the KDE Subversion repository, you will need two things:&lt;br /&gt;
&lt;br /&gt;
# A Subversion client program&lt;br /&gt;
# An account in our repository&lt;br /&gt;
&lt;br /&gt;
Note: For anonymous read-only access use protocol &amp;quot;svn&amp;quot;, no &amp;quot;yourname@&amp;quot; and server &amp;quot;anonsvn.kde.org&amp;quot; instead below.&lt;br /&gt;
&lt;br /&gt;
'''Installing Subversion:''' instructions on installing the client are not&lt;br /&gt;
presented here. Refer to your system installation instructions to find out how&lt;br /&gt;
you can install Subversion. You will need version 1.1 at least. If you are&lt;br /&gt;
compiling from sources and want to access the KDE repository by https&lt;br /&gt;
(and not by svn+ssh), you will need SSL and ZLIB support,&lt;br /&gt;
so you will need the &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; options.&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can install one of the many graphical clients out there.&lt;br /&gt;
This tutorial is intended for people using the &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; program only, referring&lt;br /&gt;
to tasks accomplished with the usual &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; program.&lt;br /&gt;
&lt;br /&gt;
'''Getting an account:''' if you had a CVS&lt;br /&gt;
account before, it has been migrated to the new Subversion client. If&lt;br /&gt;
you didn't, refer to the [[Contribute/Get_a_SVN_Account|corresponding tutorial]] how to get one.&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|If you have lost your CVS password, there are simple ways to retrieve&lt;br /&gt;
it. Use [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] or [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== Die Struktur des KDE Repository  ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
That's the address of the KDE Subversion repository. The repository is served by&lt;br /&gt;
HTTPS or SVN+SSH protocol, which means your password is secure against third-party&lt;br /&gt;
eavesdropping.&lt;br /&gt;
&lt;br /&gt;
The SSL certificate md5 fingerprint for the repositories:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
The SSL certificate sha1 fingerprint for the repositories:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
For people using svn+ssh, here's the fingerprint of the server's RSA key:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
The repository is organised in main directories:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
You can explore the repository structure at [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis /trunk ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt;&lt;br /&gt;
top-level subdirectory is where the main development for KDE occurs.&lt;br /&gt;
What you will find here is what will become the next KDE release, and&lt;br /&gt;
its associated programs. Here you will also find the &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; module,&lt;br /&gt;
which contains webpages for KDE's site and related ones.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; is further subdivided into these sub-directories:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE itself, what will become the next public release. It contains the following modules:&lt;br /&gt;
**'''kdelibs''' - KDE basic libraries, used by all KDE programs&lt;br /&gt;
**'''kdebase''' - KDE base programs, like the KDE Control Center, Kicker (the panel) and Konqueror (the web browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility files&lt;br /&gt;
**'''kdeadmin''' - KDE Administration applications&lt;br /&gt;
**'''kdeartwork''' - Images, themes, sounds and other art files&lt;br /&gt;
**'''kdebindings''' - Bindings for languages other than C++&lt;br /&gt;
**'''kdeedu''' - KDE Educational applications&lt;br /&gt;
**'''kdegames''' - KDE Games&lt;br /&gt;
**'''kdegraphics''' - KDE Graphical applications&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimedia applications&lt;br /&gt;
**'''kdenetwork''' - KDE Networking applications&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management applications&lt;br /&gt;
**'''kdepimlibs''' - Libraries used by KDE-PIM applications.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit applications&lt;br /&gt;
**'''kdetoys''' - KDE toy applications&lt;br /&gt;
**'''kdeutils''' - KDE General utilities&lt;br /&gt;
**'''kdevelop''' - The KDevelop program&lt;br /&gt;
**'''kdevplatform''' - The development platform which KDevelop is based on&lt;br /&gt;
**'''kdewebdev''' - KDE Web development applications&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Common admin/ directory&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] files&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The content of developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE programs outside the main KDE releases.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Temporary home for KDE applications that are believed to have reached release-quality. From here, once all major issues are resolved, applications are moved either to &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; or to &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Supporting applications and libraries for KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;The KDE Office suite, containing the programs:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, the KDE build program&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for the &amp;quot;unstable&amp;quot; modules of KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The KDE playground: applications being developed, but not having yet reached release-quality.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The convenience copy of [http://www.trolltech.com/ Trolltech's] Qt library, which KDE is based upon.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice and ksvg testcases&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The Valgrind application, which is hosted on the KDE repository, but that is not part of KDE itself.  Note that newer versions of Valgrind are developed on their own repository.  The KDE Valgrind modules only holds up to Valgrind 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages for the KDE site (and related sites). Write access to this directory is restricted.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This&lt;br /&gt;
directory contains the official releases of the programs maintained and&lt;br /&gt;
developed in the KDE repository. Each individual application has a&lt;br /&gt;
subdirectory here. Inside it, you will find the release numbers.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.0 code can be found under &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Das Unterverzeichnis &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This directory contains the branch versions of the applications after a major release.&lt;br /&gt;
&lt;br /&gt;
Most&lt;br /&gt;
KDE applications adhere to the philosphy that new features (as well as&lt;br /&gt;
new user-visible strings) are added only to the next release cycle &amp;amp;#8212;&lt;br /&gt;
the one that lives in &amp;lt;tt&amp;gt;/trunk/&amp;lt;/tt&amp;gt;. However, bugfixes are applied to all&lt;br /&gt;
applications, even after release.&lt;br /&gt;
&lt;br /&gt;
In&lt;br /&gt;
order to do that, a branch is created at the moment of the release,&lt;br /&gt;
indicating the state of the files at that time. Bugfixes are then&lt;br /&gt;
checked in to those files. Those branches are the ones in &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.x branch can be found under &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The subdirectories you will find inside &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; are the&lt;br /&gt;
application subdirs, like &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. You will also find a &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
subdir, containing the official KDE releases since time immemorial.&lt;br /&gt;
&lt;br /&gt;
One special subdir is found in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt;: &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. This&lt;br /&gt;
subdir contains the so-called &amp;quot;work branches&amp;quot;, that is, branches containing&lt;br /&gt;
features being worked on, sometimes highly experimental. Multi-application&lt;br /&gt;
work branches always are checked in to &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, but&lt;br /&gt;
single-application branches may be found in each application's subdir. That&lt;br /&gt;
is a decision left to the developers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Auschecken und Aktualisieren ==&lt;br /&gt;
&lt;br /&gt;
=== Auschecken ===&lt;br /&gt;
In order to check out something with Subversion, you use the &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
'''WARNING:''' If you checkout trunk/KDE/ or branches/KDE/foo/ you will download complete kde-i18n!&lt;br /&gt;
&lt;br /&gt;
Suppose you wanted to check out only KDevelop from the KDE repository. You would do:&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
&lt;br /&gt;
CVS users currently using ssh access, should use protocol svn+ssh,&lt;br /&gt;
CVS users currently using password access, should use protocol https&lt;br /&gt;
in the following.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Aktualisieren ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Den Status einer Datei ermitteln ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Ins Repository hochladen ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Dateien ignorieren ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Unterverzeichnisse von anderen Orten verlinken ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== Mehr Informationen im KDE Wiki ==&lt;br /&gt;
&lt;br /&gt;
See [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] for more&lt;br /&gt;
information about subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Build/KDE4_(de)</id>
		<title>Getting Started/Build/KDE4 (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Build/KDE4_(de)"/>
				<updated>2008-01-18T13:45:10Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Changed to german templates&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting_Started/Build/KDE4}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Vorbereitungen|&lt;br /&gt;
&lt;br /&gt;
name=KDE4 aus dem Quellcode bauen|&lt;br /&gt;
&lt;br /&gt;
pre=[[../../Sources/Anonymous_SVN|Anonymous SVN Quickstart Guide]]|&lt;br /&gt;
&lt;br /&gt;
next=[[../../Set_up_KDE_4_for_development|Set up KDE 4 for development]]|&lt;br /&gt;
&lt;br /&gt;
reading=[http://kdesvn-build.kde.org/ kdesvn-build: The KDE From Subversion Build Tool]&amp;lt;br&amp;gt;[[../../Increased_Productivity_in_KDE4_with_Scripts|Increased Productivity in KDE4 with Scripts]]&amp;lt;br&amp;gt;[[Development/Tutorials/CMake |Introduction to CMake]]&amp;lt;br&amp;gt;[[../KDE4/FreeBSD|FreeBSD notes]]&amp;lt;br&amp;gt;[[../KDE4/Mac OS X|Instructions for Mac OS X]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Übersicht ==&lt;br /&gt;
&lt;br /&gt;
Diese Anleitung zeigt einen Weg, KDE auf Linux- und BSD-Systemen&lt;br /&gt;
zu komplieren und auszuführen. Als Grundlage verwenden wir die Shell.&lt;br /&gt;
Wenn Sie sich für die Installation auf anderen Systeme wie etwa Solaris, MacOS oder Microsoft Windows interessieren, besuchen Sie bitte [[../|Build]] und folgen Sie den Links am Ende der Seite.&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Stellen Sie sich auf verstärkt auftretende Buildprobleme '''an Montagen''' ein, da die Entwickler an diesem Wochentag kritische Änderungen vornehmen. Das [http://developer.kde.org/~dirk/dashboard/ Dashboard] zeigt unerwartete Probleme beim Kompilieren an.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Benötigte Software ==&lt;br /&gt;
&lt;br /&gt;
Folgendes muss installiert sein, um dieses Tutorial erfolgreich durchführen zu können:&lt;br /&gt;
* gcc und g++ vom gcc Projekt, vorzugsweise Version 4.1 oder höher&lt;br /&gt;
* svn, der subversion revision control client&lt;br /&gt;
* pkg-config&lt;br /&gt;
* devel-(Entwicklungs-)Bibliotheken und -header für X11, OpenGL (mesa-common-dev und libglu1-mesa-dev), libjpeg, libpng, libungif, [http://clucene.sourceforge.net/index.php/Downloads libclucene], [http://download.librdf.org/source/ librdf], libxml2 und libxslt&lt;br /&gt;
* Das &amp;lt;tt&amp;gt;makeobj&amp;lt;/tt&amp;gt; Skript, welches Teil von kdesdk ist. Sie können es als Teil von kdesdk (kdesdk-scripts in Debian) installieren oder von hier einzeln herunterladen: [http://websvn.kde.org/*checkout*/trunk/KDE/kdesdk/scripts/makeobj WebSVN]&lt;br /&gt;
* das [http://freedesktop.org/wiki/Software/shared-mime-info shared-mime-info Paket], welches der freedesktop-MIME-Standard ist, den KDE nun nutzt&lt;br /&gt;
* [http://boost.org/ boost], welches von kdebase gebraucht wird. Nach dem Kompilieren und/oder Installieren von boost fügen Sie das boost-Verzeichnis (das, welches das include-Unterverzeichnis enthält) zu CMAKE_INCLUDE_PATH hinzu, oder kreieren Sie eine Umgebungsvariable namens BOOST_ROOT, die zum boost-Verzeichnis verweist, um cmake den Ort von boost mitzuteilen (FindBoost).&lt;br /&gt;
&lt;br /&gt;
Weiterhin ist es zu empfehlen, folgende Software bereits installiert zu haben:&lt;br /&gt;
* bash&lt;br /&gt;
&lt;br /&gt;
=== Kubuntu ===&lt;br /&gt;
&lt;br /&gt;
In Kubuntu 7.04 (Feisty) können alle zum Bau der Pakete benötigte Software mit folgendem Befehl installiert werden:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
sudo aptitude install build-essential cdbs debhelper cmake libungif4-dev \&lt;br /&gt;
libxml2-dev libxslt1-dev libbz2-dev libclucene-dev librdf-dev \&lt;br /&gt;
shared-mime-info libgl1-mesa-dev libglu1-mesa-dev mesa-common-dev \&lt;br /&gt;
libxext-dev libjpeg-dev libpng-dev libsm-dev libxinerama-dev \&lt;br /&gt;
libxrender-dev libfontconfig-dev libboost-dev libxcursor-dev doxygen&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die manuelle Installation von Qt 4.3, CMake 2.4.6 und DBus kann durch die Installation der folgenden Pakete und ihrer Abhängigkeiten vermieden werden:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
sudo aptitude install libqt4-dev-kdecopy libdbus-1-dev cmake&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Alle KDE-Releases nach Alpha1 funktionieren nur mit Qt4.3. Kubuntu hat aber nur Pakete für Qt 4.3-Beta. Um neuere Versionen zu kompilieren, ist  das offizielle Release nötig.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
Für eine voll funktionstüchtige [[apidox]]-Umgebung wird ebenfalls zusätzliche Software benötigt:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
sudo aptitude install graphviz&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== openSUSE ===&lt;br /&gt;
{{note (de)|&lt;br /&gt;
Der openSUSE build service stellt ebenfalls tagesaktuelle KDE-4-Pakete bereit, die das gesamte auf dieser Seite beschriebene Vorgehen überflüssig machen. Weitere Informationen findet man direkt im openSUSE wiki unter [http://de.opensuse.org/KDE4 KDE4].&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
In OpenSuse können Pakete mit Hilfe von [http://de.opensuse.org/Zypper Zypper] installiert werden:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
sudo zypper install &amp;lt;package-name&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
In älteren SUSE-Versionen geht dies nur mit Yast:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
yast2 -i &amp;lt;packagename&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die meisten zum Bau von KDE 4 nötigen Pakete sind:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
xorg-x11-devel, libxml2-devel, kdesdk3, clucene-core-devel, libjpeg-devel, liblrdf-devel, libpng-devel, libxslt-devel, Mesa-devel, giflib-devel, subversion, gcc, gcc-c++&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Bereits vorkompilierte CMake-Pakete für openSUSE sind direkt verfügbar im  [http://software.opensuse.org/download/devel:/tools:/building/ openSUSE build service].&lt;br /&gt;
&lt;br /&gt;
=== Gentoo ===&lt;br /&gt;
&lt;br /&gt;
Sie können die stabilen ebuilds verwenden. Vergessen Sie nur nicht, ihr Portage zu synchronisieren, bevor Sie fortfahren.&lt;br /&gt;
&lt;br /&gt;
Von folgenden Paketen müssen instabile Versionen verwendet werden. Um das zu erreichen, nehmen Sie die Paketnamen in die Datei &amp;lt;code&amp;gt;package.keywords&amp;lt;/code&amp;gt; auf.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
# echo 'x11-libs/qt' &amp;gt;&amp;gt; /etc/portage/package.keywords&lt;br /&gt;
# echo 'dev-util/cmake' &amp;gt;&amp;gt; /etc/portage/package.keywords&lt;br /&gt;
# echo 'dev-cpp/clucene' &amp;gt;&amp;gt; /etc/portage/package.keywords&lt;br /&gt;
# echo '&amp;gt;dev-cpp/clucene-0.9.16a' &amp;gt;&amp;gt; /etc/portage/package.mask&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Dies sind die zu installierenden Pakete. Einige könnten bereits installiert sein. Diese können übersprungen werden, indem das &amp;quot;update&amp;quot;-flag in emerge gesetzt wird.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
$ emerge -avu ebuild/name&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
 sys-devel/gcc&lt;br /&gt;
 dev-util/subversion&lt;br /&gt;
 dev-util/pkgconfig&lt;br /&gt;
 x11-base/xorg-x11&lt;br /&gt;
 media-libs/glut&lt;br /&gt;
 media-libs/mesa&lt;br /&gt;
 media-libs/jpeg&lt;br /&gt;
 media-libs/libpng&lt;br /&gt;
 media-libs/giflib&lt;br /&gt;
 dev-cpp/clucene&lt;br /&gt;
 dev-util/cppunit&lt;br /&gt;
 media-libs/liblrdf&lt;br /&gt;
 dev-libs/libxml2&lt;br /&gt;
 dev-libs/libxslt&lt;br /&gt;
 x11-misc/shared-mime-info&lt;br /&gt;
 dev-libs/boost&lt;br /&gt;
 x11-libs/qt&lt;br /&gt;
 dev-util/cmake&lt;br /&gt;
 sys-apps/dbus&lt;br /&gt;
 redland&lt;br /&gt;
&lt;br /&gt;
Beginnen Sie nun, [[Getting_Started/Build/KDE4#Strigi|Strigi]] zu kompilieren.&lt;br /&gt;
&lt;br /&gt;
Viel Erfolg!&lt;br /&gt;
&lt;br /&gt;
== Ein Benutzer für die KDE-4-Entwicklung ==&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Einige Menschen ziehen es vor, für KDE 4 einen separaten Nutzer-Account einzurichten, um nicht aus Versehen durch noch bestehende Bugs oder ähnliches Daten zu verlieren. Die Anleitung hier basiert auf der Herangehensweise.&lt;br /&gt;
&lt;br /&gt;
Es ist jedoch deutlich effizienter alles mit einem einzigen Nutzer-Account zu machen. Unter [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts|Increased Productivity in KDE4 with Scripts]] findet man mehr Details dazu.&lt;br /&gt;
&lt;br /&gt;
In diesem Fall ist die folgende Anleitung noch immer gültig, jedoch sollten die nötigen Umgebungsvariablen nicht in die &amp;lt;tt&amp;gt;.bashrc&amp;lt;/tt&amp;gt;, sondern in eine separate Datei geschrieben werden, die dann bei Bedarf eingelesen wird.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== Option 1: Kommandozeile ===&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
useradd -m kde-devel&lt;br /&gt;
passwd kde-devel&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Option 2: Über KControl ===&lt;br /&gt;
&lt;br /&gt;
Anstatt der oben genannten Befehle kann man auch mit Hilfe des Benutzer-Moduls im KDE-Kontrollzentrum (kcontrol) einen weiteren Benutzer einrichten.&lt;br /&gt;
&lt;br /&gt;
=== Einrichten der Entwicklungsumgebung ===&lt;br /&gt;
&lt;br /&gt;
Kopieren Sie die Datei {{path|~/.bashrc}} von Ihrem normalen Benutzer-Account zu Ihrem neuen kde-devel-Account. Danach fügen Sie den Inhalt der Seite [[Getting Started/Increased Productivity in KDE4 with Scripts/.bashrc|example .bashrc]] in die Datei {{path|~kde-devel/.bashrc}} ein. Stellen Sie sicher, dass die Zeile &amp;lt;tt&amp;gt;alias make=makeobj&amp;lt;/tt&amp;gt; auskommentiert ist falls auf Ihrem System das Programm &amp;lt;tt&amp;gt;[[Getting Started/Build/KDE4#Required Software|makeobj]]&amp;lt;/tt&amp;gt; nicht verfügbar ist.&lt;br /&gt;
Die neue {{path|~/.bashrc}} wird mit folgendem Befehl eingelesen:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
source ~/.bashrc&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Nun haben Sie Zugriff auf Befehle wie &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt;, die in dieser Anleitung genutzt werden. Auch wird so sichergestellt, dass alle wichtigen Umgebungsvariablen (z. B. für die Pfadangaben von Qt, KDE und CMake) richtig gesetzt sind.&lt;br /&gt;
&lt;br /&gt;
Für weitere Informationen lesen Sie bitte [[Getting Started/Increased Productivity in KDE4 with Scripts]].&lt;br /&gt;
&lt;br /&gt;
=== Zum neuen Benutzer wechseln ===&lt;br /&gt;
&lt;br /&gt;
Sie können sich nun als Benutzer kde-devel anmelden (der Bindestrich ist wichtig!):&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
su - kde-devel&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Der Rest dieser Anleitung geht davon aus, dass Sie alle Befehle als &amp;lt;tt&amp;gt;kde-devel&amp;lt;/tt&amp;gt; ausführen.&lt;br /&gt;
&lt;br /&gt;
== Die Shell des Entwicklungsbenutzers ==&lt;br /&gt;
Auf manchen Systemen nutzen neue Benutzer standardmäßig {{path|/bin/sh}}. Wenn dies auf Ihrem System nicht der Fall ist, können Sie diesen Abschnitt überspringen. {{path|/bin/sh}} zu nutzen kann sich als sehr unangenehm erweisen. Daher sollten Sie erwägen, zu {{path|/bin/bash}} oder einer anderen Shell zu wechseln.&lt;br /&gt;
&lt;br /&gt;
=== Option 1: Als kde-devel-Benutzer ===&lt;br /&gt;
Wenn Sie keine root-Privilegien haben und Ihr System das Wechseln der eigenen Shell mittels &amp;lt;tt&amp;gt;chsh&amp;lt;/tt&amp;gt; unterstützt, können Sie versuchen, Ihre Shell zu {{path|/bin/bash}} zu wechseln, indem Sie Folgendes eingeben:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
chsh -s /bin/bash kde-devel&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Option 2: Als root-Benutzer ===&lt;br /&gt;
Wenn Ihr System die Anwendung &amp;lt;tt&amp;gt;usermod&amp;lt;/tt&amp;gt; beinhaltet, können Sie den folgenden Befehl als root-Benutzer eingeben: &amp;lt;tt&amp;gt;usermod -s /bin/bash kde-devel&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Eine weitere Möglichkeit ist die Nutzung der Anwendung &amp;lt;tt&amp;gt;vipw&amp;lt;/tt&amp;gt; als root-Benutzer, um auf sichere Art {{path|/etc/passwd}} zu editieren. Machen Sie 'kde-devel' in dieser Datei ausfindig und ändern Sie '{{path|/bin/sh}}' am Zeilenende in '{{path|/bin/bash}}'. Speichern Sie die Änderungen und beenden Sie die Anwendung.&lt;br /&gt;
&lt;br /&gt;
Die neue Shell wird automatisch gestartet wenn Sie sich wieder als kde-devel-Benutzer einloggen.&lt;br /&gt;
&lt;br /&gt;
== D-Bus ==&lt;br /&gt;
QtDBus und KDE arbeiten mit den D-Bus-Versionen 0.6.2, 0.92 und höher zusammen. Die Versionen 0.60 und 0.61 funktionieren eventuell auch, sind aber ungetestet. Die Versionen 0.90 und 0.91 funktionieren definitiv nicht.&lt;br /&gt;
&lt;br /&gt;
Wir empfehlen, dass Sie eine aktuelle, stabile Version, also größer Version 1.0, benutzen, wenigstens aber Version 0.94.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie eine aktuelle D-Bus-Version auf ihrem System bereits installiert haben oder Ihre D-Bus-Version nicht aktualisieren wollen, können Sie die nächste Sektion überspringen.&lt;br /&gt;
&lt;br /&gt;
Bevor Sie die nächsten Schritte durchgehen sollten Sie sicherstellen, dass die X11-header und -Bibliotheken installiert sind. Das Konfigurationsskript sollte in Zeile 5 Folgendes ausgeben:&lt;br /&gt;
 Building X11 code:        yes&lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
&lt;br /&gt;
{{tip|Stellen Sie sicher, dass Ihre Umgebung [[Getting_Started/Build/KDE4 (de)#Einrichten der Entwicklungsumgebung|wie beschrieben]] eingerichtet wurde. Das ist wichtig für das Funktionieren der &amp;lt;tt&amp;gt;cs&amp;lt;/tt&amp;gt;- und &amp;lt;tt&amp;gt;cb&amp;lt;/tt&amp;gt;-Befehle.}}&lt;br /&gt;
&lt;br /&gt;
 cs # [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|'cs' ist eine Bash-Funktion, klicken Sie hier, um mehr darüber zu lernen]] &lt;br /&gt;
 wget http://dbus.freedesktop.org/releases/dbus/dbus-1.0.2.tar.gz&lt;br /&gt;
 tar -xvzf dbus-1.0.2.tar.gz&lt;br /&gt;
 cd dbus-1.0.2/&lt;br /&gt;
 ./configure --prefix=$DBUSDIR --localstatedir=$KDEDIR/var&lt;br /&gt;
 make&lt;br /&gt;
 make install&lt;br /&gt;
 dbus-uuidgen --ensure&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert === &lt;br /&gt;
Wir wechseln in Zeile 1 in das Quellen-Verzeichnis, laden in Zeile 2 den Quellcode von freedesktop.org herunter und entpacken diesen in Zeile 3.&lt;br /&gt;
In Zeile 4 wechseln wir in das neu erstellte Verzeichnis, und bereiten in Zeile 5 das Kompilieren der Quelldateien vor. Zeile 6 setzt den Kompilier-Vorgang in Gang, Zeile 7 installiert D-Bus, und in Zeile 8 benutzen wir das &amp;lt;tt&amp;gt;dbus-uuidgen&amp;lt;/tt&amp;gt;-Werkzeug, um eine Maschinen-Identifikation zu installieren. Das erlaubt dem bus, automatisch mit der Desktop-Sitzung zu starten.&lt;br /&gt;
&lt;br /&gt;
Achten Sie darauf, dass Sie Schreibrechte auf {{path|/var}} haben, da Sie sie für die letzten beiden Schritte benötigen. Falls Ihr System kein sudo-Kommando unterstützt, können Sie auch &amp;lt;tt&amp;gt;su&amp;lt;/tt&amp;gt; benutzen, z. B. &amp;lt;tt&amp;gt;su -c &amp;quot;make install&amp;quot;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== Fehlerbehebung ===&lt;br /&gt;
&lt;br /&gt;
Falls Sie die Fehlermeldung '''makeobj: command not found''' bekommen fehlt Ihnen &amp;lt;tt&amp;gt;[[Getting_Started/Build/KDE4#Required_Software|makeobj]]&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== CMake ==&lt;br /&gt;
Überspringen Sie diesen Abschnitt, wenn Sie [http://cmake.org/ CMake] &amp;gt;=2.4.5 installiert haben.&lt;br /&gt;
Es sollte Ihnen möglich sein, die Binärpakete zu installieren, die hier verfügbar sind: [http://www.cmake.org/HTML/Download.html CMake site]. Dort sind ebenfalls distributionsspezifische Pakete zu finden.&lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
&amp;lt;!--'cs' and 'cb' are NOT typos!--&amp;gt;&lt;br /&gt;
 &lt;br /&gt;
 cs # [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|'cs' ist eine Bash-Funktion, klicken Sie hier, um mehr zu erfahren]] &lt;br /&gt;
 wget http://www.cmake.org/files/v2.4/cmake-2.4.6.tar.gz&lt;br /&gt;
 tar zxf cmake-2.4.6.tar.gz&lt;br /&gt;
 mkdir cmake-build&lt;br /&gt;
 cd cmake-build &lt;br /&gt;
 ../cmake-2.4.6/bootstrap&lt;br /&gt;
 make&lt;br /&gt;
 sudo make install&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert ===&lt;br /&gt;
Zuerst wechseln wir in das Quellverzeichnis des &amp;lt;tt&amp;gt;kde-devel&amp;lt;/tt&amp;gt;-Benutzers (Zeile 1), laden den CMake-Quellcode herunter (Zeile 2) und entpacken ihn (Zeile 3). Dann erstellen wir ein Verzeichnis, in dem wir CMake kompilieren (Zeile 4) und wechseln in dieses (Zeile 5). Hier führen wir das CMake-bootstrap-Skript aus (Zeile 6), dann den make-Befehl (Zeile 7) und schließlich die Installation als root-Benuzter (Zeile 8).&lt;br /&gt;
&lt;br /&gt;
Wenn Ihr System den &amp;lt;tt&amp;gt;sudo&amp;lt;/tt&amp;gt;-Befehl nicht beinhaltet, können Sie stattdessen Folgendes eingeben: &amp;lt;tt&amp;gt;su -c &amp;quot;make install&amp;quot;&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Qt ==&lt;br /&gt;
Als nächstes wird Qt 4 benötigt; es befindet sich im KDE-Quell-Repository. KDE kompiliert garantiert gegen jedes Qt der Version 4.3. Qt 4.2 und früher sind nicht unterstützt und funktionieren nicht. Da Qt 4.3 erst kürzlich veröffentlicht worden ist, finden sich wahrscheinlich noch keine Pakete für Ihre Distribution (bekannte Ausnahmen sind Kubuntu, Fedora 7 und openSUSE). Sie sollten die Kopie auf den KDE-Subversion-Servern verwenden.&lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
 cd&lt;br /&gt;
 svn checkout svn://anonsvn.kde.org/home/kde/trunk/qt-copy&lt;br /&gt;
 cd qt-copy&lt;br /&gt;
 ./apply_patches&lt;br /&gt;
 ./configure -qt-gif -no-exceptions -debug -fast \&lt;br /&gt;
  -prefix $QTDIR -qdbus -pch -nomake examples \&lt;br /&gt;
  -nomake demos&lt;br /&gt;
 make -j2&lt;br /&gt;
 # make install: Nur wenn QTDIR nicht das momentane Verzeichnis ist!&lt;br /&gt;
 make install&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert ===&lt;br /&gt;
Wir wechseln in das Heimverzeichnis des &amp;lt;tt&amp;gt;kde-devel&amp;lt;/tt&amp;gt;-Benutzers (Zeile 1) und laden den Quellcode mittels Subversion (svn) herunter (Zeile 2). Nach dem Wechsel in das daraus resultierende Verzeichnis {{path|qt-copy}} (Zeile 3), führen wir ein Skript aus, das die Patches integriert, die mit &amp;lt;tt&amp;gt;qt-copy&amp;lt;/tt&amp;gt; kommen (Zeile 4). &lt;br /&gt;
&lt;br /&gt;
Sobald die Patches integriert sind, konfigurieren wir das build mittels des &amp;lt;tt&amp;gt;configure&amp;lt;/tt&amp;gt;-Skripts (Zeilen 5-7). Die verschiedenen Kommandozeilenoptionen werden in der Datei {{path|qt-copy/README.qt-copy}} erläutert. Schließlich kompilieren wir die Mininalanforderungen für KDE (Zeile 8) und installieren Qt (Zeilen 9-10). Wenn Sie alle Beispiel- und Demo-Applikationen installieren möchten, können Sie sie entweder einzeln kompilieren oder einfach den Befehl &amp;lt;tt&amp;gt;make&amp;lt;/tt&amp;gt; im Verzeichnis {{path|qt-copy}} ausführen.&lt;br /&gt;
&lt;br /&gt;
Beachten Sie, dass die Installation keine root-Rechte verlangt, da Qt lokal in {{path|$QTDIR}} installiert wird. Die Installation ist ohnehin nur nötig, wenn {{path|$QTDIR}} sich von {{path|$HOME/qt-copy}} unterscheidet, was nicht der Fall ist, wenn Sie die Anweisungen exakt befolgt haben.&lt;br /&gt;
&lt;br /&gt;
=== Fehlerbehebung ===&lt;br /&gt;
Wenn Sie die Fehlerausgabe &amp;quot;error: X11/Xlib.h: No such file or directory&amp;quot; erhalten, installieren Sie das devel-Paket von &amp;lt;tt&amp;gt;xorg&amp;lt;/tt&amp;gt; (der Name des Pakets kann in verschiedenen Distributionen abweichen, in (K)Ubuntu z. B. ist er &amp;lt;tt&amp;gt;xorg-dev&amp;lt;/tt&amp;gt;). &lt;br /&gt;
&lt;br /&gt;
Wenn Sie eine Fehlermeldung im configure-Schritt erhalten, die auf &amp;quot;missing defines&amp;quot; hinweist, prüfen Sie den Wert von &amp;lt;tt&amp;gt;$QMAKESPEC&amp;lt;/tt&amp;gt;. Manche Distributionen lassen die Variable direkt auf das standardmäßig installierte Qt verweisen. Wenn der Befehl &amp;lt;tt&amp;gt;unset QMAKESPEC&amp;lt;/tt&amp;gt; das Problem löst, sollten Sie überlegen, ihn zum &amp;lt;tt&amp;gt;~/.bashrc&amp;lt;/tt&amp;gt;-Skript hinzuzufügen.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie die Fehlermeldung &amp;quot;.pch/debug-shared/QtCore&amp;quot; erhalten, bedeutet dies, dass Qt-4.3 zwar die vorkompilierten header aktiviert hat (wenn Ihr gcc dies unterstützt), es jedoch nicht funktioniert. Wenn Sie distcc nutzen, konfigurieren Sie Qt mit der Option -no-pch. Wenn Sie icecream nutzen, führen Sie ein Update zur neuesten Version von icecream im svn trunk durch.&lt;br /&gt;
&lt;br /&gt;
Versuchen Sie, irgendeine Qt-Applikation zu starten, beispielsweise {{program|assistant}}. Wenn sie in QSpanData::adjustSpanMethods abstürzt, haben Sie ein Problem mit dem Oxygen style. Versuchen Sie, {{path|lib/kde4/plugins/styles/kstyle-oxygen.so}} und {{path|lib/kde4/plugins/styles/oxygen.so}} zu entfernen, wenn sie sich im KDE-Installationspräfix finden.&lt;br /&gt;
&lt;br /&gt;
== kdesupport ==&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Wenn Sie diesen Abschnitt erreicht haben, ohne [[Getting_Started/Build/KDE4 (de)#Einrichten der Entwicklungsumgebung|Einrichten der Entwicklungsumgebung]] zu lesen, '''werden die hier angebotenen Rezepte nicht funktionieren'''. Diese Rezepte sind nicht defekt; &amp;lt;tt&amp;gt;cs&amp;lt;/tt&amp;gt; und &amp;lt;tt&amp;gt;cb&amp;lt;/tt&amp;gt; sind keine Tippfehler. Ihre Umgebung '''muss''' korrekt eingerichtet sein, damit diese Instruktionen funktionieren.}}&lt;br /&gt;
&lt;br /&gt;
Es gibt eine Reihe von Bibliotheken in kdesupport, von denen andere Programme abhängen. Das umfasst Strigi und Soprano für die Datei-Metadaten und für die Suche, eigen für visuelle Effekte z.B. in Kalzium, taglib für Musik-Programme und qca für Kryptographie-Unterstützung.&lt;br /&gt;
&lt;br /&gt;
Strigi selbst hat ebenfalls einige Abhängigkeiten: Sie benötigen die Bibliotheken von libz, libbz2, openssl (libcrypto oder libssl), libclucene (=0.9.16; Version 0.9.17 funktioniert '''nicht'''), und entweder libxml2 oder libexpat.&lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
&amp;lt;!--'cs' and 'cb' are NOT typos!--&amp;gt;&lt;br /&gt;
 cs # cs is kein Schreibfehler&lt;br /&gt;
 svn checkout svn://anonsvn.kde.org/home/kde/trunk/kdesupport/&lt;br /&gt;
 cd kdesupport&lt;br /&gt;
 cmakekde&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert ===&lt;br /&gt;
Wir wechseln in das Quellverzeichnis (Zeile 1), laden den Quellcode von kdesupport mittels Subversion herunter (Zeile 2) und wechseln anschließend in das neue Verzeichnis {{path|~/src/kdesupport}} (Zeile 3). Dann starten wir die Kompilierung (Zeile 4). Wir finden uns im Anschluss an die Kompilierung im build-Verzeichnis von kdesupport wieder.&lt;br /&gt;
&lt;br /&gt;
=== Troubleshooting ===&lt;br /&gt;
Wenn Sie folgende Fehlermeldung bekommen:&lt;br /&gt;
 CMake Error: This project requires some variables to be set,&lt;br /&gt;
 and cmake can not find them.&lt;br /&gt;
 Please set the following variables:&lt;br /&gt;
 LIBXML2_INCLUDE_DIR (ADVANCED)&lt;br /&gt;
dann sollten Sie das Entwicklerpaket für libxml2 installieren (z.B. libxml2-devel oder ähnlich).&lt;br /&gt;
&lt;br /&gt;
Wenn Sie&lt;br /&gt;
 CMake Error: Could NOT find REDLAND&lt;br /&gt;
erhalten, benötigen Sie librdf aus den Redland-Bibliotheken.&lt;br /&gt;
Wenn Ihre Distribution das librdf-Paket nicht zur Verfügung stellt, können Sie dessen Quellcode hier herunterladen [http://download.librdf.org/source/ http://download.librdf.org/source/] und selbst kompilieren. In Gentoo heißt das  Paket 'redland' anstatt librdf.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie &lt;br /&gt;
 Fetching external item into 'kdesupport/admin'&lt;br /&gt;
 Error validating server certificate for 'https://...'&lt;br /&gt;
erhalten, werfen Sie einen Blick auf [http://techbase.kde.org/Getting_Started/Sources/Using_Subversion_with_KDE Using Subversion with KDE]&lt;br /&gt;
&lt;br /&gt;
Bei der Fehlermeldung&lt;br /&gt;
 FILE cannot create directory: /usr/lib[64]/qt4/plugins/crypto&lt;br /&gt;
benötigen Sie zum Installieren des crypto-plugins Administrations-Rechte, vermutlich weil Sie die Systemweite Installation von qt4 verwenden. Am einfachsten ist es, Sie benutzen wie oben angegeben eine für den lokalen Nutzer erstellte.&lt;br /&gt;
&lt;br /&gt;
== kdelibs ==&lt;br /&gt;
Nachdem wir Qt 4 und Strigi kompiliert haben, können wir nun mit dem Kompilieren  der KDE-Basisbibliotheken fortschreiten. Wenn Sie die oben genannte Anleitung bezüglich [[Getting Started/Increased Productivity in KDE4 with Scripts/.bashrc|.bashrc]] nutzen, kommen Ihnen diese neuen Funktionen im Folgenden gelegen. &lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--'cs' und 'cb' sind KEINE Tippfehler!--&amp;gt;&lt;br /&gt;
 cd $KDE_SRC&lt;br /&gt;
 mkdir KDE &amp;amp;&amp;amp; cd KDE&lt;br /&gt;
 svn checkout svn://anonsvn.kde.org/home/kde/trunk/KDE/kdelibs&lt;br /&gt;
 cd kdelibs&lt;br /&gt;
 cmakekde&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert ===&lt;br /&gt;
Wir wechseln in das KDE-Quellverzeichnis (Zeile 1), erstellen ein Verzeichnis names KDE und wechseln in dieses (Zeile 2). Dann laden wir den Quellcode der kdelibs mittels Subversion herunter (Zeile 3), wechseln in das neue Verzeichnis {{path|~/src/KDE/kdelibs}} (Zeile 4) und starten die Kompilierung (Zeile 5). Wir finden uns anschließend im &amp;lt;tt&amp;gt;kdelibs&amp;lt;/tt&amp;gt;-build-Verzeichnis wieder.&lt;br /&gt;
&lt;br /&gt;
{{tip|Es könnte einige fehlende Anhängigkeiten auf Ihrem System geben! Sie können in der Ausgabe von &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt; leicht übersehen werden.&lt;br /&gt;
Sie können vor dem Kompilieren jeglicher KDE-Module (wie kdelibs, kdepimlibs usw.) &amp;lt;tt&amp;gt;cmake $KDE_SRC/KDE/MODULE_NAME&amp;lt;/tt&amp;gt; ausführen.}}&lt;br /&gt;
&lt;br /&gt;
=== Zusätzliche KDE-typische CMake-Module ===&lt;br /&gt;
Es gibt weitere CMake-Module in {{path|kdelibs/cmake/modules/}}, die für die Kompilierung von KDE4-Applikationen nötig sind. Sie werden mit kdelibs installiert (siehe unten).&lt;br /&gt;
&lt;br /&gt;
=== Fehlerbehebung ===&lt;br /&gt;
Wenn Sie Schwierigkeiten bei der Kompilierung von kdelibs haben, stellen Sie sicher, dass Sie die Software im obigen Abschnitt [[Getting_Started/Build/KDE4#Required_Software|Required Software]] installiert haben und dass sie funktioniert. Andere mögliche Probleme sind:&lt;br /&gt;
* Wenn der Befehl &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt; mit der Ausgabe fehlschlägt, dass CMake ein &amp;quot;out of source&amp;quot; build-Verzeichnis benötigt, entfernen Sie {{path|~/src/KDE/kdelibs/CMakeCache.txt}} und versuchen Sie es erneut.&lt;br /&gt;
&lt;br /&gt;
Wenn &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt; dennoch denselben Fehler ausgibt, versuchen Sie Folgendes:&lt;br /&gt;
 cd&lt;br /&gt;
 cmake -DCMAKE_INSTALL_PREFIX=$KDEDIR \&lt;br /&gt;
 -DCMAKE_BUILD_TYPE=debugfull \&lt;br /&gt;
 -DKDE4_BUILD_TESTS=ON \&lt;br /&gt;
 ~/src/KDE/kdelibs&lt;br /&gt;
 make&lt;br /&gt;
 make install&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;quot;Please create a separate build directory and run 'cmake path_to_kdelibs [options]' there.&amp;quot; erhalten, müssen Sie in Ihr build-Verzechnis wechseln bevor Sie cmakekde ausführen. (z. B. &amp;lt;tt&amp;gt;cs KDE/kdelibs &amp;amp;&amp;amp; cb &amp;amp;&amp;amp; cmakekde&amp;lt;/tt&amp;gt;)&lt;br /&gt;
* Wenn Qt nicht oder in einer falschen Version gefunden wird, stellen Sie sicher, dass das qmake der benötigten Qt-Version an erster Stelle (unter den qmake-Einträgen) im Pfad eingetragen ist.&lt;br /&gt;
* Wenn das Problem nach wie vor vorhanden ist, versuchen Sie die CMake make-Option &amp;lt;tt&amp;gt;--keep-going&amp;lt;/tt&amp;gt;.&lt;br /&gt;
* Sie benötigen die libungif-Bibliothek, ansonsten erhalten Sie eine Fehlerausgabe ähnlich &amp;quot;&amp;lt;tt&amp;gt;Could NOT find GIF&amp;lt;/tt&amp;gt;&amp;quot;.&lt;br /&gt;
* Qt-4.3-Upgrade: Wenn Sie einen Verknüpfnugsfehler in kjsembed erhalten, der auf die QScriptEngine bezogen ist, editieren Sie CMakeCache.txt in kdelibs und entfernen Sie die Zeilen, die sich auf QT_QTUITOOLS_LIBRARY beziehen, und führen Sie den make-Befehl erneut aus (diese statische Bibliothek hat eine neue Abhängigkeit und der cmake-Code, der diese hinzufügt, benötigt sie, um ausgeführt zu werden).&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;lt;code&amp;gt;CMake Error: KDE Requires Qt to be built with SSL support&amp;lt;/code&amp;gt; erhalten, installieren Sie openssl-devel, und rekompilieren Sie Qt.&lt;br /&gt;
&lt;br /&gt;
== kdepimlibs ==&lt;br /&gt;
Sie müssen ''kdepimlibs'' nach &amp;lt;tt&amp;gt;kdelibs&amp;lt;/tt&amp;gt;, aber vor ''kdebase'' installieren.&lt;br /&gt;
&lt;br /&gt;
=== Das Kochrezept ===&lt;br /&gt;
&lt;br /&gt;
&amp;lt;!--'cs' and 'cb' are NOT typos!--&amp;gt;&lt;br /&gt;
 cs KDE # [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|cs ist KEIN Tippfehler]]&lt;br /&gt;
 svn checkout svn://anonsvn.kde.org/home/kde/trunk/KDE/kdepimlibs&lt;br /&gt;
 cd kdepimlibs&lt;br /&gt;
 cmakekde&lt;br /&gt;
&lt;br /&gt;
=== Was hier passiert ===&lt;br /&gt;
Wir wechseln in das KDE-Quellverzeichnis (Zeile 1), laden den Quellcode für kdepimlibs mittels Subversion herunter (Zeile 2) und wechseln anschließend in das neue Verzeichnis {{path|~/src/KDE/kdepimlibs}} (Zeile 3). Dann starten wir die Kompilierung (Zeile 4). Wir finden uns im Anschluss an die Kompilierung im build-Verzeichnis von &amp;lt;tt&amp;gt;kdepimlibs&amp;lt;/tt&amp;gt; wieder.&lt;br /&gt;
&lt;br /&gt;
== kdebase ==&lt;br /&gt;
Für manche kioslaves könnte kdebase benötigt werden.&lt;br /&gt;
&amp;lt;!--'cs' and 'cb' are NOT typos!--&amp;gt;&lt;br /&gt;
 cs KDE # [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|cs ist KEIN Tippfehler]]&lt;br /&gt;
 svn checkout svn://anonsvn.kde.org/home/kde/trunk/KDE/kdebase&lt;br /&gt;
 cd kdebase&lt;br /&gt;
 cmakekde&lt;br /&gt;
&lt;br /&gt;
=== Fehlerbehebung ===&lt;br /&gt;
&lt;br /&gt;
Wenn Sie Schwierigkeiten beim Kompilieren von kdebase haben:&lt;br /&gt;
* Stellen Sie sicher, dass die &amp;lt;tt&amp;gt;libxss-Header&amp;lt;/tt&amp;gt; installiert sind. (Sollten diese nicht installiert sein, erhalten Sie in der Regel undefinierte Verweise auf xscreensaver-Objekte.)&lt;br /&gt;
* &amp;lt;tt&amp;gt;which meinproc&amp;lt;/tt&amp;gt; muss {{path|/home/kde-devel/kde/bin/meinproc}} ausgeben.&lt;br /&gt;
* Wenn cmakekde das kdepimlibs-Verzeichnis nicht finden kann, editieren Sie die Datei {{path|$KDE_BUILD/kdebase/CMakeCache.txt}} und definieren Sie &amp;lt;tt&amp;gt;KDEPIMLIBS_INCLUDE_DIR:PATH=$KDE_BUILD/kdepimlibs&amp;lt;/tt&amp;gt; manuell.&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;quot;Please set the following variables: X11_XTest_LIB (ADVANCED)&amp;quot; erhalten, installieren Sie das devel-Paket von &amp;lt;tt&amp;gt;Xtst&amp;lt;/tt&amp;gt;. Auf manchen Systemen ist es separat von &amp;lt;tt&amp;gt;xext&amp;lt;/tt&amp;gt; gepackt und heißt &amp;lt;tt&amp;gt;x11proto-xext-dev&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;libxtst-dev&amp;lt;/tt&amp;gt;. Sie müssen eventuell außerdem nach der Installation dieses Paketes die Datei CMakeCache.txt im build Verzeichnis löschen.&lt;br /&gt;
* Dasselbe gilt für die analoge Fehlerausgabe betreffend der Variable &amp;quot;X11_Xinerama_LIB (ADVANCED)&amp;quot;: Sie benötigen das devel-Paket für &amp;lt;tt&amp;gt;xinerama&amp;lt;/tt&amp;gt;.&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;quot;Please set the following variables: FONTCONFIG_INCLUDE_DIR, FONTCONFIG_LIBRARIES (ADVANCED)&amp;quot; erhalten, müssen Sie die libfontconfig-Header installieren.&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;quot;CMake Error: This project requires some variables to be set, and cmake can not find them. Please set the following variables: KMETADATA_LIBRARIES&amp;quot; erhalten, müssen Sie soprano aus kdesupport installieren und dann kdelibs neu kompilieren.&lt;br /&gt;
* Wenn Sie die Fehlerausgabe &amp;quot;‘XserverRegion’ does not name a type&amp;quot; erhalten, stellen Sie sicher, dass Sie die libxcomposite header installiert haben. (In Ubuntu heißen diese &amp;lt;tt&amp;gt;libxcomposite-dev&amp;lt;/tt&amp;gt;.)&lt;br /&gt;
&lt;br /&gt;
== Lokale API-Dokumentation erstellen ==&lt;br /&gt;
&lt;br /&gt;
Obwohl die API-Dokumentation für KDE online unter [http://api.kde.org api.kde.org] verfügbar ist, kann es hilfreich sein, sie offline verfügbar zu haben, zum Beispiel wenn Sie [[Getting_Started/Set_up_KDE_4_for_development#KDevelop|KDevelop]] zum Durchsuchen der Dokumentation nutzen oder wenn Sie nicht ständig online sein können.&lt;br /&gt;
&lt;br /&gt;
Seien Sie sich bewusst, dass das Generieren der API-Dokumentation mehrere Stunden in Anspruch nehmen kann und knapp ein halbes Gigabyte an Speicherplatz benötigt.&lt;br /&gt;
Das Generieren wird von einem Skript in {{path|kdelibs/doc/api}} ausgeführt; Sie benötigen &amp;lt;tt&amp;gt;doxygen&amp;lt;/tt&amp;gt;, um es ausführen zu können.&lt;br /&gt;
&lt;br /&gt;
Um die API-Dokumentation für kdelibs zu generieren, geben Sie Folgendes ein:&lt;br /&gt;
&amp;lt;!--'cs' und 'cb' sind KEINE Tippfehler!--&amp;gt;&lt;br /&gt;
 cs KDE/kdelibs # [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|cs ist KEIN Tippfehler]]&lt;br /&gt;
 $KDE_SRC/KDE/kdelibs/doc/api/doxygen.sh \&lt;br /&gt;
 --doxdatadir=$KDE_SRC/KDE/kdelibs/doc/common .&lt;br /&gt;
&lt;br /&gt;
Wiederholen Sie dies nach Bedarf für andere Module.&lt;br /&gt;
&lt;br /&gt;
== Auf dem neusten Stand bleiben ==&lt;br /&gt;
&lt;br /&gt;
Um die KDE Installation auf dem neusten Stand zu halten, sollte jedes der installierten Module regelmäßig aktualisiert werden. Da Montag der Tag mit den meisten Änderungen ist, kann Dienstag der beste Tag dazu sein. Führen Sie dazu für jedes der ausgecheckten Module, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; und &amp;lt;tt&amp;gt;make&amp;lt;/tt&amp;gt; aus.&lt;br /&gt;
&lt;br /&gt;
Zum Beispiel:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
cs kdesupport # cs is not a typo&lt;br /&gt;
svn up&lt;br /&gt;
cb # cb is not a typo&lt;br /&gt;
make -j2 VERBOSE=1 &amp;amp;&amp;amp; make install&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Allgemeine Fehlerbehebung ==&lt;br /&gt;
&lt;br /&gt;
Es kann im Laufe der Zeit nach mehrmaligem Ausführen von &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; vorkommen, dass sich das Ausgabeformat einiger Werkzeuge, die in der KDE-Werkzeugkette benutzt werden, ändert. Zum Beispiel werden &amp;lt;tt&amp;gt;kcfg&amp;lt;/tt&amp;gt; Dateien vom &amp;lt;tt&amp;gt;kconfig_compiler&amp;lt;/tt&amp;gt; gelesen, um die Konfigurationsdialoge zu generieren. Da CMake diese Veränderungen nicht erkennt, kann das Kompilieren fehlschlagen. Eine provisorische Lösung ist, die Regenerierung all dieser Dateien zu erzwingen:&lt;br /&gt;
 find $KDE_SRC/kde/kdebase -name &amp;quot;*.kcfg&amp;quot; | xargs touch&lt;br /&gt;
Dasselbe gilt für &amp;lt;tt&amp;gt;ui&amp;lt;/tt&amp;gt; Dateien wie solche, die mit Qt Designer generiert werden.&lt;br /&gt;
&lt;br /&gt;
== Das war's! ==&lt;br /&gt;
&lt;br /&gt;
Sie sind nun bereit, andere svn-Module in derselben Weise wie kdebase zu kompilieren, KDE 4 zu benutzen und zu testen, sowie Ihre eigenen Patches und Anwendungen zu schreiben.&lt;br /&gt;
&lt;br /&gt;
Siehe auch die Anleitung [[Getting Started/Set up KDE 4 for development|Set up KDE 4 for development]] um Hilfe beim Starten von KDE-4-Anwendungen sowie zur Benutzung von KDevelop zu erhalten.&lt;br /&gt;
&lt;br /&gt;
[[Category:Build KDE]]&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started_(de)</id>
		<title>Getting Started (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started_(de)"/>
				<updated>2008-01-18T13:27:41Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Changed links to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting_Started}}&lt;br /&gt;
{{Box|Zugriff auf die Quellen|&lt;br /&gt;
[[Image:Action_down.svg|right|32px]]&lt;br /&gt;
Der KDE-Quelltext ist auf verschiedenen Wegen erhältlich:&lt;br /&gt;
* [[Getting Started/Sources/Anonymous SVN (de)|Anonymes SVN Schnellstart Anleitung]]&lt;br /&gt;
* [[Getting Started/Sources/Using Subversion with KDE|Benutzung von Subversion mit KDE]] ''Benutzung von Subversion mit KDE. Ein mehr in die Tiefe gehender Einblick für den Zugriff auf KDEs Quelltext mit Subversion, einschließlich dem Depot Layout und dem Arbeiten mit Revisionen und Patches.''&lt;br /&gt;
* [http://websvn.kde.org/ Durchstöbern Sie den Quelltext online]&lt;br /&gt;
* [[Getting Started/Sources/Snapshots|Tägliche Schnappschüsse]]&lt;br /&gt;
|100%}}&lt;br /&gt;
&lt;br /&gt;
{{Box|Erstellung von KDE|&lt;br /&gt;
[[Image:Action_tool.svg|right|32px]]&lt;br /&gt;
Es existieren verschiedene KDE Zweige. Für den produktiven Einsatz wird eine stabile Version empfohlen.&lt;br /&gt;
* [[Getting Started/Build/KDE4_(de)|KDE 4 (Entwicklungs Version, Trunk)]]&lt;br /&gt;
* [[Getting Started/Build/Stable Version|KDE 3.5 (Stabile Version)]]&lt;br /&gt;
* [[Getting Started/Build|Andere Versionen und das FAQ]] ''Einschließlich Informationen für die Erstellung auf Nicht-Linux Systemen''&lt;br /&gt;
|100%}}&lt;br /&gt;
&lt;br /&gt;
{{Box|Aufsetzen der Umgebung|&lt;br /&gt;
[[Image:Action_pen.svg|right|32px]]&lt;br /&gt;
Nachdem KDE erstellt worden ist, möchten Sie wahrscheinlich einen wirksamen Weg für das Starten der Anwendungen und das Ausführen Ihrer üblichen Entwicklungsaufgaben haben:&lt;br /&gt;
* [[Getting Started/Increased Productivity in KDE4 with Scripts|Erhöhen Sie Ihre Produktivität in KDE4 mit Skripten]]&lt;br /&gt;
* [[Getting Started/Set up KDE 4 for development (de)|Setzen Sie KDE4 für die Entwicklung auf]]&lt;br /&gt;
|100%}}&lt;br /&gt;
[[Category:Build KDE]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Debugging/Using_Error_Messages</id>
		<title>Development/Tutorials/Debugging/Using Error Messages</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Debugging/Using_Error_Messages"/>
				<updated>2008-01-16T16:15:10Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: +Language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language_Navigation_Bar|Development/Tutorials/Debugging/Using Error Messages}}&lt;br /&gt;
&lt;br /&gt;
When you start a konsole and type the commands to start an application you&lt;br /&gt;
will see all sorts of statements are printed in the konsole while the &lt;br /&gt;
application is running. All applications print these messages, to look&lt;br /&gt;
at them you have to know where to look. The application will have to be&lt;br /&gt;
compiled with the debugging enabled. So using a precompiled package from a distribution&lt;br /&gt;
probably will not give you this information. If you compiled the application &lt;br /&gt;
yourself, make sure the configure option &amp;quot;&amp;lt;tt&amp;gt;--disable-debug&amp;lt;/tt&amp;gt;&amp;quot; was not used.&lt;br /&gt;
&lt;br /&gt;
In KDE all debugging text-output can be switched on or off based on so&lt;br /&gt;
called '''areas'''. One application can be one or more area. One part of the kde base libraries can be another area. Enabling/disabling these areas from being printed can be done using the '''kdebugdialog''' application. For simple debugging selecting all&lt;br /&gt;
sections is probably wise.&lt;br /&gt;
&lt;br /&gt;
When you are debugging it is best to simply start a konsole and start the&lt;br /&gt;
application from there. In a konsole you could simply type:&lt;br /&gt;
&lt;br /&gt;
 kicker&lt;br /&gt;
&lt;br /&gt;
and in the konsole kicker could return a message like:&lt;br /&gt;
&lt;br /&gt;
 ERROR: kicker is already running!&lt;br /&gt;
&lt;br /&gt;
When a lot of output is written to the konsole it might go out of view before&lt;br /&gt;
you could read it, therefor it is easy to create a text file which contains&lt;br /&gt;
all this information, to do so type the following:&lt;br /&gt;
&lt;br /&gt;
 application 2&amp;amp;gt;&amp;amp;amp;1 | tee debug.log&lt;br /&gt;
&lt;br /&gt;
where 'application' can be replaced with the application you are debugging.&lt;br /&gt;
Afterwards you could open the file 'debug.log' to look at the messages again.&lt;br /&gt;
&lt;br /&gt;
If you are NOT starting the application from a konsole the messages will be&lt;br /&gt;
logged somewhere else, or they could have been discarded by the program that&lt;br /&gt;
started your application. &lt;br /&gt;
&lt;br /&gt;
If your application is started by clicking on an icon your best bet is to check&lt;br /&gt;
the following log files. Beware; they contain logs for a lot of applications, &lt;br /&gt;
not just the application you are debugging!&lt;br /&gt;
&lt;br /&gt;
'''Case 1: Graphical login (i.e. kdm, gdm, xdm, etc.'''&lt;br /&gt;
&lt;br /&gt;
The debug messages get redirected into the file {{path|~/.xsession-errors}} or&lt;br /&gt;
{{path|~/.X.err}} in your home directory (that is with a leading dot '.' also&lt;br /&gt;
watch the Capital).&lt;br /&gt;
&lt;br /&gt;
'''Case 2: You are using startx:'''&lt;br /&gt;
&lt;br /&gt;
Use the following command to restart your session:&lt;br /&gt;
 startx 2&amp;amp;gt;&amp;amp;amp;1 | tee startx.log&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
so that all the debug messages of applications started at KDE's startup (and&lt;br /&gt;
any application launched from the panel etc.) go to the file &amp;quot;startx.log&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Links ==&lt;br /&gt;
&lt;br /&gt;
The debug messages are usually printed in C++ with the kDebug or kWarning statement. Example:&lt;br /&gt;
&lt;br /&gt;
 kDebug(1210) &amp;lt;&amp;lt; &amp;quot;arbitrary message&amp;quot;;&lt;br /&gt;
 kWarning(1210) &amp;lt;&amp;lt; &amp;quot;this rather should not happen&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
The number 1210 (so called ''debug area'') in this case represents kicker.  You can omit the number.&lt;br /&gt;
&lt;br /&gt;
See also: [http://api.kde.org/4.0-api/kdelibs-apidocs/kdecore/html/group__kdebug.html kDebug/kWarning API documentation].&lt;br /&gt;
&lt;br /&gt;
''Initial Author:'' [mailto:zander@kde.org Thomas Zander]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials_(de)</id>
		<title>Development/Tutorials (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials_(de)"/>
				<updated>2008-01-16T16:07:19Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* D-Bus */ -Writing mistake&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials}}&lt;br /&gt;
&lt;br /&gt;
Tutorials sind der schnellste Weg um herauszufinden, was man mit KDE anstellen kann und wie man das macht. Es folgt eine Liste der verfügbaren Tutorials '''für KDE4'''. Tutorials und Anleitungen zu KDE3 und KDE2 finden Sie am Ende dieser Seite.&lt;br /&gt;
&lt;br /&gt;
== Einführung in die KDE4 Programmierung ==&lt;br /&gt;
Sind Sie an der Entwicklung von Programmen für KDE 4 interesiert? Wenn ja sind Sie hier genau richtig. Diese Artikelserie richtet sich an alle, die noch nie mit KDE programmiert haben.&lt;br /&gt;
;[[Development/Tutorials/First program (de)|Hallo Welt!]]&lt;br /&gt;
:''Einführung in die Grundlagen der KDE Programmierung''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KXmlGuiWindow (de)|Erstellen eines Hauptfensters]]&lt;br /&gt;
:''Dieser Artikel erklärt, wie der wichtigste Teil eines grafischen Programmes erstellt wird: das Hauptfenster.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KActions (de)|Die Verwendung von KActions]]&lt;br /&gt;
:''In diesem Artikel erfahren Sie, wie Aktionen und Werkzeugleisten (Toolbars) im Menü hinzugefügt werden können.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Saving and loading (de)|Laden und Speichern von Dateien]]&lt;br /&gt;
:''Dieser Artikel führt die KIO Bibliothek ein und erklärt wie man Dateien laden und speichern kann.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/KCmdLineArgs (de)|Befehlszeilen Argumente (todo)]]&lt;br /&gt;
:''In diesem Artikel werden Sie lernen Ihrer Anwendung zu ermöglichen, Dateien über die Befehlszeile oder sogar unter Dolphin mit 'Öffnen mit' zu laden''&lt;br /&gt;
&lt;br /&gt;
== Grundlagen ==&lt;br /&gt;
;[[Development/Tutorials/KDE4 Porting Guide (de)|Ihre Applikation nach KDE 4 portieren]]&lt;br /&gt;
:''Anleitungen Qt3/KDE3 Applikationen nach Qt4/KDE4 zu portieren''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/CMake (de)|Einführung in CMake]]&lt;br /&gt;
:''Wie man CMake in KDE 4 benutzt''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Common Programming Mistakes (de)|Häufige Programmierfehler]]&lt;br /&gt;
:''Einige häufige Fehler die man während der Entwicklung von Qt und KDE Applikationen machen kann und wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using Qt Designer (de)|Den Qt Designer benutzen um Benutzerschnittstellen zu erzeugen]]&lt;br /&gt;
:''Wie man UI Dateien mit dem Designer erzeugt und wie man diese in einem KDE Programm integriert.''&lt;br /&gt;
&lt;br /&gt;
== Testen und Fehler beheben ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Debugging (de)|Debugging Ihrer Applikation]]&lt;br /&gt;
:''Tips, Tools und Techniken zum Debuggen von KDE Applikationen''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Unittests|Schreiben von Unit-Tests für Qt4 und KDE4 mit QTestLib]] ([http://developer.kde.org/documentation/tutorials/writingunittests/writingunittests.html Original link])&lt;br /&gt;
:''Tutorial von [mailto:bradh@frogmouth.net Brad Hards] das beschreibt, wie man Unit-Tests mit dem QTestLib Framework erstellt. Das Tutorial wird anhand eines Beispiels beschrieben und befindet sich zur Zeit noch in Entwicklung.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Code_Checking|Halbautomatische Werge zur Erkennung von Programmierfehlern]]&lt;br /&gt;
:''Techniken um Fehler in KDE Code aufzuspüren''&lt;br /&gt;
&lt;br /&gt;
== Konfigurationen mit KConfig verwalten ==&lt;br /&gt;
;[[Development/Tutorials/KConfig|Einführung in KConfig]]&lt;br /&gt;
:''Eine Übersicht über die zu KConfig gehörenden Klassen und wie Sie diese in Ihre Anwendung einbinden können''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KConfig XT|Benutzung von KConfig XT]]&lt;br /&gt;
:''Tutorial über das effiziente Benutzen des KConfig XT Frameworks.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Updating KConfig Files|Update von KConfig Dateien]]&lt;br /&gt;
:''Tutorial das beschreibt, wie man ein Update-Skript erstellt, dass Veränderungen am Format der Konfiguration Ihrer Anwendung mit den bereits vorgenommenen Einstellungen des Anwenders abgleicht.''&lt;br /&gt;
&lt;br /&gt;
== Dienste: Applikationen und Plugins ==&lt;br /&gt;
;[[Development/Tutorials/Services/Introduction (de)|Einführung in das Dienst-Framework]]&lt;br /&gt;
:''Eine Einführung über das Dienst-Framework in KDE und was es dem Applikationsentwickler zur Verfügung stellen kann. Beschäftigt sich mit dem system configuration cache (SyCoCa), den benötigten Dateien und wie indizierte Informationen benutzt werden.&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Traders (de)|Dienste über Trader Queries finden]]&lt;br /&gt;
:''Wie man mit der Trader Query Syntax Dienste wie Plugins oder Mimetypes findet, die im SyCoCa zwischengespeichert wurden. ''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Plugins|Erstellen und Laden von Plugins mit KService]]&lt;br /&gt;
:''Zeigt, wie man eigene Plugintypen definiert, installiere Plugins findet (einschließlich denen von anderen Herstellern) und wie man diese einfach und portabel läd, indem man KService benutzt.''&lt;br /&gt;
&lt;br /&gt;
== Lokalisierung ==&lt;br /&gt;
;[[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]]&lt;br /&gt;
:''Eine Einführung was Unicode ist und wie KDE Applikationen damit umgehen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n (de)|Beim Schreiben der Applikation an die Lokalisierung denken]]&lt;br /&gt;
:''Diese Anleitung beschäftigt sich damit, was Lokalisation ist, warum sie wichtig ist und wie man sicherstellt, dass die eigene Applikation bereit ist, lokalisiert zu werden. Jeder Applikationsentwickler sollte das lesen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Mistakes (de)|Häufige Fehler vermeiden]]&lt;br /&gt;
:''Es gibt einige häufige Fehler, die es verhindern, dass eine Applikation angemesssen übersetzt werden kann. Diese Anleitung zeigt diese Fehler auf und zeigt, wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/Building KDE's l10n Module|Erstellen von KDE's Lokalisierungs Modul]]&lt;br /&gt;
:''Das Erstellen und Installieren der Sprachunterstützung mit KDE's Lokalisierungs-Modul (l10n) ist ratsam für alle, die an Anwendungen im KDE Haupt-Repository arbeiten. Hierdurch erreichen Sie, das Sie Ihre Anwendung in anderen Sprachen testen und somit auftauchende Probleme erkennen können. Dieses Tutorial bringt Ihnen genau das bei.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Build Systems|Einbeziehen von i18n in das Build System]]&lt;br /&gt;
:''Sobald Ihre Anwendung bereit dazu ist lokalisiert zu werden, ist es der nächste Schritt sicherzustellen, dass die Übersetzungsdateien automatisch erstellt und aktuell gehalten werden. Dieses Tutorial behandelt die nötigen Änderungen an den CMakeFile.txt Dateien sowie den Prozess um den resultierenden Nachrichten-Katalog mit Ihrer Applikation zu verteilen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Challenges|i18n - Herausforderungen and Lösungen]]&lt;br /&gt;
:''Dieses Tutorial behandelt die Aufgaben und Fallstricke, die bei der Lokalisierung auftreten wie das Übersetzen von Handbüchern und anderen Daten die ausserhalb des Quellcodes auftreten, das Behandeln von nicht mehr gültigen .po-Dateien, das Umgehen mit Freezes, programmieren in anderen Sprachen als Englisch und Erstellung unabhängiger Releases oder das Verschieben von Anwendungen zwischen KDE Modulen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n_Semantics|Semantisches Markup für Nachrichten]]&lt;br /&gt;
:''Um eine konsistente und semantisch korrekte Darstellung von Nachrichten in Anwendungen sicherzustellen, können semantische Kommentare zu den Nachrichten, die übersetzt werden sollen, mit dem KUIT System hinzugefügt werden. Dieses Tutorial beschreibt die Funktionsweise dieses Systems.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Krazy|Automatisierte i18n Codeüberprüfung]]&lt;br /&gt;
:''Der Krazy Code-Checker durchsucht KDE's Code und meldet häufige i18n Fehler.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/Language Change (de)|Mit Sprachänderungen umgehen]]&lt;br /&gt;
:''Wie man seiner Applikation beibringt beim nächsten Start oder zur Laufzeit eine andere Sprache zu benutzen.''&lt;br /&gt;
&lt;br /&gt;
== Dokumentation ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/API_Documentation|API Dokumentation]]&lt;br /&gt;
:''Dieses Tutorial erklärt, wie Sie Ihre APIs korrekt dokumentieren.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Man_Pages|Man Seiten]]&lt;br /&gt;
:''Das Schreiben und Erstellen von Referenz-Handbüchern.''&lt;br /&gt;
&lt;br /&gt;
== Anwendungsautomatisierung und Skripting ==&lt;br /&gt;
&lt;br /&gt;
=== D-Bus ===&lt;br /&gt;
; [[Development/Tutorials/D-Bus/Introduction|Einführung in D-Bus]]&lt;br /&gt;
:''Eine unkomplizierte Einführung in die Kernkonzepte von D-Bus aus der Sicht eines Anwendungs-Programmierers. Dieses Tutorial behandet was D-Bus ist, und wie Sie es in Ihren Anwendungen einsetzen können.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/D-Bus/Accessing Interfaces|Zugriff auf D-Bus Schnittstellen]]&lt;br /&gt;
:''Eine Schrittweise Anleitung zum Aufruf von D-Bus-Methoden und zur Verbindung mit D-Bus-Signalen unter Verwendung von QtDBus.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/D-Bus/Intermediate_D-Bus|D-Bus für Fortgeschrittene]]&lt;br /&gt;
:''Tips zur Verwendung von QtDBus wenn sie mit problematischen Realwelt-Schnittstellen konfrontiert werden.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/D-Bus/Creating Interfaces|Erstellen von D-Bus Schnittstellen]]&lt;br /&gt;
:''Lernen Sie, wie sie Funktionalität Ihrer Applikationen bereit stellen, indem Sie eigene D-Bus Schnittstellen erstellen und benutzen. Beschreibt das Erstellen von XML-Beschreibungen, die Bereitstellung von Schnittstellen zur Laufzeit und das Aufsetzen des Build-Systems mit CMake.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/D-Bus/Autostart Services|D-Bus Autostart Dienste]]&lt;br /&gt;
:''Machen Sie mit diesem Tutorial aus Ihrer Anwendung einen D-Bus-Autostart-Dienst. Dieses Feature, dass auch als &amp;quot;D-Bus Dienst Aktivierung&amp;quot; bekannt ist, ermöglicht es, dass D-Bus Aufrufe zu Ihrer Applikation selbst dann funktionieren, wenn sie gerade nicht läuft indem sie den D-Bus-Daemon Ihre Applikation starten lassen, wenn deren Funktionen benötigt werden.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Porting_to_D-Bus|Portieren von DCOP nach D-Bus]]&lt;br /&gt;
: ''Portieren Sie mit Hilfe dieser Anleitung Ihre Anwendungen von DCOP nach D-Bus.''&lt;br /&gt;
&lt;br /&gt;
=== Konqueror ===&lt;br /&gt;
; [[Development/Tutorials/Creating Konqueror Service Menus|Erstellung von Konqueror Dienstmenus]]&lt;br /&gt;
:''Dieses Tutorial zeigt Ihnen wie Sie MIME-Typ-spezifische Aktionen in Konquerors Kontextmenu bereitstellen.''&lt;br /&gt;
&lt;br /&gt;
=== Kross ===&lt;br /&gt;
; [[Development/Tutorials/Kross/Introduction|Einführung in Kross]]&lt;br /&gt;
:''Eine Einführung in das Kross Scripting Framework.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Kross/Hello_World|Hallo Welt]]&lt;br /&gt;
:''Eine erste Anwendung mit funktionierendem Kross Code.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Kross/Connecting_Signals_and_slots_in_Kross|Verbinden von Signalen und Slots in Kross]]&lt;br /&gt;
:''Einfache Demonstration, wie man Signale von Objekten mit Slots von Skripten verbindet.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Kross/Scripts-as-Plugins|Skripte als Plugins mit Kross]]&lt;br /&gt;
:''Dieses Tutorial bietet eine schrittweise Einführung, wie Sie Skripte als Plugins in eine KDE Anwendung integrieren.''&lt;br /&gt;
&lt;br /&gt;
=== KOffice ===&lt;br /&gt;
; [[Development/Tutorials/KOffice Overview|KOffice Übersicht]]&lt;br /&gt;
:''Dieses Dokument zeigt eine Übersicht über die verschiedenen KOffice Plugin Typen sowie ihren jeweiligen Nutzen und Stärken.'' Wenn KOffice Plugins neu für Sie sind, ist dieses Tutorial für Sie geeignet.&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Write a Flake Plugin|Erstellen von KOffice Flake Plugins]]&lt;br /&gt;
:''Dieses Tutorial zeigt Ihnen wie Sie ein Plugin für KOffice Anwendungen erstellen das Ihnen mit Hilfe von Flake erlaubt, Inhalte in ODF-Dokumente einzubetten.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/KWord Scripting|KWord Scripting]]&lt;br /&gt;
:''Dieses Tutorial zeigt, wie man KWord mit Skriptsprachen wie Python, Ruby oder JavaScript über Kross anspricht.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/KSpread Scripting|KSpread Scripting]]&lt;br /&gt;
:''Dieses Tutorial zeigt, wie man KSpread mit Skriptsprachen wie Python, Ruby oder JavaScript über Kross anspricht.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Krita Scripting|Krita Scripting]]&lt;br /&gt;
:''Dieses Tutorial zeigt, wie man Krita mit Skriptsprachen wie Python, Ruby oder JavaScript über Kross anspricht.''&lt;br /&gt;
&lt;br /&gt;
=== SuperKaramba ===&lt;br /&gt;
; [[Development/Tutorials/SuperKaramba|SuperKaramba Tutorial]]&lt;br /&gt;
:''Dieses Tutorial bietet einen Einblick in SuperKaramba, Themen-Dateien und das Skripten mit Python, Ruby und JavaScript.&lt;br /&gt;
&lt;br /&gt;
== Suche und Meta-Daten ==&lt;br /&gt;
&lt;br /&gt;
=== Strigi ===&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Writing file analyzers|Schreiben von Datei-Analysierern]]&lt;br /&gt;
:''Datei-Analysierer extrahieren Daten aus Dateien um Sie in Datei-Dialogen und Datei-Managern anzeigen können. Die Daten die auf diesem Weg erhalten werden, werden auch für die Suche nach Dateien verwendet. KDE4 erlaubt die Benutzung von mehreren Analysierern pro Dateityp. Dieses Tutorial beschreibt, wie Sie neue Analysierer schreiben können.''&lt;br /&gt;
&lt;br /&gt;
=== Nepomuk ===&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Metadata/KMetaData first steps|Erste Schritte mit Nepomuk]]&lt;br /&gt;
:''Nepomuk ist die KDE-Bibliothek die einfachen Zugriff auf Metadaten im [http://nepomuk-kde.semanticdesktop.org Nepomuk-KDE] System erlaubt. Lernen Sie, wie Ihre Applikation mit Hilfe von Nepomuk Metadaten bereitstellen und verwenden kann.''&lt;br /&gt;
&lt;br /&gt;
== Ansprechen von Hardware (Solid) ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Solid_Tutorials|Einführung in Solid]]&lt;br /&gt;
:''Eine Einführung in die Benutzung der Solid Hardware-Erkennung und -Verwendung in KDE Applikationen.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Solid_Network_Tutorial|Zugriff auf Netzwerk-Informationen]]&lt;br /&gt;
:''Wie man Solid benutzt um Informationen über das Netzwerk herauszufinden''&lt;br /&gt;
&lt;br /&gt;
== Multimedia (Phonon) ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Phonon/Introduction|Phonon]]&lt;br /&gt;
:''Erste Schritte mit der Multimedia API''&lt;br /&gt;
&lt;br /&gt;
:''Erstellung und Benutzung von Phonon und seinem GStreamer Backend unter Linux mit Qt 4.3.x''&lt;br /&gt;
::''Dieser Artikel gibt Ihnen eine kurze Anleitung wie Sie Phonon und sein GStreamer Backend unter GNU/Linux mit lediglich Qt 4.3.x beziehen, kompilieren und benutzen können. Gegen Ende beschreibt der Artikel zusätzlich, wie ein Entwickler Phonon benutzen kann um einfache Audio- und Video-Spieler zu erstellen. Sie können den Artikel [http://www.vcreatelogic.com/oss/docs/CompilingPhononOnLinux.pdf hier] lesen.&lt;br /&gt;
Sie können die editierbare OpenDocumentText Datei von [http://www.prashanthudupa.com/phonon/CompilingPhononOnLinux.odt hier]. herunterladen''&lt;br /&gt;
&lt;br /&gt;
== Plasma ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Plasma/GettingStarted|Erste Schritte mit Plasmoids]]&lt;br /&gt;
:''Erstellung Ihres ersten Plasma-Widgets oder Plasmoids in C++ mit einem SVG Hintergrund, einem Icon und etwas Text''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Plasma/DataEngines|Schreiben einer DataEngine]]&lt;br /&gt;
:''DataEngines bieten eine standardisierte Schnittstelle zur Darstellung von Daten aus verschiedenen Datenquellen. Lernen Sie was eine DataEngine ist und wie Sie selbst ein schreiben können.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Plasma/UsingDataEngines|Benutzung von DataEngines in Plasmoids]]&lt;br /&gt;
:''Mit einer DataEngine ist es möglich, Daten auf einfache und standardisierte Art und Weise zu empfangen und darzustellen. Dieses Tutorial behandelt das Thema, wie man DataEngines zu diesem Zweck in Plasma einsetzt.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Plasma/AbstractRunner|Erstellen von Runners]]&lt;br /&gt;
:''Runners sind Plugins die Aktions-basierte Suchfunkionalität im Plasma Ausführen-Dialog erlauben. Diese Plugins können von jeder Applikation verwendet werden, die libplasma einbindet.''&lt;br /&gt;
&lt;br /&gt;
== Kate / Kwrite ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Kate/KTextEditor Plugins|Erste Schritte mit KTextEditor Plugins]]&lt;br /&gt;
:''Erstellung Ihres ersten KTextEditor Plugins''&lt;br /&gt;
&lt;br /&gt;
== Drucken ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Printing Hello World|Hallo Welt]]&lt;br /&gt;
:''Einführung in das KDE Drucksystem''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Printing Print Dialog|Druckdialog]]&lt;br /&gt;
:''Benutzung des KDE Druckdialogs''&lt;br /&gt;
&lt;br /&gt;
== Neue Dinge herunterladen ==&lt;br /&gt;
; [[Development/Tutorials/Introduction to Get Hot New Stuff|Einführung in &amp;quot;Neue Dinge herunterladen&amp;quot;]]&lt;br /&gt;
:''Eine Einführung in das Entwickler-freundliche Netzwerk-Update-System das KDE Applikationen erlaubt, neue Anwendungsdaten zur Laufzeit auf benutzerfreundliche Weise herunterzuladen.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/KNewStuffSecure|Sicherheit mit KNewStuff]] ([http://developer.kde.org/documentation/tutorials/knewstuffsecure/index.html Original Link])&lt;br /&gt;
:''Tutorial das zeigt, wie man Ressourcen auf sichere Weise teilt (KDE 3.4 und später).''  Geschrieben von Andr&amp;amp;#225;s Mantia &amp;amp;lt;amantia@kde.org&amp;amp;gt;.&lt;br /&gt;
&lt;br /&gt;
== Schnelle Anwendungsentwicklung ==&lt;br /&gt;
&lt;br /&gt;
=== Python ===&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Python introduction to signals and slots|101 Einführung in Signale und Slots]]&lt;br /&gt;
:''Eine einfache Einführung in Qt's Signal- und Slot-Architektur.''&lt;br /&gt;
&lt;br /&gt;
=== Ruby ===&lt;br /&gt;
&lt;br /&gt;
;[http://developer.kde.org/language-bindings/ruby/kde3tutorial/index.html KDE Ruby Korundum Tutorial]&lt;br /&gt;
:''Eine Ruby-Version von Antonio Larossa Jim&amp;amp;eacute;nezs KDE Tutorial von Richard Dale. Sehen Sie sich for Qt Tutorials und andere Informationen auch die  [http://developer.kde.org/language-bindings/ruby/index.html Ruby Developers Corner] an.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Qt4_Ruby_Tutorial|Qt4 Ruby Tutorial]]&lt;br /&gt;
:''Trolltechs sagenhaftes Einstiegstutorial in Qt, übersetzt für Ruby.''&lt;br /&gt;
&lt;br /&gt;
=== Shell ===&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Shell_Scripting_with_KDE_Dialogs|Shell Scripting mit KDE Dialogen]] ([http://developer.kde.org/documentation/tutorials/kdialog/t1.html Original Link])&lt;br /&gt;
:''Tutorial von [mailto:bradh@frogmouth.net Brad Hards] das beschreibt, wie man KDE Dialoge mit Hilfe von kdialog in Shell-Skripten verwendet. Das Tutorial wird anhand eines Beispiels durchgeführt.''&lt;br /&gt;
&lt;br /&gt;
== Andere Tutorials ==&lt;br /&gt;
&lt;br /&gt;
=== Benutzung der KDE Games Bibliothek ===&lt;br /&gt;
;[[Development/Tutorials/Games/KStandardGameAction| KStandardGameAction]]&lt;br /&gt;
:''Benutzung von libkdegames um Ihr Spiel dem kdegames Standard anzupassen''&lt;br /&gt;
;[[Development/Tutorials/Games/Highscores| Highscores]]&lt;br /&gt;
:''Implementierung einer einfachen Highscore-Tabelle in Ihrem Spiel''&lt;br /&gt;
;[[Development/Tutorials/Games/Theme Selector| Themen-Auswahl]]&lt;br /&gt;
:'' Benutzung des libkdegames Themen-Auswahl-Dialogs''&lt;br /&gt;
&lt;br /&gt;
=== 2D Plotting (KPlotWidget) ===&lt;br /&gt;
;[[Development/Tutorials/KPlotWidget|Benutzen des KDE Daten-Plotting Widgets]]&lt;br /&gt;
:''Dieses Tutorial führt KPlotWidget ein, welches zum plotten zweidimensionaler Daten verwendet werden kann. Es enthält Informationen zu einfachen Benutzung des Widgets (inklusive Hinzufügen und Änderung von Datensätzen sowie Anpassung der Koordinatenachsen und deren Beschriftung) sowie erweiterten Anwendungsfällen (inklusive Erweiterung des Widgets durch Vererbung).''&lt;br /&gt;
&lt;br /&gt;
=== Rechtschreib- und Grammatikprüfung (Sonnet) ===&lt;br /&gt;
;[[Development/Tutorials/Sonnet/SonnetTutorial|Rechtschreib- oder Grammatikprüfung in KDE Applikationen einbinden]]&lt;br /&gt;
:''Diess Tutorial führt in Sonnet ein und wie man es benutzt um Sprachkorrekturen in der eigenen KDE Anwendung zu verwenden. Sonnets Hilffunktionen sollen in einem weiteren Tutorial beschrieben werden.''&lt;br /&gt;
&lt;br /&gt;
=== Pixmap cache (KPixmapCache) ===&lt;br /&gt;
;[[Development/Tutorials/KPixmapCache|Benutzung des KDE Pixmap Caches]]&lt;br /&gt;
:''Dieses Tutorial demonstriert die Benutzung von KPixmapCache zum Zwischenspeichern von beispielsweise Pixmaps die aus SVGs oder Daten erstellt wurden.''&lt;br /&gt;
&lt;br /&gt;
== Material für KDE2 und KDE3 ==&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/KDE3|KDE3 Tutorials]]&lt;br /&gt;
:''Diese Tutorials behandeln Themen im Bezug auf KDE3.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/KDE2|KDE2 Tutorials]]&lt;br /&gt;
:''Diese Tutorials behandeln Themen im Bezug auf KDE2.''&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Template:TutorialBrowser_(de)</id>
		<title>Template:TutorialBrowser (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Template:TutorialBrowser_(de)"/>
				<updated>2008-01-16T10:08:15Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added a link to german start page&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&amp;lt;div class=&amp;quot;rbroundbox&amp;quot; style=&amp;quot;width:100%;&amp;quot;&amp;gt;&lt;br /&gt;
 &amp;lt;div class=&amp;quot;rbtopwrap&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;div class=&amp;quot;rbtop&amp;quot;&amp;gt;&amp;lt;div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;{{{name}}}&amp;lt;/div&amp;gt;&lt;br /&gt;
 &amp;lt;div class=&amp;quot;rbcontent&amp;quot;&amp;gt;&lt;br /&gt;
{|style=&amp;quot;width:100%; background:#dadde0;&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
| width=25% align=right valign=top | '''Anleitungsserie'''&amp;amp;nbsp;&amp;amp;nbsp;&lt;br /&gt;
| {{{series|n/a}}}&lt;br /&gt;
|-&lt;br /&gt;
| align=right valign=top | '''Voriges Kapitel'''&amp;amp;nbsp;&amp;amp;nbsp;&lt;br /&gt;
| {{{pre|None}}}&lt;br /&gt;
|-&lt;br /&gt;
| align=right valign=top | '''Nächstes Kapitel'''&amp;amp;nbsp;&amp;amp;nbsp;&lt;br /&gt;
| {{{next|n/a}}}&lt;br /&gt;
|-&lt;br /&gt;
| align=right valign=top | '''Weiterführende Texte'''&amp;amp;nbsp;&amp;amp;nbsp;&lt;br /&gt;
|{{{reading|n/a}}}&lt;br /&gt;
|-&lt;br /&gt;
| align=right valign=top | '''Navigation'''&amp;amp;nbsp;&amp;amp;nbsp;&lt;br /&gt;
|[[Welcome to KDE TechBase (de)|Deutsche Startseite]]{{{otherlinks|}}}&lt;br /&gt;
|}&lt;br /&gt;
 &amp;lt;/div&amp;gt;&lt;br /&gt;
 &amp;lt;div class=&amp;quot;rbbot&amp;quot;&amp;gt;&amp;lt;div&amp;gt;&amp;lt;/div&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&amp;lt;/div&amp;gt;&lt;br /&gt;
{{DISPLAYTITLE:{{{name}}}}}&lt;br /&gt;
[[Category:Tutorial (de)]]&amp;lt;noinclude&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Empfohlene Benutzung==&lt;br /&gt;
Um im Wiki eine gewisse Konsistenz zu behalten: Wird diese Vorlage benutzt, sollte sie auf der Seite ganz oben eingefügt werden und zwar über jeder ==Überschrift==, damit die Informationen für den Leser möglichst schnell zugänglich sind. &lt;br /&gt;
&lt;br /&gt;
Weiterhin fügt diese Vorlage automatisch an das Ende der Seite eine [[:Category:Tutorial (de)|Anleitungskategorie]], daher besteht keine Veranlassung das von Hand zu machen.&lt;br /&gt;
&lt;br /&gt;
==Parameters==&lt;br /&gt;
&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Parameter !! Function&lt;br /&gt;
|-&lt;br /&gt;
| '''series''' || Die Serie von Anleitungen zu der diese Anleitung gehört&lt;br /&gt;
|-&lt;br /&gt;
| '''name''' || Beschreibender Name dieses Kapitels. &lt;br /&gt;
|-&lt;br /&gt;
| '''pre''' || Vorausgehende Kapitel, die gelesen sein sollten (versuche sie vernünftig zu ordnen und stelle sicher, dass es sich um Links handelt)&lt;br /&gt;
|-&lt;br /&gt;
| '''next''' || Die Anleitung, die logisch auf diese hier folgt (aus der gleichen Serie). Oder eine Anleitung mit der es Sinn macht, als nächstes fortzufahren. &lt;br /&gt;
|-&lt;br /&gt;
| '''reading''' || Weitere Texte, die das entsprechende Thema vertiefen&lt;br /&gt;
|-&lt;br /&gt;
| '''otherlinks''' || Weitere allgemeine Links zu übergeordneten Kapiteln&lt;br /&gt;
|-&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
[[Category:Template]]&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Anonymous_SVN_(de)</id>
		<title>Getting Started/Sources/Anonymous SVN (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Anonymous_SVN_(de)"/>
				<updated>2008-01-16T08:38:55Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation bar + german templates&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Anonymous SVN}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Für diejenigen von uns, welche bei der vordersten Front mitarbeiten wollen, gibt es einen einfachen Weg, eine aktuelle lokale Kopie des KDE Source Codes auf dem Rechner zu haben - anonymous SVN.&lt;br /&gt;
&lt;br /&gt;
Bitte beachten Sie, dass einige Linux Distributoren schon die KDE SVN Pakete beilegen, '''damit brauchen Sie nicht unbedingt Qt und KDE selber zu kompilieren! ''' &lt;br /&gt;
Lesen Sie dazu [[Getting_Started/Distribution_Packages]] für Anleitungen und Informationen.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Anonymous SVN ==&lt;br /&gt;
&lt;br /&gt;
=== Subversion einrichten===&lt;br /&gt;
Als aller ersten müssen Sie die Subversion-Binarys installieren, falls diese noch nicht auf ihrem Computer vorhanden sind.&lt;br /&gt;
Sehr wahrscheinlich wird für Ihr Betriebssystem ein Packet dazu vorhanden sein. Falls nicht, können Sie es selber von der [http://subversion.tigris.org/project_packages.html SVN-Projektpage herunterladen] und übersetzten (Kompilieren). &lt;br /&gt;
Bitte lesen die [[Getting_Started/Sources/Using_Subversion_with_KDE|KDE Subversion tutorial]], wenn Sie sich dafür interessieren wie SVN funktioniert.&lt;br /&gt;
&lt;br /&gt;
=== Checkout KDE ===&lt;br /&gt;
&lt;br /&gt;
'''/trunk/''' ist der Pfad in welchem das Qt4-basierende KDE 4 entwickelt wird.&lt;br /&gt;
Folgende sind die wichtigsten Befehle, welche Sie brauchen um KDE aus SVN aus zu checken und zu Kompilieren:&lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdelibs&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/trunk/KDE/kdebase&lt;br /&gt;
&lt;br /&gt;
{{tip|Verwenden Sie &amp;quot;'''svn co'''&amp;quot; nur für das erst Checkout; später werden Sie &amp;quot;'''svn up''' ''modulename''&amp;quot; oder &amp;quot;'''svn update''' ''modulename''&amp;quot; verwenden um die Verzeichnisse auf den neusten Stand zu bringen.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|Sollte ihre Firewall den Zugriff auf die Ports verweigern, können Sie '''svn://anonsvn.kde.org/'''durch '''svn://websvn.kde.org:443/''' ersetzen.}}&lt;br /&gt;
&lt;br /&gt;
'''qt-copy''' is a copy of the latest stable [http://www.trolltech.com Qt] release which works with KDE, put into SVN for convenience. It also contains patches by KDE developers that haven't found their way to Qt yet. They are recommended for those working with KDE from '''trunk'''. You can obtain '''qt-copy''' by doing:&lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/trunk/qt-copy&lt;br /&gt;
&lt;br /&gt;
If you wish to have a complete copy of the KDE distribution, you can simply check out the entire source tree with one command:&lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/trunk/KDE&lt;br /&gt;
&lt;br /&gt;
{{note (de)|It is smarter to first use [http://websvn.kde.org/trunk/KDE The KDE Source Repository Web Viewer]. Use it to choose which modules to download. This way KDE will be quicker to install and try out.}}&lt;br /&gt;
&lt;br /&gt;
If you want additional software packages you can check out the following modules within '''trunk/''' as well:&lt;br /&gt;
&lt;br /&gt;
 koffice&lt;br /&gt;
 extragear&lt;br /&gt;
 playground&lt;br /&gt;
 kdereview&lt;br /&gt;
&lt;br /&gt;
So, for example, if you want to check out koffice trunk, you can use &lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/trunk/koffice&lt;br /&gt;
&lt;br /&gt;
=== Checking out trunk using snapshots ===&lt;br /&gt;
&lt;br /&gt;
If you are checking out modules from '''trunk/''' you may be able to save time by using snapshots.  Using Subversion trunk snapshots is described at [[../Snapshots|the Subversion snapshots tutorial page]].&lt;br /&gt;
&lt;br /&gt;
=== Checking out KDE 3 instead ===&lt;br /&gt;
&lt;br /&gt;
If you want to track KDE 3 rather than the bleeding edge, you may retrieve the KDE 3.5 sources using:&lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/branches/arts/1.5/arts&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/branches/KDE/3.5/&lt;br /&gt;
&lt;br /&gt;
And if you want the matching qt-copy:&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/branches/qt/3.3/qt-copy&lt;br /&gt;
&lt;br /&gt;
=== Checking out specific releases ===&lt;br /&gt;
&lt;br /&gt;
KDE modules are also tagged at each release so that it is possible to get a specific release of KDE. Most KDE modules have a tag name in the format '''tags/KDE/X.Y.Z''' (where X, Y and Z represent the exact version). The arts module (only needed for KDE 2 and KDE 3) has a different format of tag name, '''tags/arts/X.Y.Z'''. For instance to get kdelibs as it was shipped in KDE 3.5.0, do: &lt;br /&gt;
&lt;br /&gt;
 svn co svn://anonsvn.kde.org/home/kde/tags/KDE/3.5.0/kdelibs/&lt;br /&gt;
&lt;br /&gt;
If you then want to update this checkout to KDE 3.5.5, use this command:&lt;br /&gt;
&lt;br /&gt;
 svn switch svn://anonsvn.kde.org/home/kde/tags/KDE/3.5.5/kdelibs&lt;br /&gt;
&lt;br /&gt;
{{tip|If you used a '''/branch/''' or '''/trunk/''' path, then there is no need to switch, just run '''svn update'''.}}&lt;br /&gt;
&lt;br /&gt;
{{tip|[http://websvn.kde.org/tags/ WebSVN] is a convenient way to check for a tag name.}}&lt;br /&gt;
&lt;br /&gt;
=== Checking out translations ===&lt;br /&gt;
If you are looking for translations and other localizations, check out the appropriate language from the [http://websvn.kde.org/trunk/l10n l10n] module. &lt;br /&gt;
&lt;br /&gt;
{{Warning (de)|The l10n module is ''extremely'' large. Be sure you have lots of time and disk space on hand before checking out the entire l10n module. Most people only check out specific language subdirectories rather than the entire l10n module.}}&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started_(de)</id>
		<title>Getting Started (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started_(de)"/>
				<updated>2008-01-16T08:35:57Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Changed link to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting_Started}}&lt;br /&gt;
{{Box|Zugriff auf die Quellen|&lt;br /&gt;
[[Image:Action_down.svg|right|32px]]&lt;br /&gt;
Der KDE-Quelltext ist auf verschiedenen Wegen erhältlich:&lt;br /&gt;
* [[Getting Started/Sources/Anonymous SVN (de)|Anonymes SVN Schnellstart Anleitung]]&lt;br /&gt;
* [[Getting Started/Sources/Using Subversion with KDE|Benutzung von Subversion mit KDE]] ''Benutzung von Subversion mit KDE. Ein mehr in die Tiefe gehender Einblick für den Zugriff auf KDEs Quelltext mit Subversion, einschließlich dem Depot Layout und dem Arbeiten mit Revisionen und Patches.''&lt;br /&gt;
* [http://websvn.kde.org/ Durchstöbern Sie den Quelltext online]&lt;br /&gt;
* [[Getting Started/Sources/Snapshots|Tägliche Schnappschüsse]]&lt;br /&gt;
|100%}}&lt;br /&gt;
&lt;br /&gt;
{{Box|Erstellung von KDE|&lt;br /&gt;
[[Image:Action_tool.svg|right|32px]]&lt;br /&gt;
Es existieren verschiedene KDE Zweige. Für den produktiven Einsatz wird eine stabile Version empfohlen.&lt;br /&gt;
* [[Getting Started/Build/KDE4_(de)|KDE 4 (Entwicklungs Version, Trunk)]]&lt;br /&gt;
* [[Getting Started/Build/Stable Version|KDE 3.5 (Stabile Version)]]&lt;br /&gt;
* [[Getting Started/Build|Andere Versionen und das FAQ]] ''Einschließlich Informationen für die Erstellung auf Nicht-Linux Systemen''&lt;br /&gt;
|100%}}&lt;br /&gt;
&lt;br /&gt;
{{Box|Aufsetzen der Umgebung|&lt;br /&gt;
[[Image:Action_pen.svg|right|32px]]&lt;br /&gt;
Nachdem KDE erstellt worden ist, möchten Sie wahrscheinlich einen wirksamen Weg für das Starten der Anwendungen und das Ausführen Ihrer üblichen Entwicklungsaufgaben haben:&lt;br /&gt;
* [[Getting Started/Increased Productivity in KDE4 with Scripts|Erhöhen Sie Ihre Produktivität in KDE4 mit Skripten]]&lt;br /&gt;
* [[Getting Started/Set up KDE 4 for development|Setzen Sie KDE4 für die Entwicklung auf]]&lt;br /&gt;
|100%}}&lt;br /&gt;
[[Category:Build KDE]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Sources/Subversion</id>
		<title>Getting Started/Sources/Subversion</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Sources/Subversion"/>
				<updated>2008-01-16T08:34:33Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting Started/Sources/Using Subversion with KDE}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
&lt;br /&gt;
series=Getting Started|&lt;br /&gt;
&lt;br /&gt;
name=Using Subversion With KDE|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
&lt;br /&gt;
This is a quick KDE-specific introduction for using subversion to access files and software in KDE's repositories. For comprehensive coverage of Subversion we recommend reading the book&lt;br /&gt;
&amp;quot;[http://svnbook.red-bean.com/ Version Control with Subversion]&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
== Getting started ==&lt;br /&gt;
&lt;br /&gt;
In order to use the KDE Subversion repository, you will need two things:&lt;br /&gt;
&lt;br /&gt;
# A Subversion client program&lt;br /&gt;
# An account in our repository&lt;br /&gt;
&lt;br /&gt;
Note: For anonymous read-only access use protocol &amp;quot;svn&amp;quot;, no &amp;quot;yourname@&amp;quot; and server &amp;quot;anonsvn.kde.org&amp;quot; instead below.&lt;br /&gt;
&lt;br /&gt;
'''Installing Subversion:''' instructions on installing the client are not&lt;br /&gt;
presented here. Refer to your system installation instructions to find out how&lt;br /&gt;
you can install Subversion. You will need version 1.1 at least. If you are&lt;br /&gt;
compiling from sources and want to access the KDE repository by https&lt;br /&gt;
(and not by svn+ssh), you will need SSL and ZLIB support,&lt;br /&gt;
so you will need the &amp;lt;tt&amp;gt;--with-ssl --with-zlib&amp;lt;/tt&amp;gt; options.&lt;br /&gt;
&lt;br /&gt;
Alternatively, you can install one of the many graphical clients out there.&lt;br /&gt;
This tutorial is intended for people using the &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; program only, referring&lt;br /&gt;
to tasks accomplished with the usual &amp;lt;tt&amp;gt;cvs&amp;lt;/tt&amp;gt; program.&lt;br /&gt;
&lt;br /&gt;
'''Getting an account:''' if you had a CVS&lt;br /&gt;
account before, it has been migrated to the new Subversion client. If&lt;br /&gt;
you didn't, refer to the [[Contribute/Get_a_SVN_Account|corresponding tutorial]] how to get one.&lt;br /&gt;
&lt;br /&gt;
{{Note|If you have lost your CVS password, there are simple ways to retrieve&lt;br /&gt;
it. Use [http://ktown.kde.org/~coolo/cvspwd.c cvspwd.c] or [http://kdab.net/~dfaure/cvs-unscramble cvs-unscramble] (Perl).}}&lt;br /&gt;
&lt;br /&gt;
== The KDE repository structure ==&lt;br /&gt;
&lt;br /&gt;
 svn.kde.org/home/kde&lt;br /&gt;
&lt;br /&gt;
That's the address of the KDE Subversion repository. The repository is served by&lt;br /&gt;
HTTPS or SVN+SSH protocol, which means your password is secure against third-party&lt;br /&gt;
eavesdropping.&lt;br /&gt;
&lt;br /&gt;
The SSL certificate md5 fingerprint for the repositories:&lt;br /&gt;
 F6BF EDE2 D016 D1B2   4F18 742E 2C8F B7EF&lt;br /&gt;
&lt;br /&gt;
The SSL certificate sha1 fingerprint for the repositories:&lt;br /&gt;
 e1:e6:41:96:3c:eb:ae:78:e2:73:0d:a2:32:2f:6b:21:13:bf:3d:0f&lt;br /&gt;
&lt;br /&gt;
For people using svn+ssh, here's the fingerprint of the server's RSA key:&lt;br /&gt;
 86:f3:66:06:20:74:81:d0:1b:b4:2f:25:03:f7:8e:fb&lt;br /&gt;
&lt;br /&gt;
The repository is organised in main directories:&lt;br /&gt;
&lt;br /&gt;
# /branches&lt;br /&gt;
# /tags&lt;br /&gt;
# /trunk&lt;br /&gt;
&lt;br /&gt;
You can explore the repository structure at [http://websvn.kde.org/ http://websvn.kde.org/]&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
=== The top-level directory /trunk ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt;&lt;br /&gt;
top-level subdirectory is where the main development for KDE occurs.&lt;br /&gt;
What you will find here is what will become the next KDE release, and&lt;br /&gt;
its associated programs. Here you will also find the &amp;lt;tt&amp;gt;www&amp;lt;/tt&amp;gt; module,&lt;br /&gt;
which contains webpages for KDE's site and related ones.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;/trunk&amp;lt;/tt&amp;gt; is further subdivided into these sub-directories:&lt;br /&gt;
&lt;br /&gt;
*&amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;KDE itself, what will become the next public release. It contains the following modules:&lt;br /&gt;
**'''kdelibs''' - KDE basic libraries, used by all KDE programs&lt;br /&gt;
**'''kdebase''' - KDE base programs, like the KDE Control Center, Kicker (the panel) and Konqueror (the web browser)&lt;br /&gt;
**'''kdeaccessibility''' - Accessibility files&lt;br /&gt;
**'''kdeadmin''' - KDE Administration applications&lt;br /&gt;
**'''kdeartwork''' - Images, themes, sounds and other art files&lt;br /&gt;
**'''kdebindings''' - Bindings for languages other than C++&lt;br /&gt;
**'''kdeedu''' - KDE Educational applications&lt;br /&gt;
**'''kdegames''' - KDE Games&lt;br /&gt;
**'''kdegraphics''' - KDE Graphical applications&lt;br /&gt;
**'''kdemultimedia''' - KDE Multimedia applications&lt;br /&gt;
**'''kdenetwork''' - KDE Networking applications&lt;br /&gt;
**'''kdepim''' - KDE Personal Information Management applications&lt;br /&gt;
**'''kdepimlibs''' - Libraries used by KDE-PIM applications.&lt;br /&gt;
**'''kdesdk''' - KDE Software Development Kit applications&lt;br /&gt;
**'''kdetoys''' - KDE toy applications&lt;br /&gt;
**'''kdeutils''' - KDE General utilities&lt;br /&gt;
**'''kdevelop''' - The KDevelop program&lt;br /&gt;
**'''kdevplatform''' - The development platform which KDevelop is based on&lt;br /&gt;
**'''kdewebdev''' - KDE Web development applications&lt;br /&gt;
*&amp;lt;tt&amp;gt;kde-common&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Common admin/ directory&lt;br /&gt;
*&amp;lt;tt&amp;gt;bugs/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:[http://bugs.kde.org/ Bugzilla] files&lt;br /&gt;
*&amp;lt;tt&amp;gt;developer.kde.org/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The content of developer.kde.org&lt;br /&gt;
*&amp;lt;tt&amp;gt;extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:KDE programs outside the main KDE releases.&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdereview/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Temporary home for KDE applications that are believed to have reached release-quality. From here, once all major issues are resolved, applications are moved either to &amp;lt;tt&amp;gt;/trunk/KDE/&amp;lt;/tt&amp;gt; or to &amp;lt;tt&amp;gt;/trunk/extragear/&amp;lt;/tt&amp;gt;&lt;br /&gt;
*&amp;lt;tt&amp;gt;kdesupport/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Supporting applications and libraries for KDE&lt;br /&gt;
*&amp;lt;tt&amp;gt;koffice/&amp;lt;/tt&amp;gt;&amp;lt;br/&amp;gt;The KDE Office suite, containing the programs:&lt;br /&gt;
**'''karbon'''&lt;br /&gt;
**'''kchart'''&lt;br /&gt;
**'''kexi'''&lt;br /&gt;
**'''kformula'''&lt;br /&gt;
**'''kivio'''&lt;br /&gt;
**'''koshell'''&lt;br /&gt;
**'''kplato'''&lt;br /&gt;
**'''kpresenter'''&lt;br /&gt;
**'''krita'''&lt;br /&gt;
**'''kspread'''&lt;br /&gt;
**'''kugar'''&lt;br /&gt;
**'''kword'''&lt;br /&gt;
*&amp;lt;tt&amp;gt;konstruct/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Konstruct, the KDE build program&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde3/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for the &amp;quot;unstable&amp;quot; modules of KDE 3 (extragear, playground)&lt;br /&gt;
*&amp;lt;tt&amp;gt;l10n-kde4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Translations for KDE 4&lt;br /&gt;
*&amp;lt;tt&amp;gt;playground/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The KDE playground: applications being developed, but not having yet reached release-quality.&lt;br /&gt;
*&amp;lt;tt&amp;gt;qt-copy/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The convenience copy of [http://www.trolltech.com/ Trolltech's] Qt library, which KDE is based upon.&lt;br /&gt;
*&amp;lt;tt&amp;gt;tests/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:khtml, KOffice and ksvg testcases&lt;br /&gt;
*&amp;lt;tt&amp;gt;valgrind/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:The Valgrind application, which is hosted on the KDE repository, but that is not part of KDE itself.  Note that newer versions of Valgrind are developed on their own repository.  The KDE Valgrind modules only holds up to Valgrind 2.4.&lt;br /&gt;
*&amp;lt;tt&amp;gt;www/&amp;lt;/tt&amp;gt;&lt;br /&gt;
:Webpages for the KDE site (and related sites). Write access to this directory is restricted.&lt;br /&gt;
&lt;br /&gt;
=== The top-level directory &amp;lt;tt&amp;gt;/tags&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This&lt;br /&gt;
directory contains the official releases of the programs maintained and&lt;br /&gt;
developed in the KDE repository. Each individual application has a&lt;br /&gt;
subdirectory here. Inside it, you will find the release numbers.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.0 code can be found under &amp;lt;tt&amp;gt;/tags/KDE/3.4.0/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
=== The top-level directory &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; ===&lt;br /&gt;
&lt;br /&gt;
This directory contains the branch versions of the applications after a major release.&lt;br /&gt;
&lt;br /&gt;
Most&lt;br /&gt;
KDE applications adhere to the philosphy that new features (as well as&lt;br /&gt;
new user-visible strings) are added only to the next release cycle &amp;amp;#8212;&lt;br /&gt;
the one that lives in &amp;lt;tt&amp;gt;/trunk/&amp;lt;/tt&amp;gt;. However, bugfixes are applied to all&lt;br /&gt;
applications, even after release.&lt;br /&gt;
&lt;br /&gt;
In&lt;br /&gt;
order to do that, a branch is created at the moment of the release,&lt;br /&gt;
indicating the state of the files at that time. Bugfixes are then&lt;br /&gt;
checked in to those files. Those branches are the ones in &amp;lt;tt&amp;gt;/branches/&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
For instance, the KDE 3.4.x branch can be found under &amp;lt;tt&amp;gt;/branches/KDE/3.4/&amp;lt;/tt&amp;gt;&lt;br /&gt;
&lt;br /&gt;
The subdirectories you will find inside &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt; are the&lt;br /&gt;
application subdirs, like &amp;lt;tt&amp;gt;akregator/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;amarok/&amp;lt;/tt&amp;gt;,&lt;br /&gt;
&amp;lt;tt&amp;gt;arts/&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;k3b/&amp;lt;/tt&amp;gt;, etc. You will also find a &amp;lt;tt&amp;gt;KDE/&amp;lt;/tt&amp;gt;&lt;br /&gt;
subdir, containing the official KDE releases since time immemorial.&lt;br /&gt;
&lt;br /&gt;
One special subdir is found in &amp;lt;tt&amp;gt;/branches&amp;lt;/tt&amp;gt;: &amp;lt;tt&amp;gt;work/&amp;lt;/tt&amp;gt;. This&lt;br /&gt;
subdir contains the so-called &amp;quot;work branches&amp;quot;, that is, branches containing&lt;br /&gt;
features being worked on, sometimes highly experimental. Multi-application&lt;br /&gt;
work branches always are checked in to &amp;lt;tt&amp;gt;/branches/work/&amp;lt;/tt&amp;gt;, but&lt;br /&gt;
single-application branches may be found in each application's subdir. That&lt;br /&gt;
is a decision left to the developers.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Checking out and updating ==&lt;br /&gt;
&lt;br /&gt;
=== Checking out ===&lt;br /&gt;
In order to check out something with Subversion, you use the &amp;lt;tt&amp;gt;checkout&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
'''WARNING:''' If you checkout trunk/KDE/ or branches/KDE/foo/ you will download complete kde-i18n!&lt;br /&gt;
&lt;br /&gt;
Suppose you wanted to check out only KDevelop from the KDE repository. You would do:&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde login&lt;br /&gt;
 cvs -d :pserver:yourname@cvs.kde.org:/home/kde checkout kdevelop&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
&lt;br /&gt;
CVS users currently using ssh access, should use protocol svn+ssh,&lt;br /&gt;
CVS users currently using password access, should use protocol https&lt;br /&gt;
in the following.&lt;br /&gt;
&lt;br /&gt;
 svn checkout &amp;amp;lt;protocol&amp;amp;gt;://&amp;amp;lt;username&amp;amp;gt;@svn.kde.org/home/kde/trunk/KDE/kdevelop&lt;br /&gt;
&lt;br /&gt;
=== Updating ===&lt;br /&gt;
&lt;br /&gt;
In order to update, you use the &amp;lt;tt&amp;gt;update&amp;lt;/tt&amp;gt; subcommand.&lt;br /&gt;
&lt;br /&gt;
This is no different from CVS: you change into your checked out copy (for those new to this whole process, the checked out copy should be in your Home folder) and issue a &amp;lt;tt&amp;gt;svn update&amp;lt;/tt&amp;gt; (or, shorter, &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt;) command.&lt;br /&gt;
&lt;br /&gt;
== Knowing the status of a file ==&lt;br /&gt;
&lt;br /&gt;
To know which local files you had modified, in CVS most people did&lt;br /&gt;
 cvs up&lt;br /&gt;
and looked at the files with '''M''', this does not work with svn so you have to do&lt;br /&gt;
 svn status&lt;br /&gt;
to know the status of the files.&lt;br /&gt;
&lt;br /&gt;
== Committing to the repository ==&lt;br /&gt;
&lt;br /&gt;
Just like in CVS, committing to the Subversion repository is accomplished&lt;br /&gt;
with the &amp;lt;tt&amp;gt;commit&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;checkin&amp;lt;/tt&amp;gt; (&amp;lt;tt&amp;gt;ci&amp;lt;/tt&amp;gt; for short) subcommands.&lt;br /&gt;
&lt;br /&gt;
CVS command:&lt;br /&gt;
 cvs commit&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci&lt;br /&gt;
 # or&lt;br /&gt;
 cvs ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
Subversion command:&lt;br /&gt;
 svn commit&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci&lt;br /&gt;
 # or&lt;br /&gt;
 svn ci filename.cpp&lt;br /&gt;
&lt;br /&gt;
This way, &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; will launch the editor specified in &amp;lt;tt&amp;gt;$SVN_EDITOR&amp;lt;/tt&amp;gt; for you&lt;br /&gt;
to compose the commit message. If you prefer, you can give &amp;lt;tt&amp;gt;svn&amp;lt;/tt&amp;gt; the -m&lt;br /&gt;
oprtion with your full message:&lt;br /&gt;
&lt;br /&gt;
 svn ci -m &amp;quot;Updating protocol to conform to HTTP/1.1&amp;quot;&lt;br /&gt;
&lt;br /&gt;
== Ignoring files ==&lt;br /&gt;
&lt;br /&gt;
Subversion stores ignored files per directory. To edit the ignored&lt;br /&gt;
files of the directory you are currently in, do&lt;br /&gt;
  svn propedit svn:ignore .&lt;br /&gt;
that will launch your editor, write there the names of the files you want to&lt;br /&gt;
ignore, one file per line. Once you are done, do a commit so the ignored list&lt;br /&gt;
file gets updated on the server.&lt;br /&gt;
&lt;br /&gt;
A lot of files were ignored in CVS with help from global ignore list which&lt;br /&gt;
is not supported yet by SVN. You can wait for svn 1.3 or you need to add the&lt;br /&gt;
ignore list to the [miscellany] group in your {{path|~/.subversion/config}} (all in&lt;br /&gt;
one line):&lt;br /&gt;
&lt;br /&gt;
 global-ignores = *.o *.lo *.la .*.rej *.rej .*~ *~ .#* #*# .DS_Store *.moc&lt;br /&gt;
 *.moc.cc *.moc.cpp config.log config.status config.cache *.gmo .deps .libs&lt;br /&gt;
 SunWS_cache *.lo *.la *.rpo *.la.closure *_la_closure.cpp *_la_closure.cc&lt;br /&gt;
 *_la_closure.cxx *.all_cc.cc *.all_cpp.cpp *.all_C.C *.all_cxx.cxx&lt;br /&gt;
 *_meta_unload.cc *_meta_unload.h *_meta_unload.cpp *_meta_unload.C&lt;br /&gt;
 *_meta_unload.cxx index.cache.bz2 .memdump Makefile.rules.in Makefile.calls.in&lt;br /&gt;
 Makefile.rules Makefile.calls autom4te.cache *.kidl&lt;br /&gt;
&lt;br /&gt;
== Working with multiple revisions and branches ==&lt;br /&gt;
&lt;br /&gt;
Unlike CVS, Subversion doesn't generate a revision number for each file&lt;br /&gt;
modified. Instead, the full repository is versioned, as a whole. This way, a&lt;br /&gt;
given revision number represents the state the repository was on a given date.&lt;br /&gt;
In other words, a revision number is like a timestamp (in fact, the Subversion&lt;br /&gt;
server uses this fact to search for dates in the repository faster).&lt;br /&gt;
&lt;br /&gt;
So, for instance, when you check out the KDE repository, Subversion will&lt;br /&gt;
tell you the following:&lt;br /&gt;
&lt;br /&gt;
 Updated to revision 403821.&lt;br /&gt;
&lt;br /&gt;
This means that the latest revision available at the time of the operation&lt;br /&gt;
was 403821. If you make a modification and commit, Subversion will update the&lt;br /&gt;
server-side revision and will inform you of it. Like CVS, only the committed&lt;br /&gt;
files will be updated: you will need run &amp;lt;tt&amp;gt;cvs up&amp;lt;/tt&amp;gt; to update the rest of the&lt;br /&gt;
files.&lt;br /&gt;
&lt;br /&gt;
If you want to retrieve a specific revision of a file, you can use the &amp;lt;tt&amp;gt;-r&amp;lt;/tt&amp;gt;&lt;br /&gt;
switch. Besides the revision number itself, -r accepts a number of other&lt;br /&gt;
possibilities:&lt;br /&gt;
  &lt;br /&gt;
* The revision number: for example, use -r 403819 to retrieve that version&lt;br /&gt;
* '''BASE''': the revision you updated to&lt;br /&gt;
* '''COMMITTED''': the revision a file was last modified, before BASE&lt;br /&gt;
* '''PREV''': the revision of the previous commit to the file before COMMITTED&lt;br /&gt;
* '''HEAD''': the most recent revision available in the server&lt;br /&gt;
* '''{ date }''': between curly brackets, you can specify a date for searching the closest revisions&lt;br /&gt;
&lt;br /&gt;
The following illustrates the evolution of the keywords:&lt;br /&gt;
&lt;br /&gt;
# You run &amp;lt;tt&amp;gt;svn up&amp;lt;/tt&amp;gt; to update to the latest available revision. Suppose Subversion tells you it updated to revision 403821. This means that HEAD and BASE are 403821.&lt;br /&gt;
# You modify file README and commit it. Suppose Subversion tells you it committed revision 403822. This means HEAD, BASE and COMMITTED are 403822.&lt;br /&gt;
# You modify the file again and commit it. Now PREV is 403822, but HEAD, BASE and COMMITTED are updated to a new value (suppose it's 403823).&lt;br /&gt;
# Now someone else modifies the repository, and you update your working copy. If Subversion tells you it updated to 403824, this means now HEAD and BASE are moved to 403824 (but PREV and COMMITTED stay the same)&lt;br /&gt;
# If someone modifies the README file now, HEAD is moved. The other keywords stay the same for you, until you update. At this time, we will have HEAD = 403825 (the latest available revision), BASE = 403824 (the revision you last updated to), COMMITTED = 403823 (the revision of the latest change to the file when you last updated) and PREV = 403822 (the revision of the change before COMMITTED)&lt;br /&gt;
&lt;br /&gt;
Those keywords are useful to retrieve logs and diffs for commits to the&lt;br /&gt;
repository.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your working copy and BASE, you&lt;br /&gt;
can run:&lt;br /&gt;
&lt;br /&gt;
 svn diff&lt;br /&gt;
&lt;br /&gt;
This is a very fast operation, since Subversion keeps a local copy of BASE.&lt;br /&gt;
It doesn't need a network connection to accomplish this operation.&lt;br /&gt;
&lt;br /&gt;
If you want to see the difference between your local copy and the latest&lt;br /&gt;
available on the server, you will run:&lt;br /&gt;
&lt;br /&gt;
 svn diff -r HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see what has changed in the repository since you've last updated, you can use:&lt;br /&gt;
 svn diff -r BASE:HEAD&lt;br /&gt;
&lt;br /&gt;
If you want to see the last change to a file before BASE, you can use:&lt;br /&gt;
 svn diff -r PREV:BASE&lt;br /&gt;
 # or&lt;br /&gt;
 svn diff -r PREV:COMMITTED&lt;br /&gt;
&lt;br /&gt;
That is also valid for the &amp;lt;tt&amp;gt;svn log&amp;lt;/tt&amp;gt; command.&lt;br /&gt;
&lt;br /&gt;
== Linking in subdirectories from other places ==&lt;br /&gt;
&lt;br /&gt;
It can happen you would like to include a copy of a subdirectory from another place, but just for convenience, not for developing the code in there. Of course it should be updated automatically whenever the original changes. Subversion can help you. You need to edit the property &amp;lt;tt&amp;gt;svn:external&amp;lt;/tt&amp;gt; of the directory the subdirectory should be added to. So for the current directory you use&lt;br /&gt;
 svn propedit svn:externals .&lt;br /&gt;
and then enter lines of the form&lt;br /&gt;
 libkhalkhi svn://anonsvn.kde.org/home/kde/trunk/playground/pim/khalkhi&lt;br /&gt;
Updating will now fetch &amp;lt;tt&amp;gt;/trunk/playground/pim/khalkhi&amp;lt;/tt&amp;gt; into the subdirectoy &amp;lt;tt&amp;gt;libkhalkhi&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
{{warning|Beware that you cannot commit changes you did to the local copy of the external subdirectory, it is just a readonly copy.}}&lt;br /&gt;
&lt;br /&gt;
You use &amp;lt;tt&amp;gt;svn://anonsvn.kde.org&amp;lt;/tt&amp;gt; and not another protocol, because &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt; is accessible to everyone. Using &amp;lt;tt&amp;gt;https:&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;svn+ssh:&amp;lt;/tt&amp;gt; would only work for users of that protocol. There are still some small disadvantage with &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;: It is not always in synchronization with &amp;lt;tt&amp;gt;svn.kde.org&amp;lt;/tt&amp;gt;, so updates in the original branch may take a while to appear on &amp;lt;tt&amp;gt;anonsvn.kde.org&amp;lt;/tt&amp;gt;. And some strict firewalls are blocking the &amp;lt;tt&amp;gt;svn:&amp;lt;/tt&amp;gt; protocol.&lt;br /&gt;
&lt;br /&gt;
A special case in KDE 3 is the subdirectory &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt;, containing the KDE 3 build utilities. It is linked in to the top directory in all modules, and maintained in &amp;lt;tt&amp;gt;/branches/KDE/3.5/kde-common&amp;lt;/tt&amp;gt;. For &amp;lt;tt&amp;gt;admin&amp;lt;/tt&amp;gt; the KDE subversion server is configured to allow readonly access for everyone, so if you see&lt;br /&gt;
 admin https://svn.kde.org/home/kde/branches/KDE/3.5/kde-common/admin&lt;br /&gt;
there is no need to change this.&lt;br /&gt;
&lt;br /&gt;
== More information on the kde wiki ==&lt;br /&gt;
&lt;br /&gt;
See [http://wiki.kde.org/tiki-index.php?page=KDE%20Subversion%20HOWTO the KDE wiki] for more&lt;br /&gt;
information about subversion in KDE&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Getting_Started/Set_up_KDE_4_for_development_(de)</id>
		<title>Getting Started/Set up KDE 4 for development (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Getting_Started/Set_up_KDE_4_for_development_(de)"/>
				<updated>2008-01-14T17:04:09Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Changed to german templates&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Getting_Started/Set_up_KDE_4_for_development}}&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Am Anfang|&lt;br /&gt;
&lt;br /&gt;
name=KDE 4 für Entwicklung von Software aufsetzen|&lt;br /&gt;
&lt;br /&gt;
pre=[[Getting_Started/Build/KDE4 (de)|KDE 4 erzeugen]]|&lt;br /&gt;
&lt;br /&gt;
next=[[Development (de)|Anderes zum Thema Entwickeln in KDE4]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Diese Seite setzt voraus, dass Sie bereits kdelibs, kdepimlibs und kdebase anhand der der Anleitung unter [[Getting Started/Build/KDE4]] erstellt haben}}&lt;br /&gt;
&lt;br /&gt;
== KDE 4 Anwendungen &amp;amp; Sitzungen starten ==&lt;br /&gt;
&lt;br /&gt;
Um mit der Entwicklung für KDE 4 zu beginnen, gibt es folgende drei Möglichkeiten:&lt;br /&gt;
* Sie können [[Getting_Started/Set_up_KDE_4_for_development_(de)#KDE_4_Anwendungen_starten|KDE 4 Anwendungen neben anderen Anwendungen]] in Ihrer aktuellen Desktop Umgebung ausführehn.&lt;br /&gt;
* Sie können in Ihre aktuelle Desktop Umgebung  [[Getting_Started/Set_up_KDE_4_for_development_(de)#Eingebettete_KDE_4_Sitzung|eine KDE 4 Sitzung einbetten]].&lt;br /&gt;
* Sie können [[Getting_Started/Set_up_KDE_4_for_development_(de)#Eigenständige_KDE_4_Sitzung|KDE 4 als eigene Sitzung]] ausführen.&lt;br /&gt;
&lt;br /&gt;
Alle drei Optionen werden nachfolgend beschrieben.&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Wenn Sie beim ausführen von KDE 4 Anwendungen Fehler wie den folgenden erhalten:&lt;br /&gt;
  Qt: Session management error: Could not open network socket&lt;br /&gt;
  QMutex::lock: Deadlock detected in thread -1241241936&lt;br /&gt;
Oder wenn Sie startkde ausführen und es hängenbleibt, lesen Sie [http://www.nabble.com/QMutex::lock:-Deadlock-detected---running-KDE4-apps-%22using-the-normal-shell%22-t3584446.html diesen Artikel] für einen möglichen Ausweg.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
=== KDE 4 Anwendungen starten ===&lt;br /&gt;
==== Auf der normalen Shell mit sux ====&lt;br /&gt;
&lt;br /&gt;
Für diese Methode wird das Tool '''sux''' (http://fgouget.free.fr/sux/sux-readme.shtml) benötigt. '''sux''' ist in den meisten Distributionen bereits enthalten. Anderenfalls können Sie auf die unten beschriebene Methode ''Normale Shell ohne sux'' zurückgreifen. '''sux''' erlaubt Ihnen, zu einem anderen Nutzer zu wechseln und konfiguriert dabei automatisch das X Forwarding (Authentifizierung und Export der DISPLAY Variable).&lt;br /&gt;
&lt;br /&gt;
Um sich anzumelden, geben Sie  &amp;lt;code bash&amp;gt;sux - kde-devel&amp;lt;/code&amp;gt; ein.&lt;br /&gt;
&lt;br /&gt;
Alle Umgebungsvariablen und alles sonstige sollten korrekt von Ihrer {{path|[[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|.bashrc]]}}&lt;br /&gt;
gesetzt werden. Um eine Applikation zu starten, geben Sie einfach ihren Namen ein; zum Beispiel: &amp;lt;code bash&amp;gt;kwrite&amp;lt;/code&amp;gt;&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Wenn Sie Fehlermeldungen über fehlende MIME-Typen oder ähnliches erhalten, versuchen Sie folgendes:&lt;br /&gt;
* führen Sie &amp;lt;code bash&amp;gt;unset XDG_DATA_DIRS ; kbuildsycoca4&amp;lt;/code&amp;gt; aus.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==== Normal Shell ohne sux ====&lt;br /&gt;
Die einfachste Methode um KDE 4 Anwendungen zu starten, ist es &amp;lt;tt&amp;gt;su&amp;lt;/tt&amp;gt; zur Anmeldung als &amp;lt;tt&amp;gt;kde-devel&amp;lt;/tt&amp;gt; Benutzer zu benutzen und dann einfach die gewünschten KDE 4 Anwendung von der Shell aufzurufen. Um sich anzumelden, geben Sie &amp;lt;code bash&amp;gt;su - kde-devel&amp;lt;/code&amp;gt; &lt;br /&gt;
ein und nachdem Sie Ihr Passwort eingegeben haben führen Sie&lt;br /&gt;
&amp;lt;code bash&amp;gt;export DISPLAY=:0&amp;lt;/code&amp;gt; aus.&lt;br /&gt;
{{Note (de)|Das Exportieren der &amp;lt;tt&amp;gt;DISPLAY&amp;lt;/tt&amp;gt; Variable ist nötig, damit die KDE 4 Anwendungen auf Ihrem normalen KDE 3 Desktop erscheinen.}}&lt;br /&gt;
Alle Umgebungsvariablen und alles sonstige sollte bereits von Ihrer {{path|[[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|.bashrc]]}} korrekt gesetzt worden sein. Um eine Anwendung zu starten, geben sie einfach ihren namen ein; zum Beispiel: &amp;lt;code bash&amp;gt;kwrite&amp;lt;/code&amp;gt;&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Wenn Sie Fehlermeldungen über fehlende MIME-Typen oder ähnliches erhalten, versuchen Sie folgendes:&lt;br /&gt;
* führen Sie &amp;lt;code bash&amp;gt;unset XDG_DATA_DIRS ; kbuildsycoca4&amp;lt;/code&amp;gt; aus&lt;br /&gt;
}}&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Wenn Sie eine Fehlermeldung erhalten, dass Sie sich nicht mit einem X-Server verbinden können, versuchen Sie &lt;br /&gt;
&amp;lt;code bash&amp;gt;sudo xhost +local:kde-devel&amp;lt;/code&amp;gt;&lt;br /&gt;
unter Ihrem normalen KDE 3 Account auszuführen um sicher zu gehen das die Anwendung sich mit der gerade laufenden X-Sitzung verbinden kann.&lt;br /&gt;
&lt;br /&gt;
Obwohl Ihr X-Server ankommende TCP Verbindungen akzeptieren sollte, ist dies oft von Distributionsseite her deaktiviert (so etwa unter Kubuntu Feisty). Wenn Sie &amp;lt;tt&amp;gt;kdm&amp;lt;/tt&amp;gt; benutzen, müssen Sie die Datei &amp;lt;tt&amp;gt;/etc/kde3/kdm/kdmrc&amp;lt;/tt&amp;gt; als root bearbeiten und überprüfen, das sie nicht folgendes enthält:&lt;br /&gt;
&amp;lt;code&amp;gt;ServerArgsLocal=-nolisten tcp&amp;lt;/code&amp;gt;&lt;br /&gt;
Wenn Sie dies geändert haben, müssen Sie den X-Server neu starten.&lt;br /&gt;
Der &amp;lt;tt&amp;gt;xhost&amp;lt;/tt&amp;gt; Befehl sollte nun nicht mehr die Meldung &amp;quot;unable to open display&amp;quot; ausgeben.&lt;br /&gt;
&lt;br /&gt;
Aus Bequemlichkeit sollte dies automatisch beim Anmelden ihres normalen Benutzers geschehen. Um dies zu erreichen, erstellen Sie eine neue Datei unter  &amp;lt;tt&amp;gt;$HOME/.kde/Autostart&amp;lt;/tt&amp;gt; Ihres normalen Benutzers mit dem folgenden Inhalt:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
#! /bin/sh&lt;br /&gt;
xhost +local:kde-devel&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Stellen Sie sicher, das die neue Datei ausführbar ist, indem Sie  &amp;lt;tt&amp;gt;chmod +x&amp;lt;/tt&amp;gt; für die Datei ausführen.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie mehr über die '''Sicherheitsrisiken''' in Bezug auf &amp;lt;tt&amp;gt;xhost&amp;lt;/tt&amp;gt; erfahren möchten, lesen Sie [http://bau2.uibk.ac.at/matic/xsecur.htm diesen Artikel]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==== Benutzung von SSH ====&lt;br /&gt;
&lt;br /&gt;
Der einfachste Weg um eine KDE 4 Anwendung über SSH auf Ihrem aktuellen Desktop auszuführen, ist es auf folgendem Weg eine Shell mit X-Forwarding zu bekommen:&lt;br /&gt;
&amp;lt;code bash&amp;gt;ssh -X kde-devel@localhost&amp;lt;/code&amp;gt;&lt;br /&gt;
Jetzt können Sie KDE Anwendungen wie gewöhnlich ausführen, zum Beispiel:&lt;br /&gt;
&amp;lt;code bash&amp;gt;kwrite&amp;lt;/code&amp;gt;&lt;br /&gt;
Diese zwei Zeilen können auf einfache Weise kombiniert werden:&lt;br /&gt;
&amp;lt;code bash&amp;gt;ssh -X kde-devel@localhost kwrite&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
Falls Sie Fehlermeldungen erhalten, probieren Sie die Tips aus dem vorhergehenden Abschnitt aus.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
===== Anmeldung ohne Passwort =====&lt;br /&gt;
Bevor Sie vorherige Methode sinnvoll benutzen können, müssen Sie eine Anmeldung ohne Passwort einrichten. Dafür führen Sie folgenden Befehl unter Ihrem normalen Benutzeraccount aus:&lt;br /&gt;
&amp;lt;code bash&amp;gt;ssh-keygen -t rsa&amp;lt;/code&amp;gt;&lt;br /&gt;
Drücken Sie drei mal RETURN um den Pfad {{path|~/.ssh/id_rsa}} zu akzeptieren und ein leeres Passwort zu vergeben. Anschliessen kopieren Sie die einzelne Zeile aus {{path|~/.ssh/id_rsa.pub}} die Ihnen die Ausgabe von&lt;br /&gt;
&amp;lt;code bash&amp;gt;cat ~/.ssh/id_rsa.pub&amp;lt;/code&amp;gt; liefert, in die Zwischenablage.&lt;br /&gt;
Wechseln Sie nun mit &amp;lt;tt&amp;gt;ssh&amp;lt;/tt&amp;gt; zurück zum &amp;lt;tt&amp;gt;kde-devel&amp;lt;/tt&amp;gt; Benutzer öffnen Sie die Datei {{path|$HOME/.ssh/authorized_keys}} auf folgende Weise:&lt;br /&gt;
 ssh -X kde-devel@localhost $HOME/kde/bin/kwrite \&lt;br /&gt;
  $HOME/.ssh/authorized_keys&lt;br /&gt;
Fügen Sie dort die zuvor kopierte Zeile ein, speichern Sie die Datei und beenden Sie KWrite. Versuchen Sie nun nochmal KWrite mit dem gleichen SSH-Befehl auszuführen; Sie sollten nun kein Passwort mehr benötigen:&lt;br /&gt;
&amp;lt;code bash&amp;gt;ssh -X kde-devel@localhost $HOME/kde/bin/kwrite&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{warning (de)|Das Anmelden per SSH ohne Passwort birgt gewisse '''Sicherheitsrisiken'''. Vergewissern Sie sich deshalb, dass Ihre  &amp;lt;tt&amp;gt;~/.ssh/id_rsa&amp;lt;/tt&amp;gt; Datei geschützt ist, indem Sie den Zugriff auf sie mit &lt;br /&gt;
&amp;lt;code bash&amp;gt;chmod og-xrw ~/.ssh/id_rsa&amp;lt;/code&amp;gt; einschränken (Die Datei sollte diese Rechte eigentlich bereits bei der Erstellung erhalten haben)}}&lt;br /&gt;
&lt;br /&gt;
===== Die SSH desktop Datei =====&lt;br /&gt;
Wenn Sie Anwendungen einfacher benutzen wollen, als Sie per SSH-Befehl von der Shell zu starten, besteht ein Weg darin, &amp;lt;tt&amp;gt;.desktop&amp;lt;/tt&amp;gt; Dateien zu erstellen die automatisch per &amp;lt;tt&amp;gt;ssh&amp;lt;/tt&amp;gt; zum anderen Benutzer wechseln. &lt;br /&gt;
{{Note (de)|Dies ist nur dann nützlich, wenn Ihre Desktop-Umgebung .desktop Dateien unterstützt. Immerhin KDE und GNOME tuen dies.}}&lt;br /&gt;
&lt;br /&gt;
Sie können eine existierenden .desktop Datei als Vorlage verwenden (Etwa eine von Ihrem Desktop) oder eine neue erstellen. Die Idee dahinter ist, dem auszuführenden Kommando die SSH-Verbindung auf folgende Weise voranzustellen:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
ssh -X kde-devel@localhost $HOME/kde/bin/&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Eine einfache .desktop Datei die KWrite ausführt würde folgenden Inhalt haben:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini&amp;gt;&lt;br /&gt;
[Desktop Entry]&lt;br /&gt;
Categories=Qt;KDE;TextEditor;&lt;br /&gt;
Comment=&lt;br /&gt;
DocPath=kwrite/index.html&lt;br /&gt;
Encoding=UTF-8&lt;br /&gt;
Exec=ssh -X kde-devel@localhost /home/kde-devel/kde/bin/kwrite %U&lt;br /&gt;
GenericName=Text Editor&lt;br /&gt;
Icon=kwrite&lt;br /&gt;
InitialPreference=8&lt;br /&gt;
MimeType=text/plain&lt;br /&gt;
Name=KWrite (kde-devel)&lt;br /&gt;
Path=&lt;br /&gt;
StartupNotify=false&lt;br /&gt;
Terminal=false&lt;br /&gt;
TerminalOptions=&lt;br /&gt;
Type=Application&lt;br /&gt;
X-DBUS-StartupType=Multi&lt;br /&gt;
X-DCOP-ServiceType=non&lt;br /&gt;
X-KDE-StartupNotify=true&lt;br /&gt;
X-KDE-SubstituteUID=false&lt;br /&gt;
X-KDE-Username=&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{tip|Anwendung, die wie hier über SSH gestartet werden, lösen nicht die korrekten Startereignisse aus, so dass Sie besser die &amp;quot;Startrückmeldung&amp;quot; für Ihre .desktop Dateien deaktivieren sollten.}}&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Um auf diese Weise eine .desktop-Datei für KDE 4 Anwendungen zu erstellen, muss das Paket der Anwendung mit &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt; in &amp;lt;tt&amp;gt;~/kde/bin&amp;lt;/tt&amp;gt; installiert worden sein.}}&lt;br /&gt;
&lt;br /&gt;
=== Starten von KDE 4 Sitzungen ===&lt;br /&gt;
==== Eingebettete KDE 4 Sitzung ====&lt;br /&gt;
    {|align=&amp;quot;right&amp;quot; &lt;br /&gt;
    |[[image:Snapshot1.png|right|thumb|200px|Nested]]&lt;br /&gt;
    |}&lt;br /&gt;
Anstatt für die Software-Entwicklung einen vollständigen virtuellen X-Server zu benutzen, können Sie Xephyr zur Einbettung Ihrer KDE 4 Sitzung in Ihr KDE 3 oder  eine andere X11-Umgebung verwenden.&lt;br /&gt;
&lt;br /&gt;
Sie können dies auch mit xnest erreichen aber da xnest nicht mit Erweiterungen wie Render umgehen kann, bevorzugen viele Leute Xephyr.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie eine minimale KDE Sitzung verwenden wollen, führen Sie einfach Xephyr aus: (in Kubuntu als xserver-xephyr verfügbar; Gentoo Benutzer kompilieren x11-base/xorg-server mit USE=&amp;quot;kdrive&amp;quot;):&lt;br /&gt;
&lt;br /&gt;
 Xephyr :1&amp;amp;&lt;br /&gt;
&lt;br /&gt;
Sie können KDE nun ausführen:&lt;br /&gt;
&lt;br /&gt;
 export DISPLAY=:1&lt;br /&gt;
 /path/to/kde4/bin/startkde-modified &amp;amp;&lt;br /&gt;
&lt;br /&gt;
startkde-modified ist eine Kopie des startkde-Skripts welches die folgenden Zeilen am Anfang enthält:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
export KDEDIR=`kde4-config --prefix`&lt;br /&gt;
export LD_LIBRARY_PATH=$KDEDIR/lib&lt;br /&gt;
export PATH=$KDEDIR/bin/:$PATH&lt;br /&gt;
export KDEHOME=~/.kde4&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Sie können Xephyr auch mit KDM über das Xdmcp Protokoll benutzen und einfach eine neue KDE 4 Sitzung zu KDM hinzufügen.&lt;br /&gt;
 &lt;br /&gt;
Unter Kubuntu können Sie das erreichen indem Sie&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini&amp;gt;&lt;br /&gt;
[Xdmcp]&lt;br /&gt;
# Whether KDM should listen to incoming XDMCP requests.&lt;br /&gt;
# Default is true&lt;br /&gt;
Enable=false&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
in {{path|/etc/kde3/kdm/kdmrc}} zu&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini&amp;gt;&lt;br /&gt;
[Xdmcp]&lt;br /&gt;
# Whether KDM should listen to incoming XDMCP requests.&lt;br /&gt;
# Default is true&lt;br /&gt;
Enable=true&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
verändern und Ihre {{path|/etc/kde3/kdm/Xaccess}} anpassen um ihrem lokalen System Zugriff zu gewähren. Zusätzlich sollten Sie eine Blockierende Regel für alle Ihre externen Schnittstellen für den Xdmcp Port einrichten falls Sie dies auf einem Laptop oder einem PC in einer unsicheren Umgebung verwenden.&lt;br /&gt;
 &lt;br /&gt;
Wenn Sie soweit sind, führen Sie einfach Xephyr aus:&lt;br /&gt;
 &lt;br /&gt;
 Xephyr -query localhost :1 -host-cursor -screen 1024x768&amp;amp;&lt;br /&gt;
&lt;br /&gt;
wobei &amp;lt;tt&amp;gt;-host-cursor&amp;lt;/tt&amp;gt; versucht den Cursor des Hosts zu benutzen und &amp;lt;tt&amp;gt;-screen&amp;lt;/tt&amp;gt; die Auflösung des Bildschirms festlegt.&lt;br /&gt;
&lt;br /&gt;
Hinweis: Wenn Sie viele Fehlermeldungen bezüglich abgewiesener Verbindungen erhalten, sollten Sie die Option -ac an Xephyr übergeben:&lt;br /&gt;
&lt;br /&gt;
 Xephyr -ac :1&amp;amp;&lt;br /&gt;
&lt;br /&gt;
Eine andere Möglichkeit die Sie versuchen können, wenn Sie diese Meldungen erhalten, ist es dem kde-devel Benutzer Zugriff auf den X-Server zu geben. Als root oder mit sudo führen Sie dazu folgenden Befehl aus:&lt;br /&gt;
&lt;br /&gt;
 xhost +local:kde-devel&lt;br /&gt;
&lt;br /&gt;
Falls Ihnen Xephyr nicht zur Verfügung steht, können Sie auch Xnest benutzen:&lt;br /&gt;
&lt;br /&gt;
 Xnest -ac :1&amp;amp; export DISPLAY=:1&lt;br /&gt;
&lt;br /&gt;
&amp;lt;BR&amp;gt;&lt;br /&gt;
-----&lt;br /&gt;
{{improve}}&lt;br /&gt;
[[User:Sping|Sping]] 00:25, 9 April 2007 (CEST)&amp;lt;BR&amp;gt;&lt;br /&gt;
I use this for my start script ''nested_kde4.sh'':&lt;br /&gt;
&lt;br /&gt;
 #! /bin/bash&lt;br /&gt;
 NESTED_KDE_DISPLAY_BACKUP=$DISPLAY&lt;br /&gt;
 export DISPLAY=:0&lt;br /&gt;
 Xephyr :1 -screen 1024x768 &amp;amp;&lt;br /&gt;
 export DISPLAY=:1&lt;br /&gt;
 $HOME/kde/bin/startkde-modified &amp;amp;&lt;br /&gt;
 export DISPLAY=${NESTED_KDE_DISPLAY_BACKUP}&lt;br /&gt;
&lt;br /&gt;
Falls Sie folgende Fehlermeldung erhalten:&lt;br /&gt;
&lt;br /&gt;
 &amp;quot;Call to lnusertemp failed (temporary directories full?).&lt;br /&gt;
  Check your installation.&amp;quot;&lt;br /&gt;
&lt;br /&gt;
versuchen Sie folgendes:&lt;br /&gt;
&lt;br /&gt;
 mkdir /var/tmp/kde-devel-kde4&lt;br /&gt;
&lt;br /&gt;
Der obige Code setzt voraus das sie als Benutzer ''kde-devel'' arbeiten.&lt;br /&gt;
{{Note (de)|In den meisten Fällen müssen Sie ''startkde-modified'' mit ''startkde'' ersetzen}}&lt;br /&gt;
-----&lt;br /&gt;
&lt;br /&gt;
==== Eigenständige KDE 4 Sitzung ====&lt;br /&gt;
    {|align=&amp;quot;right&amp;quot; &lt;br /&gt;
    |[[image:solitary.png|right|thumb|200px|Solitary]]&lt;br /&gt;
    |}&lt;br /&gt;
Um eine eigenständige KDE 4 Sitzung auszuführen, können Sie sie entweder, wie gewöhnlich, auf folgende Weise von der Kommandozeile starten:&lt;br /&gt;
&lt;br /&gt;
 X :1 &amp;amp; export DISPLAY=:1&lt;br /&gt;
 startkde&lt;br /&gt;
&lt;br /&gt;
{{Note|Wenn der X-Server die Verbindung verweigert und dabei folgendes ausgibt: &amp;lt;tt&amp;gt;Xlib: connection to &amp;quot;:1.0&amp;quot; refused by server&amp;lt;/tt&amp;gt;, versuchen Sie &amp;lt;tt&amp;gt;X -ac :1&amp;lt;/tt&amp;gt; stattdessen.}}&lt;br /&gt;
&lt;br /&gt;
oder Sie können KDE 4 zu Ihrem Login Manager hinzufügen. Wenn Sie KDM (oder einen kompatiblen Login Manager) benutzen, wird dies durch Erstellen einer .desktop Datei in entweder {{path|`kde-config --prefix`/share/apps/kdm/sessions/}} oder in {{path|/usr/share/xsessions/}} erreicht. Der einfachste Weg führt dabei über das kopieren einer existierenden {{path|kde.desktop}}-Datei nach {{path|kde4.desktop}}. Öffnen Sie diese neue .desktop-Datei in einem Texteditor und ändern Sie die Einträge zu  &amp;lt;tt&amp;gt;Exec&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;TryExec&amp;lt;/tt&amp;gt; und &amp;lt;tt&amp;gt;Name&amp;lt;/tt&amp;gt; auf folgende Weise:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code ini&amp;gt;&lt;br /&gt;
Exec=$HOME/kde/bin/startkde&lt;br /&gt;
TryExec=$HOME/kde/bin/startkde&lt;br /&gt;
Name=KDE4&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Ersetzen Sie {{path|$HOME/kde}} in obigem Beispiel mit dem Pfad unter dem Sie KDE 4 installiert haben.&lt;br /&gt;
&lt;br /&gt;
Nach dem Neustart des Login Managers (&amp;lt;tt&amp;gt;Alt+e&amp;lt;/tt&amp;gt; in KDM) sollte dieser neue Eintrag im Sitzungs-Menu erscheinen.&lt;br /&gt;
&lt;br /&gt;
{{Note|Sie sollten den Pfad zum 'qdbus' Programm (normalerweise ist dies $QTDIR/bin) in Ihrer $PATH Variable haben um sich erfolgreich anzumelden. Falls es dort nicht ist, werden Sie eine Fehlermeldung &amp;quot;Could not start DBus. Check your installation.&amp;quot; erhalten.}}&lt;br /&gt;
&lt;br /&gt;
== Entwicklungs Aufgaben ==&lt;br /&gt;
=== KDevelop ===&lt;br /&gt;
&lt;br /&gt;
Dieser Abschnitt wird Ihnen erklären, wie sie KDevelop 3.4 benutzen um KDE 4 Anwendungen zu entwickeln. Wenn sie Fragen, Korrekturen oder Bedenken zu diesem Abschnitt haben, notieren Sie diese bitte auf der Diskussions-Seite.&lt;br /&gt;
&lt;br /&gt;
==== Voraussetzungen ====&lt;br /&gt;
&lt;br /&gt;
Sie benötigen hierfür mindestens KDevelop 3.4, das immernoch eine KDE 3 Anwendung ist. Versionen vor 3.4 haben unter anderem keine Qt 4 Unterstützung. Die KDE 4 Version von KDevelop ist für den produktiven Einsatz noch nicht geeignet. Sie erhalten KDevelop auf der [http://www.kdevelop.org/index.html?filename=3.4/download.html KDevelop Homepage]. Installieren Sie KDevelop wie alle anderen KDE 3 Anwendungen unter Ihrem normalen Benutzer und '''nicht''' mit Ihrem ''kde-devel'' Benutzer. &lt;br /&gt;
&lt;br /&gt;
Sie benötigen ausserdem die neueste ''GDB'' Version. Die aktuelle ist 6.6.0.&lt;br /&gt;
&lt;br /&gt;
Weiterhin müssen Sie die kdelibs API Dokumentation lokal vorliegend haben, was unter [[Getting_Started/Build/KDE4_(de)#Generating_local_API_documentation|Anleitung zum Erstellen]] beschrieben wird.&lt;br /&gt;
&lt;br /&gt;
Ausserdem benötigen Sie noch ''ctags'', ''htdig'', ''htmerge'' und ''htsearch''. ''valgrind'' und ''callgrind'' könnten auch nützlich sein.&lt;br /&gt;
&lt;br /&gt;
Stellen Sie sicher, das sie den Schritten unter KDE 4 [[Getting_Started/Build/KDE4 (de)|Anleitung zum Erstellen]] befolgt und eine funktionierende KDE 4 Umgebung erstellt haben. Prüfen Sie, ob sich einfache KDE 4 Anwendungen wie ''Konsole'' oder ''KWrite'' von der Kommandozeile des kde-devel Benutzers ohne Probleme starten lassen.&lt;br /&gt;
&lt;br /&gt;
Die folgenden Schritte werden alle mit dem '''kde-devel''' Benutzer ausgeführt. Sie müssen sich mit &amp;lt;code bash&amp;gt;su - kde-devel&amp;lt;/code&amp;gt; unter diesem Benutzer anmelden.&lt;br /&gt;
&lt;br /&gt;
==== Die Umgebung aufsetzen ====&lt;br /&gt;
&lt;br /&gt;
KDevelop hat keine native Unterstützung für CMake Projekte. Glücklicherweise hat CMake die Fähigkeit selbst KDevelop Projekt Dateien zu erstellen. Um dies zu erreichen, müssen Sie CMake den Parameter ''-GKDevelop3'' übergeben. Dies bewegt CMake dazu, Projektdateien für KDevelop neben den normalen Makefiles zu erstellen. Der beste Weg dazu ist es, die '''cmakekde ''' Funktion in Ihrer [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|{{path|.bashrc}}]] anzupassen. Ändern Sie einfach&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
cmake $srcFolder -DCMAKE_INSTALL_PREFIX=$KDEDIR \&lt;br /&gt;
-DCMAKE_BUILD_TYPE=debugfull&amp;amp;&amp;amp; \&lt;br /&gt;
make &amp;amp;&amp;amp; \&lt;br /&gt;
make install;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
in&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
cmake $srcFolder -GKDevelop3 -DCMAKE_INSTALL_PREFIX=$KDEDIR \&lt;br /&gt;
-DCMAKE_BUILD_TYPE=debugfull&amp;amp;&amp;amp; \&lt;br /&gt;
make &amp;amp;&amp;amp; \&lt;br /&gt;
make install;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Nachdem Sie das getan haben, melden Sie sich erneut an, damit sich die Veränderungen an der {{path|.bashrc}} Datei auswirken. Dann müssen Sie ''cmakekde'' erneut im (Wurzel) build Verzeichnis des Projekts an dem Sie mit KDevelop arbeiten wollen (wenn sie vorher nicht ''-GKDevelop3'' im  [[Getting_Started/Build/KDE4_(de)#Setting_up_the_environment|Erstellungsschritt]] ausgeführt haben). Wenn Sie zum Beispiel an Konsole, welches in ''kdebase'' liegt, arbeiten möchten, müssen Sie cmakekde im {{path|$KDE_BUILD/KDE/kdebase}} Verzeichnis ausführen. Dies erstellt unglücklicherweise alles erneut, aber nur einmal wenn Sie den Generator ändern.&lt;br /&gt;
&lt;br /&gt;
Da alle Umgebungsvariablen des kde-devel Benutzers KDE 4 spezifisch sind, müssen diese zurückgesetzt werden, um der KDE 3 Umgebung zu entsprechen bevor KDevelop gestartet wird. Am einfachsten wird dies erreicht, indem Sie folgende Funktion zu Ihrer {{path|.bashrc}} hinzufügen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
function start3app {&lt;br /&gt;
  mkdir -p /tmp/$USER-kde&lt;br /&gt;
  export PATH=/opt/kde3/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/bin/X11:/usr/games &lt;br /&gt;
  export LD_LIBRARY_PATH= &lt;br /&gt;
  export KDETMP=/tmp/$USER-kde &lt;br /&gt;
  export KDEVARTMP=/var/tmp/$USER-kde &lt;br /&gt;
  export KDEHOME=$HOME/.kde &lt;br /&gt;
  export KDEDIR=/usr &lt;br /&gt;
  export KDEDIRS=$KDEDIR &lt;br /&gt;
  export DISPLAY=:0 &lt;br /&gt;
  eval &amp;quot;$@&amp;quot;&lt;br /&gt;
  source $HOME/.bashrc   #Reset environment variables again&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die ''PATH'' und ''LD_LIBRARY_PATH'' Variable werden vom KDE 3 Benutzer übernommen, und sie könnten auf Ihrem System abweichen, Geben Sie &amp;lt;code bash&amp;gt;echo $PATH&amp;lt;/code&amp;gt; und &amp;lt;code bash&amp;gt;echo $LD_LIBRARY_PATH&amp;lt;/code&amp;gt; als normaler KDE 3 Benutzer ein, um diese Werte zu erhalten. Die obigen Funktion nimmt an, das KDE 3 im {{path|/usr}} Verzeichnis installiert ist, wie es unter Debian-Systemen der Fall ist. Falls Ihr KDE 3 in einem anderen Verzeichnis installiert ist, müssen Sie die Zeile die ''KDEDIR'' setzt entsprechend anpassen. Hier ist ein Beispiel, wie sie herausfinden unter welchem Verzeichnis KDE installiert ist; in diesem Beispiel ist es /opt/kde3:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
kde-config --prefix&lt;br /&gt;
/opt/kde3&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jetzt sollten Sie KDevelop starten können, indem Sie &amp;lt;tt&amp;gt;start3app kdevelop&amp;lt;/tt&amp;gt; eingeben. Machen sie dies jetzt.&lt;br /&gt;
&lt;br /&gt;
{{tip|&lt;br /&gt;
Sie können jede KDE 3 Anwendung mit der &amp;lt;tt&amp;gt;start3app&amp;lt;/tt&amp;gt; Funktion starten. Nützlich ist das zum Beispiele für ''Kompare'' und ''kdesvn''.&lt;br /&gt;
&lt;br /&gt;
Sie können jedoch auf diesem Weg nicht ''KDbg'' starten umd KDE 4 Anwendungen zu debuggen, da sonst die die Umgebungsvariablen für die debuggte Anwendung falsch sind.&lt;br /&gt;
}}&lt;br /&gt;
&amp;lt;!--&lt;br /&gt;
{{tip|&lt;br /&gt;
Anstatt KDevelop mit ''start3app'' als ''kde-devel'' zu starten, können Sie auch den KDE-Ausführen-Dialog ''(Alt+F2)'' dafür benutzen:&lt;br /&gt;
&lt;br /&gt;
[[Image:Minicli.png]]&lt;br /&gt;
&lt;br /&gt;
Dies startet KDevelop als ''kde-devel'' Benutzer aber verwendet die Umgebungsvariablen des normalen Benutzers, so wie es das ''start3app'' Skript tut.&lt;br /&gt;
}}&lt;br /&gt;
--&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===== TroubleShooting =====&lt;br /&gt;
&lt;br /&gt;
'''Symptom:''' kdevelop meldet &amp;quot;cannot talk to klauncher&amp;quot;. Sie können keine Datei öffnen.&lt;br /&gt;
&lt;br /&gt;
'''Lösung:''' fügen Sie Ihren KDE Bibliotheks-Pfad zum LD_LIBRARY_PATH hinzu, e.g.:&lt;br /&gt;
 export LD_LIBRARY_PATH=/opt/kde3/lib&lt;br /&gt;
&lt;br /&gt;
==== Einrichten von KDevelop ====&lt;br /&gt;
&lt;br /&gt;
Jetzt, da KDevelop gestartet ist, müssen Sie einige Einstellung vornehmen.&lt;br /&gt;
Gehen Sie dafür nach ''Einstellungen-&amp;gt;KDevelop einrichten...-&amp;gt;Dokumentation''. Entfernen Sie alle Einträge die für KDE 4 nicht relevant sind.&lt;br /&gt;
&lt;br /&gt;
{{note (de)| Obwohl Umgebungsvariablen wie $HOME in diesem Abschnitt verwendet werden, sollten Sie diese mit echten Pfaden ersetzen, da KDevelop keine Umgebungsvariablen auflöst.}&lt;br /&gt;
&lt;br /&gt;
Optional können Sie die kdelibs API Dokumentation hinzufügen. Sie müssen sie [[Getting_Started/Build/KDE4_(de)#Generating_local_API_documentation|zuvor erstellen]]. Dann fügen sie die Dokumentation durch Klick auf ''Hinzufügen...'' hinzu. In diesem Dialog verwenden Sie folgende Einstellungen:&lt;br /&gt;
* ''Typ'': Doxygen Documentation Collection (muss zuerst eingestellt werden)&lt;br /&gt;
* ''Ort'': {{path|$KDE_SRC/KDE/kdelibs/kdelibs-apidocs/index.html}}&lt;br /&gt;
&lt;br /&gt;
Fügen Sie nun die Qt API Dokumentation hinzu, indem Sie folgende Einstellungen verwenden:&lt;br /&gt;
* ''Typ'': Qt Documentation Collection (muss zuerst eingestellt werden)&lt;br /&gt;
* ''Ort'': {{path|$HOME/qt-copy/doc/html/qt.dcf}}&lt;br /&gt;
&lt;br /&gt;
Nachdem Sie die Dokumentation für kdelibs und die Qt API hinzugefügt haben, stellen sie sicher das alle Checkboxen (''TOC'',''Index'' und ''Suche'') aktiviert sind. Dann gehen Sie auf den Tab ''Volltextsuche'' und stellen sicherm das die Pfade zu den Programmen ''htdig'', ''htmerge'' und ''htsearch'' korrekt sind. Sie können den Einstellungs-Dialog nun schliessen.&lt;br /&gt;
&lt;br /&gt;
Jetzt ist es an der Zeit das Projekt an dem Sie arbeiten möchten zu öffen indem sie auf ''Projekt-&amp;gt;Projekt öffnen'' klicken. Die Projektdateien befinden sich im build-Verzeichnis. Für Konsole müssen Sie zum Beispiel die Datei {{path|$KDE_BUILD/KDE/kdebase/apps/konsole/konsole.kdevelop}} öffnen. Sie müssen nun einige Projektspezifische Einstellungen unter ''Projekt-&amp;gt;Projekt Optionen'' vornehmen. Sie müssen das für jedes Projekt machen, an dem Sie arbeiten möchten.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|&lt;br /&gt;
Manchmal ist keine KDevelop Projektdatei für das Verzeichnis in dem Sie arbeiten möchten verfügbar.&lt;br /&gt;
&lt;br /&gt;
Dies kann verschieden Gründe haben, es hängt davon ab wie die CMake-Dateien geschrieben wurden. Für gewöhnlich sollten CMake-Dateien, die eine &amp;lt;tt&amp;gt;project(projectname)&amp;lt;/tt&amp;gt; Anweisung enthalten gut funktionieren. Wenn Sie mit CMake vertraut genug sind, können Sie versuchen, diese Anweisung hinzuzufügen.&lt;br /&gt;
&lt;br /&gt;
Ein Workaround dafür ist es, einfach die KDevelop Projektdatei eines darüberliegenden Ordners zu verwenden. In diesem Fall müssen Sie den &amp;lt;tt&amp;gt;Make Active Directory&amp;lt;/tt&amp;gt; Eintrag im Kontextmenu des &amp;lt;tt&amp;gt;File Selectors&amp;lt;/tt&amp;gt; in der Sidebar benutzen. Damit können Sie die anderen, unerwünschten Verzeichnisse beim erstellen und installieren ignorieren.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
* ''C++ Unterstützung-&amp;gt;Codevervollständigung''&lt;br /&gt;
:Hier müssen Sie die Vervollständigungs-Datenbanken für Qt und kdelibs hinzufügen und natürlich noch mehr wenn Sie mögen. Zum Beispiel könnten Sie eine Datenbank für ''kdepimlibs'' benötigen wenn sie an ''kdepim'' arbeiten.&lt;br /&gt;
&lt;br /&gt;
:Für kdelibs klicken Sie den ''Hinzufügen...'' Button und wählen ''KDevelop Custom Directory PCS Importer'', dann fügen Sie Ihr KDE include Verzeichnis ({{path|$HOME/kde/include}}) zur Liste hinzu und fahren fort. Sie können den Dateiauswahldialog und den ''Hinzufügen...'' Button benutzen um es hinzuzufügen. &lt;br /&gt;
&lt;br /&gt;
:Jetzt fügen Sie die Datenbank für Qt 4 hinzu indem Sie ''KDevelop Qt4 PCS Importer'' auswählen. Sie müssen das Qt 4 include-Verzeichnis welches Sie unter {{path|$HOME/qt-copy/include}} finden hinzufügen.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Der Qt4 PCS Importer wird nur benötigt wenn Qt4 nicht installiert wurde, sie es also zum Beispiel direkt aus dem build-Verzeichnis heraus nutzen. Der Nachteil ber der Benutzung des Qt4 Importers ist das er während des Imports keinen Fortschritt anzeigt und die Applikation zu hängen scheint. Die Alternative ist es den Custom Directory PCS Importer dafür zu benutzen}}&lt;br /&gt;
&lt;br /&gt;
* ''C++ Unterstützung-&amp;gt;Qt Optionen''&lt;br /&gt;
:Aktivieren Sie ''Qt Options aktivieren'' und wählen Sie Qt4 als Ihre Version. Setzen Sie den ''QMake Binary'' Pfad auf {{path|$HOME/qt-copy/bin/qmake}}. Dann wählen Sie ''Qt 4 style'' als ''Qt include syntax''. Benutzen Sie {{path|$HOME/qt-copy/bin/designer}} für ''Designer Binary''. Benutzen Sie den ''Pluginpfade ändern'' Dialog um das Plugin-Verzeichnis von KDE hinzufügen und so die KDE widgets im Designer zu sehen. Um das zu erreichen fügen Sie {{path|$HOME/kde/lib/kde4/plugins}} in das Textfeld ein und klicken den ''Hinzufügen''-Button.&lt;br /&gt;
&lt;br /&gt;
* ''Ausführungs Optionen''&lt;br /&gt;
:Stellen Sie sicher das für ''Executable'' der korrekte Wert eingestellt ist. Wenn Sie zum Beispiel Konsole ausführen wollen, geben Sie {{path|$KDE_BUILD/KDE/kdebase/apps/konsole/src/konsole}} an. Sie sollten  ''--nofork'' zu den ''Debug Parametern'' hinzufügen oder das Debuggen von einigen Anwendungen wie ''KMail'' wird fehlschlagen.&lt;br /&gt;
&lt;br /&gt;
:Da die ''start3app'' Funktion einige Umgebungsvariablen anpasst, müssen Sie diese hier zurücksetzen damit KDE 4 Anwendungen problemlos aus KDevelop heraus ausgeführt werden können.&lt;br /&gt;
:Für einige Anwendungen, wie Konsole, ist dies nicht unbedingt nötig aber andere wie KMail werden abstürzen wenn Sie die Variablen nicht anpassen.&lt;br /&gt;
:Klicken  Sie einfach auf den ''Hinzufügen / Kopieren'' Button um neue Umgebungsvariablen hinzuzufügen. Sie werden die folgenden brauchen, die die selben wie in Ihrer  [[Getting_Started/Increased_Productivity_in_KDE4_with_Scripts/.bashrc|{{path|.bashrc}}]] sind:&lt;br /&gt;
&lt;br /&gt;
:{| border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! Name&lt;br /&gt;
! Value&lt;br /&gt;
|-&lt;br /&gt;
| KDEHOME&lt;br /&gt;
| $HOME/.kde4&lt;br /&gt;
|-&lt;br /&gt;
| PATH&lt;br /&gt;
| $KDEDIR/bin:$QTDIR/bin:/usr/local/bin:$PATH&lt;br /&gt;
|-&lt;br /&gt;
| LD_LIBRARY_PATH&lt;br /&gt;
| $KDEDIR/lib:$QTDIR/lib:$LD_LIBRARY_PATH&lt;br /&gt;
|-&lt;br /&gt;
| KDETMP&lt;br /&gt;
| /tmp/$USER-kde4&lt;br /&gt;
|-&lt;br /&gt;
| KDEVARTMP&lt;br /&gt;
| /var/tmp/$USER-kde4&lt;br /&gt;
|-&lt;br /&gt;
| KDEDIR&lt;br /&gt;
| $HOME/kde&lt;br /&gt;
|-&lt;br /&gt;
| KDEDIRS&lt;br /&gt;
| $KDEDIR&lt;br /&gt;
|-&lt;br /&gt;
| LD_BIND_NOW&lt;br /&gt;
| 42&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
* ''Erstellungs Optionen-&amp;gt;Erstellung''&lt;br /&gt;
:Stellen Sie sicher das hier das korrekte build-Verzeichnis eingetragen ist. Für Konsole ist es wiederum dieses: {{path|$KDE_BUILD/KDE/kdebase/apps/konsole}}.&lt;br /&gt;
&lt;br /&gt;
* ''Erstellungs Optionen-&amp;gt;Make''&lt;br /&gt;
:Sie sollten ''Abruch bei erstem Fehler'' aktivieren. Ausserdem sollten Sie ''VERBOSE='' oder ''VERBOSE=1'' zu ''Weitere Make Optionen'' hinzufügen um Aussagekraft des Erstellungsprozesses zu steuern.&lt;br /&gt;
&lt;br /&gt;
:Wenn Sie mehr als einen Prozessor haben oder Sie Zugriff auf einen icecream cluster besitzen, sollten Sie die Option ''Mehrere Jobs ausführen'' aktivieren u nd die ''Anzahl der gleichzeitigen Prozesse'' auf die Anzahl der verfügbaren Prozessoren einstellen. Dies erhöht die Kompilierungsgeschwindigkeit. Es ist dsa gleiche wie die &amp;lt;tt&amp;gt;-j&amp;lt;/tt&amp;gt; Option für ''Make''.&lt;br /&gt;
&lt;br /&gt;
* ''Formatierung''&lt;br /&gt;
:Sie sollten alle Optionen hier so setzen, das sie zu dem Coding-Stil des Projekts an dem Sie arbeiten passen.&lt;br /&gt;
&lt;br /&gt;
* ''CTags-&amp;gt;Allgemein''&lt;br /&gt;
:Sie müssen den ''Pfad zur CTag Binary'' korrekt setzen, die sich in Debian unter {{path|/usr/bin/ctags}} befindet. &lt;br /&gt;
&lt;br /&gt;
:Am besten aktivieren Sie noch die Option &amp;lt;tt&amp;gt;Bei mehr als einem Treffer, direkt zum Ersten gehen&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Jetzt sind Sie damit fertig Ihre Projekt-spezifischen Einstellungen zu konfigurieren. Sie sollten nun unter ''Einstellungen-&amp;gt;Plugins konfigurieren...'' einige Plugins entfernen, die Sie nicht benötigen. Ich deaktiviere beispielsweise folgende Plugins:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;small&amp;gt;Abbreviation Expansion, Code Snippets, Doxygen Support, Embedded Konsole, File Tree, '''Final Packaging Support''', &amp;quot;Open with&amp;quot; Menu Addon, QuickOpen, Regular Expression Tester, Scripting, '''Security Checker''', Shell Filtering and Insertion, Text Structure and Tools Menu Addition.&amp;lt;/small&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Sie sollten zumindest die Fettgedruckten entfernen.&lt;br /&gt;
&lt;br /&gt;
Jetzt öffnen Sie, falls noch nicht geschehen, irgendeine Quelldatei. Dies aktiviert den Menueintrag ''Einstellungen-&amp;gt;Editor konfigurieren...'', wo Sie die Tabulatoroptionen so einstellen müssen wie Sie im Projekt an dem Sie arbeiten benutzt werden. Die wichtigsten Einstellungen sind:&lt;br /&gt;
* ''Erscheinungsbild-&amp;gt;Rahmen-&amp;gt;Zeilennummern anzeigen'': Sollte aktiviert sein.&lt;br /&gt;
* ''Erscheinungsbild-&amp;gt;Rahmen-&amp;gt;Symbolränder anzeigen'': Sollte aktiviert sein.&lt;br /&gt;
* ''Bearbeiten-&amp;gt;Tabulatoren'' &lt;br /&gt;
* ''Bearbeiten-&amp;gt;Statischer Zeilenumbruch-&amp;gt;Markierung anzeigen'': Sollte aktiviert sein&lt;br /&gt;
* ''Einrückung-&amp;gt;Automatische Einrückung-&amp;gt;Einrückungs-Modus'': Sollte ''C Style'' sein&lt;br /&gt;
* ''Einrückung'' insgesamt&lt;br /&gt;
&lt;br /&gt;
Im Hauptfenster klicken Sie auf den Tab ''CTags'' in der unteren Tableiset, dann klicken Sie auf ''Neu erstellen'' um eine CTags-Datenbank zur einfacheren Navigation im Quellcode zu erstellen.&lt;br /&gt;
&lt;br /&gt;
Jetzt haben Sie alle wesentlichen Einstellunge vorgenommen, Gratulation!&lt;br /&gt;
&lt;br /&gt;
==== KDevelop benutzen ====&lt;br /&gt;
&lt;br /&gt;
Wenden Sie sich an das [http://docs.kde.org/development/en/kdevelop/kdevelop/ KDevelop Handbuch (englisch)] um generell Hilfe zu Ihrer Arbeit mit KDevelop zu erhalten. Der folgende Abschnitt wird nur Spezialfälle im Bezug auf KDE 4 enthalten.&lt;br /&gt;
&lt;br /&gt;
===== Debugging =====&lt;br /&gt;
&lt;br /&gt;
KDE Anwendungen haben viele Symbole, was bedeutet, dass sie viel Speicher benötigen um eine angemessene Ladezeit beim Debuggen zu erreichen. Um einen GDB Entwickler zu zitieren: &amp;quot;Ich würde mich weigern KDE auf etwas mit unter 1 GB RAM zu debuggen.&amp;quot;&lt;br /&gt;
Wenn die Schrittfunktion des Debuggers zu langsam für Sie ist, versuchen Sie folgende Tips:&lt;br /&gt;
* Lokale Variablen verstecken. Der &amp;lt;tt&amp;gt;Lokal&amp;lt;/tt&amp;gt; Teil im linken Variablen Tab   verursacht einen erheblichen Geschwindigkeitsrückgang bei der Schrittweisen Ausführung wenn Sie viele lokale Variablen haben. Klappen sie einfach den &amp;lt;tt&amp;gt;Lokal&amp;lt;/tt&amp;gt; Teil des Baums zu, die lokalen Variablen werden nun nicht bei jedem Schritt aktualisiert. Sie können immernoch die Variablen untersuchen indem sie die &amp;lt;tt&amp;gt;Ausdruck evaluieren&amp;lt;/tt&amp;gt; Funktion benutzen.&lt;br /&gt;
* Benutzen Sie den Patch unter http://bugs.kde.org/show_bug.cgi?id=143977. Es verhindert die Aktualisierung des Framestack-Widgets bei jedem Schritt und beschleunigt damit die Schrittweise Ausführung erheblich. Der Patch führt zu einigen kleineren Ungereimtheiten weshalb er bisher noch nicht commited wurde.&lt;br /&gt;
&lt;br /&gt;
{{Note (de)|&lt;br /&gt;
KDevelop unterstützt bisher keine Änderungen am CMake build System. Das bedeutet, das Sie KDevelop nicht dazu benutzen können, Dateien zum Projekt hinzuzufügen oder zu entfernen oder irgend einen anderen Aspekt des Buildprozesses Ihres Projekts zu modifizieren.&lt;br /&gt;
&lt;br /&gt;
Sie müssen stattdessen die CMake Dateien per Hand anpassen und dann erneut &amp;lt;tt&amp;gt;cmakekde&amp;lt;/tt&amp;gt; ausführen.  Lesen Sie das [[Development/Tutorials/CMake (de)|CMake Tutorial]] um zu lernen wie man das macht.&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
{{tip|Wenn Sie an Bibliotheken arbeiten, müssen Sie diese zuerst installieren bevor Sie Ihre Änderungen an diesen testen oder debuggen können.&lt;br /&gt;
Da this lästig und zeitverschlingend ist, sollten Sie für alle betreffenden Bibliotheken Symlinks erstellen ''(ln -s)'', die aus dem Build-Verzeichnis auf das Installations-Verzeichnis verweisen. &lt;br /&gt;
&lt;br /&gt;
Oft benutzen selbst einfache Programme interne Bibliotheken, zum Beispiel ist der Einstellungsdialog von Konsole in Wirklichkeit eine Bibliothek,}}&lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems_(de)</id>
		<title>Development/Tutorials/Localization/i18n Build Systems (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems_(de)"/>
				<updated>2007-12-26T17:34:29Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Some small translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n Build Systems}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalization|&lt;br /&gt;
&lt;br /&gt;
name=Das l10n Modul von KDE erzeugen|&lt;br /&gt;
&lt;br /&gt;
pre=[[../i18n (de)|Beim Schreiben von Applikationen an die Lokalisation denken]]|&lt;br /&gt;
next=[[../Language Change (de)|Sprachänderungen behandeln]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
Da Ihre Applikationen in den vorigen Schritten vorbereitet wurde, lokalisiert zu werden, sehen wir uns jetzt an, wie man die notwendigen Schritte in das CMake Build-System Ihrer Applikation integriert. &lt;br /&gt;
&lt;br /&gt;
First we'll explain the &amp;quot;theory&amp;quot; of the steps that need to happen from extracting message strings to installing the generated .po files. After that we'll look at how to implement those steps ([[#Theory: The xgettext toolchain]]). If your application is developed in KDE's subversion repository, many of those steps will happen automatically (see [[#handling i18n in KDE's subversion repository]]). Else you will want to read on in the [[#handling i18n in third party applications]] section.&lt;br /&gt;
&lt;br /&gt;
== Theorie: Die xgettext toolchain ==&lt;br /&gt;
&lt;br /&gt;
Making translations work consists of the following steps:&lt;br /&gt;
# Extract the translatable strings&lt;br /&gt;
# Merge the new or changed strings with existing translations&lt;br /&gt;
# Compile the translations into message catalogs&lt;br /&gt;
# Install the message catalogs&lt;br /&gt;
# Use the message catalogs in the application&lt;br /&gt;
&lt;br /&gt;
=== Die Zeichenkette extrahieren ===&lt;br /&gt;
&lt;br /&gt;
In this step, all the strings you marked as i18n()/ki18n()/etc. in your sources need to be collected into a translation template (.pot) file. Some translateable strings are also contained in .ui, .rc, or .kcfg files. Also tips-of-the-day need to be collected into the .pot file.&lt;br /&gt;
&lt;br /&gt;
These steps are handled by {{path|xgettext}}, {{path|extractrc}}, and {{path|preparetips}} programs, respectively. In some cases you may also need {{path|extractattr}}.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen mischen ===&lt;br /&gt;
&lt;br /&gt;
Generally, only a few translatable string will change at a time, in an application. Some will be removed, some will be added, some will be changed into different strings, and some will be moved around in the source files. These changes need to be reflected in the translations, but of course it would be a huge effort to redo the entire translation every time a string was changed. Rather the changes should be merged with the existing translations. This is the job of the {{path|msgmerge}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen kompilieren ===&lt;br /&gt;
&lt;br /&gt;
In order to make message lookup fast, the .po files need to be compiled into so-called &amp;quot;message catalogs&amp;quot; (.mo / .gmo). This is done using the {{path|msgfmt}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Die Kataloge für Zeichenkette installieren ===&lt;br /&gt;
&lt;br /&gt;
The compiled message catalogs need to be installed alongside the application. In KDE, the standard location for message catalogs is {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}.&lt;br /&gt;
&lt;br /&gt;
=== Die Kataloge für Zeichenketten benutzen ===&lt;br /&gt;
&lt;br /&gt;
Finally, when the application is run, it needs to load the appropriate message catalog in order to be able to look up and show translated strings. In KDE applications, this is the job of the {{class|KLocale}} class, and in the great majority of cases happens automatically.&lt;br /&gt;
&lt;br /&gt;
For some special cases, such as plugins, look at [[#Runtime Loading Of Catalogs]].&lt;br /&gt;
&lt;br /&gt;
== i18n in KDE's subversion Repository behandeln ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed inside KDE's subversion repository, most of the steps outlined above are automated. In this case, generally, all you will need to do is provide a simple script called {{path|Messages.sh}}, which we will look at below.&lt;br /&gt;
&lt;br /&gt;
In addition, if your top-level folder and .pot file have the same name, the svn2dist script will automatically include .po files when you use it to make a source tarball for your app. &lt;br /&gt;
&lt;br /&gt;
Of course, for the curious, a more detailed account of what happens behind the scences is also provided.&lt;br /&gt;
&lt;br /&gt;
=== Ein Messages.sh Skript schreiben ===&lt;br /&gt;
&lt;br /&gt;
Basically, the only thing that is necessary to prepare and install translations for applications in KDE's subversion repository, is to provide information, which sources, ui-files or tips need to be translated. For this purpose, you write a small script called {{path|Messages.sh}} and place it in your sources. Here is an example with inline comments:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!bin/sh&lt;br /&gt;
&lt;br /&gt;
# invoke the extractrc script on all .ui, .rc, and .kcfg files in the sources&lt;br /&gt;
# the results are stored in a pseudo .cpp file to be picked up by xgettext.&lt;br /&gt;
$EXTRACTRC `find . -name \*.rc -o -name \*.ui -o -name \*.kcfg` &amp;gt;&amp;gt; rc.cpp&lt;br /&gt;
# if your application contains tips-of-the-day, call preparetips as well.&lt;br /&gt;
$PREPARETIPS &amp;gt; tips.cpp&lt;br /&gt;
# call xgettext on all source files. If your sources have other filename&lt;br /&gt;
# extensions besides .cc, .cpp, and .h, just add them in the find call.&lt;br /&gt;
$XGETTEXT `find . -name \*.cc -o -name \*.cpp -o -name \*.h` -o $podir/APPNAME.pot&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, this script contains only three actual lines of code, and not all may even be needed. The $XGETTEXT, $PREPARETIPS, $EXTRACTRC, and $podir environment variables are predefined, you do not need to worry about setting these. The only thing that you will need to do is to replace &amp;quot;APPNAME&amp;quot; with the name of your application (but see [[#Naming .pot Files]] for exceptions).&lt;br /&gt;
&lt;br /&gt;
Try to make sure your Messages.sh script collects only those messages that are really needed. If in doubt, look at other Messages.sh files in the KDE subversion repository for inspiration, or - of course - ask.&lt;br /&gt;
&lt;br /&gt;
=== Was geschieht hinter der Bühne ===&lt;br /&gt;
&lt;br /&gt;
{{tip (de)|If your application is in the KDE code repository, all this happens automatically. If your code is not in the KDE repository, you must perform these steps yourself. See [[#handling i18n in third party applications]].}}&lt;br /&gt;
&lt;br /&gt;
Periodically, the script {{path|extract-messages.sh}} (a.k.a. scripty) runs on the KDE server. This program basically calls all Messages.sh scripts in the repository with the appropriate parameters. The extracted messages are stored in template (.pot) files in the templates folder of the l10n module. See [[What Is Scripty]] for more information. &lt;br /&gt;
&lt;br /&gt;
The KDE translation teams translate the messages and commit them into a messages folder corresponding to the language, which is further broken down by module. For example, German translated messages for konqueror are committed to {{path|l10n/de/messages/kdebase/konqueror.po}}. &lt;br /&gt;
&lt;br /&gt;
When the l10n module is built, the .po files are compiled into a binary format for fast lookup and installed as .mo files to {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}, where xx is the two-letter ISO 639 code for the language. These are called the message catalogs. &lt;br /&gt;
&lt;br /&gt;
At runtime, the &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; function, using the original string you coded, looks up the string in the message catalog of the user's desktop language and returns the translated string. If the message catalog is missing, or the specific string is not found, &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; falls back to the original string in your code. &lt;br /&gt;
&lt;br /&gt;
.desktop files in your project are handled separately. {{path|makemessages}} extracts strings, such as Name and Comment from the .desktop files and places them into a file named {{path|desktop_mmmm.pot}}, where mmmm is the module name, in the templates folder. Once translators have translated this file, makemessages inserts the translated strings back into the .desktop files. The list of strings extracted is in {{path|l10n/scripts/apply.cc}}. Here's the code that checks for them:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;if (checkTag(&amp;quot;Name&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Comment&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Language&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Keywords&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;About&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Description&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;GenericName&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Query&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;ExtraNames&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== i18n in Applikationen von dritten behandeln ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed outside of KDE's subversion repository, you need to take care of generating and installing message catalogs yourself. This is not too hard to do, but you should make sure you have a basic understanding of all steps involved, so you will probably want to read [[#Theory: The xgettext toolchain]], first.&lt;br /&gt;
&lt;br /&gt;
Also, there is more than one way to deal with i18n in your application. We will outline one approach to do so for simple applications, but you may want to diverge from this, if you like to.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|The following improvements are needed in this section (or is this obsolete?):&lt;br /&gt;
How can messages for .desktop files be extracted? &lt;br /&gt;
How can translated .desktop messages be inserted back into .desktop files?}}&lt;br /&gt;
&lt;br /&gt;
=== Allgemeine Überlegungen ===&lt;br /&gt;
&lt;br /&gt;
The i18n generation process can roughly be divided into two steps:&lt;br /&gt;
&lt;br /&gt;
# Extracting and merging messages&lt;br /&gt;
# Compiling and installing message catalogs&lt;br /&gt;
&lt;br /&gt;
The first step really concerns the ''sources'', while the second step is a natural part of compiling and installing an application. Hence, while the second step should definitely be incorporated into the build system for your application (we assume CMake, here), there is no striking reason for the first step to be handled by the build system.&lt;br /&gt;
&lt;br /&gt;
In fact, the extraction and merging of messages does not map well onto the CMake concept of out-of-source builds, and CMake can't provide too much help for this step, either.&lt;br /&gt;
&lt;br /&gt;
Hence, in this tutorial, we will handle the first step with a standalone shell script, and only the second step will be handled by CMake.&lt;br /&gt;
&lt;br /&gt;
=== Extrahieren und Mischen von Zeichenketten ===&lt;br /&gt;
&lt;br /&gt;
If you have read the section [[#handling i18n in KDE's subversion repository]] you will know that in the KDE repository, message extraction and merging is handled by a simple script called Messages.sh, which is invoked by a script called {{path|extract-messages.sh}}. Outside of KDE's repository, you will need to take care of both parts, but fortunately, this is easy enough. Here's a sample script:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
BASEDIR=&amp;quot;../rkward/&amp;quot;	# root of translatable sources&lt;br /&gt;
PROJECT=&amp;quot;rkward&amp;quot;	# project name&lt;br /&gt;
BUGADDR=&amp;quot;http://sourceforge.net/tracker/?group_id=50231&amp;amp;atid=459007&amp;quot;	# MSGID-Bugs&lt;br /&gt;
WDIR=`pwd`		# working dir&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Preparing rc files&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# we use simple sorting to make sure the lines do not jump around too much from system to system&lt;br /&gt;
find . -name '*.rc' -o -name '*.ui' -o -name '*.kcfg' | sort &amp;gt; ${WDIR}/rcfiles.list&lt;br /&gt;
xargs --arg-file=${WDIR}/rcfiles.list extractrc &amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
# additional string for KAboutData&lt;br /&gt;
echo 'i18nc(&amp;quot;NAME OF TRANSLATORS&amp;quot;,&amp;quot;Your names&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
echo 'i18nc(&amp;quot;EMAIL OF TRANSLATORS&amp;quot;,&amp;quot;Your emails&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
echo &amp;quot;Done preparing rc files&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Extracting messages&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# see above on sorting&lt;br /&gt;
find . -name '*.cpp' -o -name '*.h' -o -name '*.c' | sort &amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
echo &amp;quot;rc.cpp&amp;quot; &amp;gt;&amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
xgettext --from-code=UTF-8 -C -kde -ci18n -ki18n:1 -ki18nc:1c,2 -ki18np:1,2 -ki18ncp:1c,2,3 -ktr2i18n:1 \&lt;br /&gt;
	-kI18N_NOOP:1 -kI18N_NOOP2:1c,2 -kaliasLocale -kki18n:1 -kki18nc:1c,2 -kki18np:1,2 -kki18ncp:1c,2,3 \&lt;br /&gt;
	--msgid-bugs-address=&amp;quot;${BUGADDR}&amp;quot; \&lt;br /&gt;
	--files-from=infiles.list -D ${BASEDIR} -D ${WDIR} -o ${PROJECT}.pot || { echo &amp;quot;error while calling xgettext. aborting.&amp;quot;; exit 1; }&lt;br /&gt;
echo &amp;quot;Done extracting messages&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Merging translations&amp;quot;&lt;br /&gt;
catalogs=`find . -name '*.po'`&lt;br /&gt;
for cat in $catalogs; do&lt;br /&gt;
  echo $cat&lt;br /&gt;
  msgmerge -o $cat.new $cat ${PROJECT}.pot&lt;br /&gt;
  mv $cat.new $cat&lt;br /&gt;
done&lt;br /&gt;
echo &amp;quot;Done merging translations&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Cleaning up&amp;quot;&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
rm rcfiles.list&lt;br /&gt;
rm infiles.list&lt;br /&gt;
rm rc.cpp&lt;br /&gt;
echo &amp;quot;Done&amp;quot;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course you will want to adjust the variable definitions at the top, and - if needed - add code to extract tips-of-the-day or other additional strings.&lt;br /&gt;
&lt;br /&gt;
The example script assumes that all .po files and the .pot file are kept in a single directory, which is appropriate for most projects.&lt;br /&gt;
&lt;br /&gt;
=== Kompilieren und Installieren von Zeichenkettenkatalogen ===&lt;br /&gt;
&lt;br /&gt;
Assuming you use the script from the previous section, you can place the following CMakeLists.txt in the directory containing the .po files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
FIND_PROGRAM(GETTEXT_MSGFMT_EXECUTABLE msgfmt)&lt;br /&gt;
&lt;br /&gt;
IF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
	MESSAGE(&lt;br /&gt;
&amp;quot;------&lt;br /&gt;
                 NOTE: msgfmt not found. Translations will *not* be installed&lt;br /&gt;
------&amp;quot;)&lt;br /&gt;
ELSE(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&lt;br /&gt;
        SET(catalogname rkward)&lt;br /&gt;
&lt;br /&gt;
	ADD_CUSTOM_TARGET(translations ALL)&lt;br /&gt;
	&lt;br /&gt;
	FILE(GLOB PO_FILES *.po)&lt;br /&gt;
	&lt;br /&gt;
	FOREACH(_poFile ${PO_FILES})&lt;br /&gt;
		GET_FILENAME_COMPONENT(_lang ${_poFile} NAME_WE)&lt;br /&gt;
		SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_lang}.gmo)&lt;br /&gt;
		ADD_CUSTOM_COMMAND(TARGET translations&lt;br /&gt;
			COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} --check -o ${_gmoFile} ${_poFile}&lt;br /&gt;
			DEPENDS ${_poFile})&lt;br /&gt;
		INSTALL(FILES ${_gmoFile} DESTINATION ${LOCALE_INSTALL_DIR}/${_lang}/LC_MESSAGES/ RENAME ${catalogname}.mo)&lt;br /&gt;
	ENDFOREACH(_poFile ${PO_FILES})&lt;br /&gt;
&lt;br /&gt;
ENDIF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This iterates over all .po files in the directory, compiles them using msgfmt, and installs them to the standard location. You will want to change &amp;quot;catalogname&amp;quot; to the name of your application.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen erhalten ===&lt;br /&gt;
&lt;br /&gt;
Now you just have to find translators to translate the extracted messages into the various languages. As your application gets used by more people, you will find that translators will volunteer to do this. Translated PO files then have to be stored in the po folder with the naming scheme &amp;lt;languagecode&amp;gt;.po.&lt;br /&gt;
&lt;br /&gt;
== Sonderfälle (plugins, mehrere catalogs, etc.) ==&lt;br /&gt;
&lt;br /&gt;
=== Kataloge zur Laufzeit laden ===&lt;br /&gt;
&lt;br /&gt;
To have translations show up properly in an application, the name of the .pot file must match the name of the message catalog (.mo) file that your application will read at runtime. But what name will be used at runtime?&lt;br /&gt;
&lt;br /&gt;
In general, it will be the value returned by &amp;lt;tt&amp;gt;{{class|KGlobal}}::instance()-&amp;gt;instanceName()&amp;lt;/tt&amp;gt;. But what will that be? The general rules for standalone applications are:&lt;br /&gt;
* the message catalog will default to the name of the application passed as the first argument to {{class|KAboutData}}&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::setMainCatalog()&amp;lt;/tt&amp;gt;, that name will be used instead&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;, the specified catalog will also be searched in addition to the main catalog&lt;br /&gt;
&lt;br /&gt;
If your code does not call either of the {{class|KLocale}} methods mentioned above and your application is a plugin, it gets a little more complicated. If your code exports your plugin using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;K_EXPORT_COMPONENT_FACTORY( libkhtmlkttsdplugin,&lt;br /&gt;
  KGenericFactory&amp;lt;KHTMLPluginKTTSD&amp;gt;(&amp;quot;khtmlkttsd&amp;quot;) )&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
then the catalog name will be the name passed in the {{class|KGenericFactory}} constructor - in the example above that woudl be &amp;lt;tt&amp;gt;khtmlkttsd&amp;lt;/tt&amp;gt;. This is because the macro creates a {{class|Kinstance}} for you with the specified name.&lt;br /&gt;
&lt;br /&gt;
However, some classes, such as &amp;lt;tt&amp;gt;KTextEditor&amp;lt;/tt&amp;gt; create a &amp;lt;tt&amp;gt;KPart&amp;lt;/tt&amp;gt; containing your component and the name passed in the macro is not used. In this case, you should call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; in the component's constructor.&lt;br /&gt;
&lt;br /&gt;
If in doubt, the safest thing to do is to call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
{{tip|If you're not using the export macro for your plugin, you probably should be. See the API documentation of KGenericFactory for more information.}}&lt;br /&gt;
&lt;br /&gt;
Calling &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; if the catalog has already been inserted does nothing. However, calling &amp;lt;tt&amp;gt;{{class|KLocale}}::removeCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; removes the catalog no matter how many times it has been inserted. Therefore, take care that you do not inadvertently remove the catalog when multiple components are sharing a single catalog. For example, the following sequence will break translations: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;// Component A loads and uses catalog xyz by calling&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// Component B loads and also uses the same catalog.&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// component B unloads and calls&lt;br /&gt;
removeCatalogue(&amp;quot;xyz&amp;quot;)&lt;br /&gt;
// Component A now doesn't translate properly.&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Notice that a sequence such as above will occur automatically if both components A and B are loaded using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro and pass the same name argument to the KGenericFactory constructor.&lt;br /&gt;
&lt;br /&gt;
=== Benennung von .pot Dateien ===&lt;br /&gt;
&lt;br /&gt;
The name that you settle on for both the .pot file and catalog should be governed by where your code resides. If it is a component of another application and resides in that application's source tree, you'll want to share the main catalog of the application. &lt;br /&gt;
&lt;br /&gt;
If is a component of another application but resides elsewhere in the code repository, you will probably have to create a separate .pot, but keep in mind that .pot filenames must be unique across all of KDE.&lt;br /&gt;
&lt;br /&gt;
If it is a component of another application, but resides in the source tree of a second application, you should share with the second application. For example, the KDE text-to-speach daemon (KTTSD) includes a plugin for embedded Kate in {{path|kdeaccessibility/kttsd}} source tree. Since the plugin is not installed unless kttsd is installed, it shares its catalog with kttsd and calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(&amp;quot;kttsd&amp;quot;)&amp;lt;/tt&amp;gt; to do this.&lt;br /&gt;
&lt;br /&gt;
== Handbücher ==&lt;br /&gt;
Hanbücher, die im docbook Format geschrieben werden, werden von Applikationen anders behandelt. Die übersetzen Handbücher werden im l10n Modul in das doc Verzeichnis unter der jeweiligen Sprache geschrieben. Zusätzlich ist das doc Verzeichnis in Module und Applikationen unterteilt. So ist zum Beispiel das deutsche Kate Handbuch in {{path|l10n/de/docs/kdebase/kate}} geschrieben. Wenn es kompiliert wurde, wird es in {{path|$KDEDIR/share/doc/HTML/de/kate/index.cache.bz2}} installiert.&lt;br /&gt;
&lt;br /&gt;
Bitte beachten Sie, dass es am jeweiligen Übersetzerteam liegt, die übersetzen Handbücher zu erzeugen, wann immer diese meinen, es wäre komplett. &lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials_(de)</id>
		<title>Development/Tutorials (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials_(de)"/>
				<updated>2007-12-21T16:45:12Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Lokalisation */ Added language change&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials}}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Bitte hilf, die englische Seite vollständig ins Deutsche zu übersetzen.}}&lt;br /&gt;
&lt;br /&gt;
== Einführung in die KDE 4 Programmierung ==&lt;br /&gt;
Sind Sie an der Entwicklung von Programmen für KDE 4 interesiert? Wenn ja sind Sie hier genau richtig. Diese Artikelserie richtet sich an alle, die noch nie mit KDE programmiert haben.&lt;br /&gt;
;[[Development/Tutorials/First program (de)|Hallo Welt!]]&lt;br /&gt;
:''Einführung in die Grundlagen der KDE Programmierung''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KXmlGuiWindow (de)|Erstellen eines Hauptfensters]]&lt;br /&gt;
:''Dieser Artikel erklärt, wie der wichtigste Teil eines grafischen Programmes erstellt wird: das Hauptfenster.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KActions (de)|Die Verwendung von KActions]]&lt;br /&gt;
:''In diesem Artikel erfahren Sie, wie Aktionen und Werkzeugleisten (Toolbars) im Menü hinzugefügt werden können.''&lt;br /&gt;
&lt;br /&gt;
== Grundlagen ==&lt;br /&gt;
;[[Development/Tutorials/KDE4 Porting Guide (de)|Ihre Applikation nach KDE 4 portieren]]&lt;br /&gt;
:''Anleitungen Qt3/KDE3 Applikationen nach Qt4/KDE4 zu portieren''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/CMake (de)|Einführung in CMake]]&lt;br /&gt;
:''Wie man CMake in KDE 4 benutzt''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Common Programming Mistakes (de)|Häufige Programmierfehler]]&lt;br /&gt;
:''Einige häufige Fehler die man während der Entwicklung von Qt und KDE Applikationen machen kann und wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using Qt Designer (de)|Den Qt Designer benutzen um Benutzerschnittstellen zu erzeugen]]&lt;br /&gt;
:''Wie man UI Dateien mit dem Designer erzeugt und wie man diese in einem KDE Programm integriert.''&lt;br /&gt;
&lt;br /&gt;
== Dienste: Applicationen and Plugins ==&lt;br /&gt;
;[[Development/Tutorials/Services/Introduction (de)|Einführung in das Dienst-Framework]]&lt;br /&gt;
:''Eine Einführung über das Dienst-Framework in KDE und was es dem Applikationsentwickler zur Verfügung stellen kann. Beschäftigt sich mit dem system configuration cache (SyCoCa), den benötigten Dateien und wie indizierte Informationen benutzt werden.&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Traders (de)|Dienste über Trader Queries finden]]&lt;br /&gt;
:''Wie man mit der Trader Query Syntax Dienste wie Plugins oder Mimetypes findet, die im SyCoCa zwischengespeichert wurden. ''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Plugins (de)|Erstellen und Laden von Plugins mit KService]]&lt;br /&gt;
:''Zeigt, wie man eigene Plugintypen definiert, installiere Plugins findet (einschließlich denen von anderen Herstellern) und wie man diese einfach und portabel läd, indem man KService benutzt.''&lt;br /&gt;
&lt;br /&gt;
== Lokalisation ==&lt;br /&gt;
;[[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]]&lt;br /&gt;
:''Eine Einführung was Unicode ist und wie KDE Applikationen damit umgehen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n (de)|Beim Schreiben der Applikation an die Lokalisation denken]]&lt;br /&gt;
:''Diese Anleitung beschäftigt sich damit, was Lokalisation ist, warum sie wichtig ist und wie man sicherstellt, dass die eigene Applikation bereit ist, lokalisiert zu werden. Jeder Applikationsentwickler sollte das lesen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Mistakes (de)|Häufige Fehler vermeiden]]&lt;br /&gt;
:''Es gibt einige häufige Fehler, die es verhindern, dass eine Applikation angemesssen übersetzt werden kann. Diese Anleitung zeigt diese Fehler auf und zeigt, wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/Language Change (de)|Mit Sprachänderungen umgehen]]&lt;br /&gt;
:''Wie man seiner Applikation beibringt beim nächsten Start oder zur Laufzeit eine andere Sprache zu benutzen.''&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/Language_Change_(de)</id>
		<title>Development/Tutorials/Localization/Language Change (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/Language_Change_(de)"/>
				<updated>2007-12-21T16:35:16Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Translated&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/Language Change}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
name=Mit Sprachänderungen umgehen|&lt;br /&gt;
pre=[[../i18n (de)|Beim Schreiben von Applikationen an die Lokalisation denken]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Eine Option zum Ändern der Sprache hinzufügen ==&lt;br /&gt;
Für eine Benutzer kann es nützlich sein, die Sprache einer bestimmter Applikation zu ändern. Es ist glücklicherweise sehr einfach, eine solche Funktionalität zum eigenen Programm hinzuzufügen&lt;br /&gt;
&lt;br /&gt;
Wenn Sie als Hauptfenster eine von KXmlGuiWindow abgeleitete Klasse benutzen, haben Sie bereits eine entsprechende programname.rc Datei bereitgestellt. &lt;br /&gt;
&lt;br /&gt;
Verändern Sie diese einfach, damit sie folgendes beinhaltet:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
&amp;lt;Menu name=&amp;quot;help&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;switch_application_language&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/Menu&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Das ist alles. Jetzt haben Sie im &amp;quot;Help&amp;quot; Menü einen Eintrag &amp;quot;Switch Application Language&amp;quot; mit dem Sie die Sprache ändern können.&lt;br /&gt;
&lt;br /&gt;
Der Benutzer muß jedoch die Applikation neu starten, damit der Sprachwechsel wirksam wird. &lt;br /&gt;
&lt;br /&gt;
== Die GUI dynamisch ändern  ==&lt;br /&gt;
&lt;br /&gt;
Einen Schritt weiter geht die Option, die Sprache zur Laufzeit zu ändern, sobald der Benutzer dieses wünscht. &lt;br /&gt;
&lt;br /&gt;
Das scheint ein sehr mühsames Unternehmen zu sein, da ein typisches Programm mehrere hundert übersetzbare Zeichenketten beinhalten kann, die neu übersetzt werden müssten doch glücklicherweise ist eine Menge Arbeit bereits erledigt, es muss nur noch richtig verknüpft werden.&lt;br /&gt;
&lt;br /&gt;
Wenn die Sprache einer Applikation geändert wird, wird ein LanguageChanged {{Qt|QEvent}} ausgelöst und an jedes einzelne Widget gesendet. Die Idee ist, dass das Hauptfenster auf dieses Ereignis lauscht und der GUI und allen weiteren beteiltigten Elementen mitteilt, sich neu zu übersetzen.&lt;br /&gt;
&lt;br /&gt;
Fügen Sie in ihrer von KXmlGuiWindow abgeleiteten Klasse einfach in die Header-Datei ein:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
  class MyWindow {&lt;br /&gt;
    ...&lt;br /&gt;
   protected:&lt;br /&gt;
    void changeEvent( QEvent * event );&lt;br /&gt;
    void retranslateUi();&lt;br /&gt;
    KAction *mSomeAction;&lt;br /&gt;
    KAction *mQuitAction;&lt;br /&gt;
  }&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
und in die Quelldatei:&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
MyWindow::MyWindow() : KXmlGuiWindow( 0 )&lt;br /&gt;
{&lt;br /&gt;
  //setup the GUI.  There should be no i18n calls here, but instead&lt;br /&gt;
  //these calls should be in the retranslateUi() function&lt;br /&gt;
  //Set up the actions in the GUI&lt;br /&gt;
  mSomeAction = actionCollection()-&amp;gt;addAction(&amp;quot;something&amp;quot;);&lt;br /&gt;
  mSomeAction-&amp;gt;setIcon(KIcon(&amp;quot;some-action&amp;quot;));&lt;br /&gt;
  connect(mSomeAction, SIGNAL(triggered(bool)), mWorkSpace, SLOT(newWorkSheet() ));&lt;br /&gt;
&lt;br /&gt;
  //KStandardActions need to be handled careful.&lt;br /&gt;
  mQuitAction = NULL&lt;br /&gt;
  &lt;br /&gt;
  retranslateUi();&lt;br /&gt;
  // Use the KXmlGuiWindow class to setup the GUI&lt;br /&gt;
  setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::changeEvent( QEvent * event )&lt;br /&gt;
{&lt;br /&gt;
  if (event-&amp;gt;type() == QEvent::LanguageChange) {&lt;br /&gt;
    // This will setup the menu, toolbars etc again, using the new language&lt;br /&gt;
    setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
    retranslateUi();&lt;br /&gt;
  }&lt;br /&gt;
  KXmlGuiWindow::changeEvent(event);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::retranslateUi()&lt;br /&gt;
{&lt;br /&gt;
  // Set the window title&lt;br /&gt;
  setPlainCaption( i18n( &amp;quot;My Window&amp;quot; ) );&lt;br /&gt;
  // For custom actions, just set the text again&lt;br /&gt;
  mMyAction-&amp;gt;setText(i18n( &amp;quot;&amp;amp;Do Something...&amp;quot; ));&lt;br /&gt;
  if(mQuitAction) {&lt;br /&gt;
    //If we have already set this up before, create a new dummy action&lt;br /&gt;
    // and grab what info we need from it&lt;br /&gt;
    KAction *tmpQuitAction = KStandardAction::quit( NULL, NULL, NULL );&lt;br /&gt;
    mQuitAction-&amp;gt;setText(tmpQuitAction-&amp;gt;text());&lt;br /&gt;
    mQuitAction-&amp;gt;setWhatsThis(tmpQuitAction-&amp;gt;whatsThis());&lt;br /&gt;
    mQuitAction-&amp;gt;setToolTip(tmpQuitAction-&amp;gt;toolTip());&lt;br /&gt;
    delete tmpQuitAction;&lt;br /&gt;
  } else&lt;br /&gt;
    mQuitAction = KStandardAction::quit( this, SLOT( close() ), actionCollection() );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Auch wenn dies nicht sonderlich kompliziert ist, ist das alles was getan werden muss. Stellen Sie nur sicher, dass wann immer Sie eine neue Zeichenkette hinzufügen diese auch übersetzt werden kann.&lt;br /&gt;
&lt;br /&gt;
Der Weg das in Qt zu bewerkstelligen ist, die Funktion retranslateUi() sowohl vom Konstruktor als auch vom LanguageChange Ereignis aufrufen zu lassen.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/User:DrSlowDecay</id>
		<title>User:DrSlowDecay</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/User:DrSlowDecay"/>
				<updated>2007-12-21T14:55:33Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: New page: I'm doing some translation of tutorials in german.&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;I'm doing some translation of tutorials in german.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/KDE_TechBase:Contributors</id>
		<title>KDE TechBase:Contributors</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/KDE_TechBase:Contributors"/>
				<updated>2007-12-21T14:53:56Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* German Team */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Welcome to the contributors page.&lt;br /&gt;
&lt;br /&gt;
'''This site contains a list of ''active'' contributors. It should help to build teams which maintain KDE TechBase's content. If you have questions about KDE TechBase you can ask/email the corresponding person.'''&lt;br /&gt;
&lt;br /&gt;
Please add yourself to the list where appropriate. If you are inactive, please remove yourself again.&lt;br /&gt;
&lt;br /&gt;
== Administrators ==&lt;br /&gt;
&lt;br /&gt;
This is a list of KDE TechBase administrators.&lt;br /&gt;
&lt;br /&gt;
* [[User:Danimo|Danimo]]&lt;br /&gt;
* [[User:Dhaumann|Dhaumann]], &amp;lt;dhaumann at kde dot org&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Reviewers and Article Writers ==&lt;br /&gt;
&lt;br /&gt;
If you are continuously reviewing KDE TechBase changes or writing articles add yourself to the list.&lt;br /&gt;
&lt;br /&gt;
* [[User:Dhaumann|Dhaumann]], &amp;lt;dhaumann at kde dot org&amp;gt;&lt;br /&gt;
* [[User:Milliams|Milliams]]&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Translation Teams ==&lt;br /&gt;
&lt;br /&gt;
KDE TechBase is [[Help:Wiki Translation|translated]] into many languages. If you translate pages please add yourself to the right translation team.&lt;br /&gt;
&lt;br /&gt;
=== Chinese(simplified) Team ===&lt;br /&gt;
* [[User:Liangqi|Liangqi]], cavendish.qi at gmail dot com&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== German Team ===&lt;br /&gt;
* [[User:DrSlowDecay|DrSlowDecay]], kde at metalhorde dot de&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Italian Team ===&lt;br /&gt;
* [[User:Thunder Teaser|Thunder Teaser]], totokid at gmail dot com&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== ... Team ===&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/Language_Change_(de)</id>
		<title>Development/Tutorials/Localization/Language Change (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/Language_Change_(de)"/>
				<updated>2007-12-21T14:49:03Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and first translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/Language Change}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
series=Localization|&lt;br /&gt;
name=Dealing with Language Changes|&lt;br /&gt;
pre=[[../i18n|Writing Applications With Localization in Mind]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Eine Option zum Ändern der Sprache hinzufügen ==&lt;br /&gt;
&lt;br /&gt;
It can be extremely useful for a user to be able to change the language of a specific application.  It is fortunately extremely easy to add such functionality to your program.&lt;br /&gt;
&lt;br /&gt;
If you are using the KXmlGuiWindow class for your main window, then you will already have an associated programname.rc file for it.&lt;br /&gt;
&lt;br /&gt;
Simply modify this file to contain:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
&amp;lt;Menu name=&amp;quot;help&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;switch_application_language&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/Menu&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And that is it!  You will now have a Switch Application Language option in the Help menu.&lt;br /&gt;
&lt;br /&gt;
However the user will need to restart the application for the changes to take effect.&lt;br /&gt;
&lt;br /&gt;
== Die GUI dynamisch ändern  ==&lt;br /&gt;
&lt;br /&gt;
One step better is to change the language on the fly, as soon as the user has selected a new language.&lt;br /&gt;
&lt;br /&gt;
This can seem a fairly daunting task, as a typical program can contain many hundreds of translatable strings that will need to be retranslated, but fortunately a lot of the work is already done for, and just needs to be connected together.&lt;br /&gt;
&lt;br /&gt;
When the language of an application is changed, a LanguageChanged QEvent is sent to every single widget.  The idea is that in the top level window you will listen for this event, tell the GUI to retranslate, tell the toolbars to retranslate, and then let any custom widgets clean up themselves.&lt;br /&gt;
&lt;br /&gt;
So in your class that inherits from KXmlGuiWindow, add to the header file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
  class MyWindow {&lt;br /&gt;
    ...&lt;br /&gt;
   protected:&lt;br /&gt;
    void changeEvent( QEvent * event );&lt;br /&gt;
    void retranslateUi();&lt;br /&gt;
    KAction *mSomeAction;&lt;br /&gt;
    KAction *mQuitAction;&lt;br /&gt;
  }&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and to the source file:&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
MyWindow::MyWindow() : KXmlGuiWindow( 0 )&lt;br /&gt;
{&lt;br /&gt;
  //setup the GUI.  There should be no i18n calls here, but instead&lt;br /&gt;
  //these calls should be in the retranslateUi() function&lt;br /&gt;
  //Set up the actions in the GUI&lt;br /&gt;
  mSomeAction = actionCollection()-&amp;gt;addAction(&amp;quot;something&amp;quot;);&lt;br /&gt;
  mSomeAction-&amp;gt;setIcon(KIcon(&amp;quot;some-action&amp;quot;));&lt;br /&gt;
  connect(mSomeAction, SIGNAL(triggered(bool)), mWorkSpace, SLOT(newWorkSheet() ));&lt;br /&gt;
&lt;br /&gt;
  //KStandardActions need to be handled careful.&lt;br /&gt;
  mQuitAction = NULL&lt;br /&gt;
  &lt;br /&gt;
  retranslateUi();&lt;br /&gt;
  // Use the KXmlGuiWindow class to setup the GUI&lt;br /&gt;
  setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::changeEvent( QEvent * event )&lt;br /&gt;
{&lt;br /&gt;
  if (event-&amp;gt;type() == QEvent::LanguageChange) {&lt;br /&gt;
    // This will setup the menu, toolbars etc again, using the new language&lt;br /&gt;
    setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
    retranslateUi();&lt;br /&gt;
  }&lt;br /&gt;
  KXmlGuiWindow::changeEvent(event);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::retranslateUi()&lt;br /&gt;
{&lt;br /&gt;
  // Set the window title&lt;br /&gt;
  setPlainCaption( i18n( &amp;quot;My Window&amp;quot; ) );&lt;br /&gt;
  // For custom actions, just set the text again&lt;br /&gt;
  mMyAction-&amp;gt;setText(i18n( &amp;quot;&amp;amp;Do Something...&amp;quot; ));&lt;br /&gt;
  if(mQuitAction) {&lt;br /&gt;
    //If we have already set this up before, create a new dummy action&lt;br /&gt;
    // and grab what info we need from it&lt;br /&gt;
    KAction *tmpQuitAction = KStandardAction::quit( NULL, NULL, NULL );&lt;br /&gt;
    mQuitAction-&amp;gt;setText(tmpQuitAction-&amp;gt;text());&lt;br /&gt;
    mQuitAction-&amp;gt;setWhatsThis(tmpQuitAction-&amp;gt;whatsThis());&lt;br /&gt;
    mQuitAction-&amp;gt;setToolTip(tmpQuitAction-&amp;gt;toolTip());&lt;br /&gt;
    delete tmpQuitAction;&lt;br /&gt;
  } else&lt;br /&gt;
    mQuitAction = KStandardAction::quit( this, SLOT( close() ), actionCollection() );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Although these is fairly complicated, that's about all that's needed.  Just be careful whenever you add a new string somewhere that it can be translated.&lt;br /&gt;
&lt;br /&gt;
The way it is done in Qt is to follow this pattern of having a retranslateUi() function that is called from both the constructor and from a LanguageChange event.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/Language_Change</id>
		<title>Development/Tutorials/Localization/Language Change</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/Language_Change"/>
				<updated>2007-12-21T14:47:35Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/Language Change}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
series=Localization|&lt;br /&gt;
name=Dealing with Language Changes|&lt;br /&gt;
pre=[[../i18n|Writing Applications With Localization in Mind]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Adding an option to change the language ==&lt;br /&gt;
&lt;br /&gt;
It can be extremely useful for a user to be able to change the language of a specific application.  It is fortunately extremely easy to add such functionality to your program.&lt;br /&gt;
&lt;br /&gt;
If you are using the KXmlGuiWindow class for your main window, then you will already have an associated programname.rc file for it.&lt;br /&gt;
&lt;br /&gt;
Simply modify this file to contain:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
&amp;lt;Menu name=&amp;quot;help&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;switch_application_language&amp;quot;/&amp;gt;&lt;br /&gt;
&amp;lt;/Menu&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
And that is it!  You will now have a Switch Application Language option in the Help menu.&lt;br /&gt;
&lt;br /&gt;
However the user will need to restart the application for the changes to take effect.&lt;br /&gt;
&lt;br /&gt;
== Dynamically changing the GUI ==&lt;br /&gt;
&lt;br /&gt;
One step better is to change the language on the fly, as soon as the user has selected a new language.&lt;br /&gt;
&lt;br /&gt;
This can seem a fairly daunting task, as a typical program can contain many hundreds of translatable strings that will need to be retranslated, but fortunately a lot of the work is already done for, and just needs to be connected together.&lt;br /&gt;
&lt;br /&gt;
When the language of an application is changed, a LanguageChanged QEvent is sent to every single widget.  The idea is that in the top level window you will listen for this event, tell the GUI to retranslate, tell the toolbars to retranslate, and then let any custom widgets clean up themselves.&lt;br /&gt;
&lt;br /&gt;
So in your class that inherits from KXmlGuiWindow, add to the header file:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
  class MyWindow {&lt;br /&gt;
    ...&lt;br /&gt;
   protected:&lt;br /&gt;
    void changeEvent( QEvent * event );&lt;br /&gt;
    void retranslateUi();&lt;br /&gt;
    KAction *mSomeAction;&lt;br /&gt;
    KAction *mQuitAction;&lt;br /&gt;
  }&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and to the source file:&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
MyWindow::MyWindow() : KXmlGuiWindow( 0 )&lt;br /&gt;
{&lt;br /&gt;
  //setup the GUI.  There should be no i18n calls here, but instead&lt;br /&gt;
  //these calls should be in the retranslateUi() function&lt;br /&gt;
  //Set up the actions in the GUI&lt;br /&gt;
  mSomeAction = actionCollection()-&amp;gt;addAction(&amp;quot;something&amp;quot;);&lt;br /&gt;
  mSomeAction-&amp;gt;setIcon(KIcon(&amp;quot;some-action&amp;quot;));&lt;br /&gt;
  connect(mSomeAction, SIGNAL(triggered(bool)), mWorkSpace, SLOT(newWorkSheet() ));&lt;br /&gt;
&lt;br /&gt;
  //KStandardActions need to be handled careful.&lt;br /&gt;
  mQuitAction = NULL&lt;br /&gt;
  &lt;br /&gt;
  retranslateUi();&lt;br /&gt;
  // Use the KXmlGuiWindow class to setup the GUI&lt;br /&gt;
  setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::changeEvent( QEvent * event )&lt;br /&gt;
{&lt;br /&gt;
  if (event-&amp;gt;type() == QEvent::LanguageChange) {&lt;br /&gt;
    // This will setup the menu, toolbars etc again, using the new language&lt;br /&gt;
    setupGUI(ToolBar | Keys | StatusBar | Create);&lt;br /&gt;
    retranslateUi();&lt;br /&gt;
  }&lt;br /&gt;
  KXmlGuiWindow::changeEvent(event);&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MyWindow::retranslateUi()&lt;br /&gt;
{&lt;br /&gt;
  // Set the window title&lt;br /&gt;
  setPlainCaption( i18n( &amp;quot;My Window&amp;quot; ) );&lt;br /&gt;
  // For custom actions, just set the text again&lt;br /&gt;
  mMyAction-&amp;gt;setText(i18n( &amp;quot;&amp;amp;Do Something...&amp;quot; ));&lt;br /&gt;
  if(mQuitAction) {&lt;br /&gt;
    //If we have already set this up before, create a new dummy action&lt;br /&gt;
    // and grab what info we need from it&lt;br /&gt;
    KAction *tmpQuitAction = KStandardAction::quit( NULL, NULL, NULL );&lt;br /&gt;
    mQuitAction-&amp;gt;setText(tmpQuitAction-&amp;gt;text());&lt;br /&gt;
    mQuitAction-&amp;gt;setWhatsThis(tmpQuitAction-&amp;gt;whatsThis());&lt;br /&gt;
    mQuitAction-&amp;gt;setToolTip(tmpQuitAction-&amp;gt;toolTip());&lt;br /&gt;
    delete tmpQuitAction;&lt;br /&gt;
  } else&lt;br /&gt;
    mQuitAction = KStandardAction::quit( this, SLOT( close() ), actionCollection() );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Although these is fairly complicated, that's about all that's needed.  Just be careful whenever you add a new string somewhere that it can be translated.&lt;br /&gt;
&lt;br /&gt;
The way it is done in Qt is to follow this pattern of having a retranslateUi() function that is called from both the constructor and from a LanguageChange event.&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems_(de)</id>
		<title>Development/Tutorials/Localization/i18n Build Systems (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems_(de)"/>
				<updated>2007-12-21T14:45:01Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and first translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n Build Systems}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalization|&lt;br /&gt;
&lt;br /&gt;
name=Das l10n Modul von KDE erzeugen|&lt;br /&gt;
&lt;br /&gt;
pre=[[../i18n (de)|Beim Schreiben von Applikationen an die Lokalisation denken]]|&lt;br /&gt;
next=[[../Language Change (de)|Sprachänderungen behandeln]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Now that your application is ready to be localized, we next look at how to incorporate the necessary mechanisms into the CMake build system of your application.&lt;br /&gt;
&lt;br /&gt;
First we'll explain the &amp;quot;theory&amp;quot; of the steps that need to happen from extracting message strings to installing the generated .po files. After that we'll look at how to implement those steps ([[#Theory: The xgettext toolchain]]). If your application is developed in KDE's subversion repository, many of those steps will happen automatically (see [[#handling i18n in KDE's subversion repository]]). Else you will want to read on in the [[#handling i18n in third party applications]] section.&lt;br /&gt;
&lt;br /&gt;
== Theorie: Die xgettext toolchain ==&lt;br /&gt;
&lt;br /&gt;
Making translations work consists of the following steps:&lt;br /&gt;
# Extract the translatable strings&lt;br /&gt;
# Merge the new or changed strings with existing translations&lt;br /&gt;
# Compile the translations into message catalogs&lt;br /&gt;
# Install the message catalogs&lt;br /&gt;
# Use the message catalogs in the application&lt;br /&gt;
&lt;br /&gt;
=== Die Zeichenkette extrahieren ===&lt;br /&gt;
&lt;br /&gt;
In this step, all the strings you marked as i18n()/ki18n()/etc. in your sources need to be collected into a translation template (.pot) file. Some translateable strings are also contained in .ui, .rc, or .kcfg files. Also tips-of-the-day need to be collected into the .pot file.&lt;br /&gt;
&lt;br /&gt;
These steps are handled by {{path|xgettext}}, {{path|extractrc}}, and {{path|preparetips}} programs, respectively. In some cases you may also need {{path|extractattr}}.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen mischen ===&lt;br /&gt;
&lt;br /&gt;
Generally, only a few translatable string will change at a time, in an application. Some will be removed, some will be added, some will be changed into different strings, and some will be moved around in the source files. These changes need to be reflected in the translations, but of course it would be a huge effort to redo the entire translation every time a string was changed. Rather the changes should be merged with the existing translations. This is the job of the {{path|msgmerge}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen kompilieren ===&lt;br /&gt;
&lt;br /&gt;
In order to make message lookup fast, the .po files need to be compiled into so-called &amp;quot;message catalogs&amp;quot; (.mo / .gmo). This is done using the {{path|msgfmt}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Die Kataloge für Zeichenkette installieren ===&lt;br /&gt;
&lt;br /&gt;
The compiled message catalogs need to be installed alongside the application. In KDE, the standard location for message catalogs is {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}.&lt;br /&gt;
&lt;br /&gt;
=== Die Kataloge für Zeichenketten benutzen ===&lt;br /&gt;
&lt;br /&gt;
Finally, when the application is run, it needs to load the appropriate message catalog in order to be able to look up and show translated strings. In KDE applications, this is the job of the {{class|KLocale}} class, and in the great majority of cases happens automatically.&lt;br /&gt;
&lt;br /&gt;
For some special cases, such as plugins, look at [[#Runtime Loading Of Catalogs]].&lt;br /&gt;
&lt;br /&gt;
== i18n in KDE's subversion Repository behandeln ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed inside KDE's subversion repository, most of the steps outlined above are automated. In this case, generally, all you will need to do is provide a simple script called {{path|Messages.sh}}, which we will look at below.&lt;br /&gt;
&lt;br /&gt;
In addition, if your top-level folder and .pot file have the same name, the svn2dist script will automatically include .po files when you use it to make a source tarball for your app. &lt;br /&gt;
&lt;br /&gt;
Of course, for the curious, a more detailed account of what happens behind the scences is also provided.&lt;br /&gt;
&lt;br /&gt;
=== Ein Messages.sh Skript schreiben ===&lt;br /&gt;
&lt;br /&gt;
Basically, the only thing that is necessary to prepare and install translations for applications in KDE's subversion repository, is to provide information, which sources, ui-files or tips need to be translated. For this purpose, you write a small script called {{path|Messages.sh}} and place it in your sources. Here is an example with inline comments:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!bin/sh&lt;br /&gt;
&lt;br /&gt;
# invoke the extractrc script on all .ui, .rc, and .kcfg files in the sources&lt;br /&gt;
# the results are stored in a pseudo .cpp file to be picked up by xgettext.&lt;br /&gt;
$EXTRACTRC `find . -name \*.rc -o -name \*.ui -o -name \*.kcfg` &amp;gt;&amp;gt; rc.cpp&lt;br /&gt;
# if your application contains tips-of-the-day, call preparetips as well.&lt;br /&gt;
$PREPARETIPS &amp;gt; tips.cpp&lt;br /&gt;
# call xgettext on all source files. If your sources have other filename&lt;br /&gt;
# extensions besides .cc, .cpp, and .h, just add them in the find call.&lt;br /&gt;
$XGETTEXT `find . -name \*.cc -o -name \*.cpp -o -name \*.h` -o $podir/APPNAME.pot&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, this script contains only three actual lines of code, and not all may even be needed. The $XGETTEXT, $PREPARETIPS, $EXTRACTRC, and $podir environment variables are predefined, you do not need to worry about setting these. The only thing that you will need to do is to replace &amp;quot;APPNAME&amp;quot; with the name of your application (but see [[#Naming .pot Files]] for exceptions).&lt;br /&gt;
&lt;br /&gt;
Try to make sure your Messages.sh script collects only those messages that are really needed. If in doubt, look at other Messages.sh files in the KDE subversion repository for inspiration, or - of course - ask.&lt;br /&gt;
&lt;br /&gt;
=== Was geschieht hinter der Bühne ===&lt;br /&gt;
&lt;br /&gt;
{{tip (de)|If your application is in the KDE code repository, all this happens automatically. If your code is not in the KDE repository, you must perform these steps yourself. See [[#handling i18n in third party applications]].}}&lt;br /&gt;
&lt;br /&gt;
Periodically, the script {{path|extract-messages.sh}} (a.k.a. scripty) runs on the KDE server. This program basically calls all Messages.sh scripts in the repository with the appropriate parameters. The extracted messages are stored in template (.pot) files in the templates folder of the l10n module. See [[What Is Scripty]] for more information. &lt;br /&gt;
&lt;br /&gt;
The KDE translation teams translate the messages and commit them into a messages folder corresponding to the language, which is further broken down by module. For example, German translated messages for konqueror are committed to {{path|l10n/de/messages/kdebase/konqueror.po}}. &lt;br /&gt;
&lt;br /&gt;
When the l10n module is built, the .po files are compiled into a binary format for fast lookup and installed as .mo files to {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}, where xx is the two-letter ISO 639 code for the language. These are called the message catalogs. &lt;br /&gt;
&lt;br /&gt;
At runtime, the &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; function, using the original string you coded, looks up the string in the message catalog of the user's desktop language and returns the translated string. If the message catalog is missing, or the specific string is not found, &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; falls back to the original string in your code. &lt;br /&gt;
&lt;br /&gt;
.desktop files in your project are handled separately. {{path|makemessages}} extracts strings, such as Name and Comment from the .desktop files and places them into a file named {{path|desktop_mmmm.pot}}, where mmmm is the module name, in the templates folder. Once translators have translated this file, makemessages inserts the translated strings back into the .desktop files. The list of strings extracted is in {{path|l10n/scripts/apply.cc}}. Here's the code that checks for them:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;if (checkTag(&amp;quot;Name&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Comment&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Language&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Keywords&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;About&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Description&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;GenericName&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Query&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;ExtraNames&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== i18n in Applikationen von dritten behandeln ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed outside of KDE's subversion repository, you need to take care of generating and installing message catalogs yourself. This is not too hard to do, but you should make sure you have a basic understanding of all steps involved, so you will probably want to read [[#Theory: The xgettext toolchain]], first.&lt;br /&gt;
&lt;br /&gt;
Also, there is more than one way to deal with i18n in your application. We will outline one approach to do so for simple applications, but you may want to diverge from this, if you like to.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|The following improvements are needed in this section (or is this obsolete?):&lt;br /&gt;
How can messages for .desktop files be extracted? &lt;br /&gt;
How can translated .desktop messages be inserted back into .desktop files?}}&lt;br /&gt;
&lt;br /&gt;
=== Allgemeine Überlegungen ===&lt;br /&gt;
&lt;br /&gt;
The i18n generation process can roughly be divided into two steps:&lt;br /&gt;
&lt;br /&gt;
# Extracting and merging messages&lt;br /&gt;
# Compiling and installing message catalogs&lt;br /&gt;
&lt;br /&gt;
The first step really concerns the ''sources'', while the second step is a natural part of compiling and installing an application. Hence, while the second step should definitely be incorporated into the build system for your application (we assume CMake, here), there is no striking reason for the first step to be handled by the build system.&lt;br /&gt;
&lt;br /&gt;
In fact, the extraction and merging of messages does not map well onto the CMake concept of out-of-source builds, and CMake can't provide too much help for this step, either.&lt;br /&gt;
&lt;br /&gt;
Hence, in this tutorial, we will handle the first step with a standalone shell script, and only the second step will be handled by CMake.&lt;br /&gt;
&lt;br /&gt;
=== Extrahieren und Mischen von Zeichenketten ===&lt;br /&gt;
&lt;br /&gt;
If you have read the section [[#handling i18n in KDE's subversion repository]] you will know that in the KDE repository, message extraction and merging is handled by a simple script called Messages.sh, which is invoked by a script called {{path|extract-messages.sh}}. Outside of KDE's repository, you will need to take care of both parts, but fortunately, this is easy enough. Here's a sample script:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
BASEDIR=&amp;quot;../rkward/&amp;quot;	# root of translatable sources&lt;br /&gt;
PROJECT=&amp;quot;rkward&amp;quot;	# project name&lt;br /&gt;
BUGADDR=&amp;quot;http://sourceforge.net/tracker/?group_id=50231&amp;amp;atid=459007&amp;quot;	# MSGID-Bugs&lt;br /&gt;
WDIR=`pwd`		# working dir&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Preparing rc files&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# we use simple sorting to make sure the lines do not jump around too much from system to system&lt;br /&gt;
find . -name '*.rc' -o -name '*.ui' -o -name '*.kcfg' | sort &amp;gt; ${WDIR}/rcfiles.list&lt;br /&gt;
xargs --arg-file=${WDIR}/rcfiles.list extractrc &amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
# additional string for KAboutData&lt;br /&gt;
echo 'i18nc(&amp;quot;NAME OF TRANSLATORS&amp;quot;,&amp;quot;Your names&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
echo 'i18nc(&amp;quot;EMAIL OF TRANSLATORS&amp;quot;,&amp;quot;Your emails&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
echo &amp;quot;Done preparing rc files&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Extracting messages&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# see above on sorting&lt;br /&gt;
find . -name '*.cpp' -o -name '*.h' -o -name '*.c' | sort &amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
echo &amp;quot;rc.cpp&amp;quot; &amp;gt;&amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
xgettext --from-code=UTF-8 -C -kde -ci18n -ki18n:1 -ki18nc:1c,2 -ki18np:1,2 -ki18ncp:1c,2,3 -ktr2i18n:1 \&lt;br /&gt;
	-kI18N_NOOP:1 -kI18N_NOOP2:1c,2 -kaliasLocale -kki18n:1 -kki18nc:1c,2 -kki18np:1,2 -kki18ncp:1c,2,3 \&lt;br /&gt;
	--msgid-bugs-address=&amp;quot;${BUGADDR}&amp;quot; \&lt;br /&gt;
	--files-from=infiles.list -D ${BASEDIR} -D ${WDIR} -o ${PROJECT}.pot || { echo &amp;quot;error while calling xgettext. aborting.&amp;quot;; exit 1; }&lt;br /&gt;
echo &amp;quot;Done extracting messages&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Merging translations&amp;quot;&lt;br /&gt;
catalogs=`find . -name '*.po'`&lt;br /&gt;
for cat in $catalogs; do&lt;br /&gt;
  echo $cat&lt;br /&gt;
  msgmerge -o $cat.new $cat ${PROJECT}.pot&lt;br /&gt;
  mv $cat.new $cat&lt;br /&gt;
done&lt;br /&gt;
echo &amp;quot;Done merging translations&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Cleaning up&amp;quot;&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
rm rcfiles.list&lt;br /&gt;
rm infiles.list&lt;br /&gt;
rm rc.cpp&lt;br /&gt;
echo &amp;quot;Done&amp;quot;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course you will want to adjust the variable definitions at the top, and - if needed - add code to extract tips-of-the-day or other additional strings.&lt;br /&gt;
&lt;br /&gt;
The example script assumes that all .po files and the .pot file are kept in a single directory, which is appropriate for most projects.&lt;br /&gt;
&lt;br /&gt;
=== Kompilieren und Installieren von Zeichenkettenkatalogen ===&lt;br /&gt;
&lt;br /&gt;
Assuming you use the script from the previous section, you can place the following CMakeLists.txt in the directory containing the .po files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
FIND_PROGRAM(GETTEXT_MSGFMT_EXECUTABLE msgfmt)&lt;br /&gt;
&lt;br /&gt;
IF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
	MESSAGE(&lt;br /&gt;
&amp;quot;------&lt;br /&gt;
                 NOTE: msgfmt not found. Translations will *not* be installed&lt;br /&gt;
------&amp;quot;)&lt;br /&gt;
ELSE(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&lt;br /&gt;
        SET(catalogname rkward)&lt;br /&gt;
&lt;br /&gt;
	ADD_CUSTOM_TARGET(translations ALL)&lt;br /&gt;
	&lt;br /&gt;
	FILE(GLOB PO_FILES *.po)&lt;br /&gt;
	&lt;br /&gt;
	FOREACH(_poFile ${PO_FILES})&lt;br /&gt;
		GET_FILENAME_COMPONENT(_lang ${_poFile} NAME_WE)&lt;br /&gt;
		SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_lang}.gmo)&lt;br /&gt;
		ADD_CUSTOM_COMMAND(TARGET translations&lt;br /&gt;
			COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} --check -o ${_gmoFile} ${_poFile}&lt;br /&gt;
			DEPENDS ${_poFile})&lt;br /&gt;
		INSTALL(FILES ${_gmoFile} DESTINATION ${LOCALE_INSTALL_DIR}/${_lang}/LC_MESSAGES/ RENAME ${catalogname}.mo)&lt;br /&gt;
	ENDFOREACH(_poFile ${PO_FILES})&lt;br /&gt;
&lt;br /&gt;
ENDIF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This iterates over all .po files in the directory, compiles them using msgfmt, and installs them to the standard location. You will want to change &amp;quot;catalogname&amp;quot; to the name of your application.&lt;br /&gt;
&lt;br /&gt;
=== Übersetzungen erhalten ===&lt;br /&gt;
&lt;br /&gt;
Now you just have to find translators to translate the extracted messages into the various languages. As your application gets used by more people, you will find that translators will volunteer to do this. Translated PO files then have to be stored in the po folder with the naming scheme &amp;lt;languagecode&amp;gt;.po.&lt;br /&gt;
&lt;br /&gt;
== Sonderfälle (plugins, mehrere catalogs, etc.) ==&lt;br /&gt;
&lt;br /&gt;
=== Kataloge zur Laufzeit laden ===&lt;br /&gt;
&lt;br /&gt;
To have translations show up properly in an application, the name of the .pot file must match the name of the message catalog (.mo) file that your application will read at runtime. But what name will be used at runtime?&lt;br /&gt;
&lt;br /&gt;
In general, it will be the value returned by &amp;lt;tt&amp;gt;{{class|KGlobal}}::instance()-&amp;gt;instanceName()&amp;lt;/tt&amp;gt;. But what will that be? The general rules for standalone applications are:&lt;br /&gt;
* the message catalog will default to the name of the application passed as the first argument to {{class|KAboutData}}&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::setMainCatalog()&amp;lt;/tt&amp;gt;, that name will be used instead&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;, the specified catalog will also be searched in addition to the main catalog&lt;br /&gt;
&lt;br /&gt;
If your code does not call either of the {{class|KLocale}} methods mentioned above and your application is a plugin, it gets a little more complicated. If your code exports your plugin using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;K_EXPORT_COMPONENT_FACTORY( libkhtmlkttsdplugin,&lt;br /&gt;
  KGenericFactory&amp;lt;KHTMLPluginKTTSD&amp;gt;(&amp;quot;khtmlkttsd&amp;quot;) )&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
then the catalog name will be the name passed in the {{class|KGenericFactory}} constructor - in the example above that woudl be &amp;lt;tt&amp;gt;khtmlkttsd&amp;lt;/tt&amp;gt;. This is because the macro creates a {{class|Kinstance}} for you with the specified name.&lt;br /&gt;
&lt;br /&gt;
However, some classes, such as &amp;lt;tt&amp;gt;KTextEditor&amp;lt;/tt&amp;gt; create a &amp;lt;tt&amp;gt;KPart&amp;lt;/tt&amp;gt; containing your component and the name passed in the macro is not used. In this case, you should call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; in the component's constructor.&lt;br /&gt;
&lt;br /&gt;
If in doubt, the safest thing to do is to call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
{{tip|If you're not using the export macro for your plugin, you probably should be. See the API documentation of KGenericFactory for more information.}}&lt;br /&gt;
&lt;br /&gt;
Calling &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; if the catalog has already been inserted does nothing. However, calling &amp;lt;tt&amp;gt;{{class|KLocale}}::removeCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; removes the catalog no matter how many times it has been inserted. Therefore, take care that you do not inadvertently remove the catalog when multiple components are sharing a single catalog. For example, the following sequence will break translations: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;// Component A loads and uses catalog xyz by calling&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// Component B loads and also uses the same catalog.&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// component B unloads and calls&lt;br /&gt;
removeCatalogue(&amp;quot;xyz&amp;quot;)&lt;br /&gt;
// Component A now doesn't translate properly.&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Notice that a sequence such as above will occur automatically if both components A and B are loaded using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro and pass the same name argument to the KGenericFactory constructor.&lt;br /&gt;
&lt;br /&gt;
=== Benennung von .pot Dateien ===&lt;br /&gt;
&lt;br /&gt;
The name that you settle on for both the .pot file and catalog should be governed by where your code resides. If it is a component of another application and resides in that application's source tree, you'll want to share the main catalog of the application. &lt;br /&gt;
&lt;br /&gt;
If is a component of another application but resides elsewhere in the code repository, you will probably have to create a separate .pot, but keep in mind that .pot filenames must be unique across all of KDE.&lt;br /&gt;
&lt;br /&gt;
If it is a component of another application, but resides in the source tree of a second application, you should share with the second application. For example, the KDE text-to-speach daemon (KTTSD) includes a plugin for embedded Kate in {{path|kdeaccessibility/kttsd}} source tree. Since the plugin is not installed unless kttsd is installed, it shares its catalog with kttsd and calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(&amp;quot;kttsd&amp;quot;)&amp;lt;/tt&amp;gt; to do this.&lt;br /&gt;
&lt;br /&gt;
== Handbücher ==&lt;br /&gt;
&lt;br /&gt;
Handbooks, which are written in docbook format, are handled different from applications. The translated Handbooks are committed into the l10n module in the docs folder under each language. In addition, the docs folder is broken down by module and application. For example, the German Kate Handbook is committed to the {{path|l10n/de/docs/kdebase/kate/}} folder. When compiled, the German Kate Handbook is installed to {{path|$KDEDIR/share/doc/HTML/de/kate/index.cache.bz2}}.&lt;br /&gt;
&lt;br /&gt;
Note that it is up to each translation team to generate the translated Handbook when they feel it is complete.&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems</id>
		<title>Development/Tutorials/Localization/i18n Build Systems</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_Build_Systems"/>
				<updated>2007-12-21T14:37:23Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n Build Systems}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
&lt;br /&gt;
series=Localization|&lt;br /&gt;
&lt;br /&gt;
name=Building KDE's l10n Module|&lt;br /&gt;
&lt;br /&gt;
pre=[[../i18n|Writing Applications With Localization in Mind]]|&lt;br /&gt;
next=[[../Language Change|Dealing with language changes]]|&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
&lt;br /&gt;
Now that your application is ready to be localized, we next look at how to incorporate the necessary mechanisms into the CMake build system of your application.&lt;br /&gt;
&lt;br /&gt;
First we'll explain the &amp;quot;theory&amp;quot; of the steps that need to happen from extracting message strings to installing the generated .po files. After that we'll look at how to implement those steps ([[#Theory: The xgettext toolchain]]). If your application is developed in KDE's subversion repository, many of those steps will happen automatically (see [[#handling i18n in KDE's subversion repository]]). Else you will want to read on in the [[#handling i18n in third party applications]] section.&lt;br /&gt;
&lt;br /&gt;
== Theory: The xgettext toolchain ==&lt;br /&gt;
&lt;br /&gt;
Making translations work consists of the following steps:&lt;br /&gt;
# Extract the translatable strings&lt;br /&gt;
# Merge the new or changed strings with existing translations&lt;br /&gt;
# Compile the translations into message catalogs&lt;br /&gt;
# Install the message catalogs&lt;br /&gt;
# Use the message catalogs in the application&lt;br /&gt;
&lt;br /&gt;
=== Extracting the strings ===&lt;br /&gt;
&lt;br /&gt;
In this step, all the strings you marked as i18n()/ki18n()/etc. in your sources need to be collected into a translation template (.pot) file. Some translateable strings are also contained in .ui, .rc, or .kcfg files. Also tips-of-the-day need to be collected into the .pot file.&lt;br /&gt;
&lt;br /&gt;
These steps are handled by {{path|xgettext}}, {{path|extractrc}}, and {{path|preparetips}} programs, respectively. In some cases you may also need {{path|extractattr}}.&lt;br /&gt;
&lt;br /&gt;
=== Merging translations ===&lt;br /&gt;
&lt;br /&gt;
Generally, only a few translatable string will change at a time, in an application. Some will be removed, some will be added, some will be changed into different strings, and some will be moved around in the source files. These changes need to be reflected in the translations, but of course it would be a huge effort to redo the entire translation every time a string was changed. Rather the changes should be merged with the existing translations. This is the job of the {{path|msgmerge}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Compiling the translations ===&lt;br /&gt;
&lt;br /&gt;
In order to make message lookup fast, the .po files need to be compiled into so-called &amp;quot;message catalogs&amp;quot; (.mo / .gmo). This is done using the {{path|msgfmt}} tool.&lt;br /&gt;
&lt;br /&gt;
=== Installing the message catalogs ===&lt;br /&gt;
&lt;br /&gt;
The compiled message catalogs need to be installed alongside the application. In KDE, the standard location for message catalogs is {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}.&lt;br /&gt;
&lt;br /&gt;
=== Using the message catalogs ===&lt;br /&gt;
&lt;br /&gt;
Finally, when the application is run, it needs to load the appropriate message catalog in order to be able to look up and show translated strings. In KDE applications, this is the job of the {{class|KLocale}} class, and in the great majority of cases happens automatically.&lt;br /&gt;
&lt;br /&gt;
For some special cases, such as plugins, look at [[#Runtime Loading Of Catalogs]].&lt;br /&gt;
&lt;br /&gt;
== handling i18n in KDE's subversion repository ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed inside KDE's subversion repository, most of the steps outlined above are automated. In this case, generally, all you will need to do is provide a simple script called {{path|Messages.sh}}, which we will look at below.&lt;br /&gt;
&lt;br /&gt;
In addition, if your top-level folder and .pot file have the same name, the svn2dist script will automatically include .po files when you use it to make a source tarball for your app. &lt;br /&gt;
&lt;br /&gt;
Of course, for the curious, a more detailed account of what happens behind the scences is also provided.&lt;br /&gt;
&lt;br /&gt;
=== Writing a Messages.sh script ===&lt;br /&gt;
&lt;br /&gt;
Basically, the only thing that is necessary to prepare and install translations for applications in KDE's subversion repository, is to provide information, which sources, ui-files or tips need to be translated. For this purpose, you write a small script called {{path|Messages.sh}} and place it in your sources. Here is an example with inline comments:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!bin/sh&lt;br /&gt;
&lt;br /&gt;
# invoke the extractrc script on all .ui, .rc, and .kcfg files in the sources&lt;br /&gt;
# the results are stored in a pseudo .cpp file to be picked up by xgettext.&lt;br /&gt;
$EXTRACTRC `find . -name \*.rc -o -name \*.ui -o -name \*.kcfg` &amp;gt;&amp;gt; rc.cpp&lt;br /&gt;
# if your application contains tips-of-the-day, call preparetips as well.&lt;br /&gt;
$PREPARETIPS &amp;gt; tips.cpp&lt;br /&gt;
# call xgettext on all source files. If your sources have other filename&lt;br /&gt;
# extensions besides .cc, .cpp, and .h, just add them in the find call.&lt;br /&gt;
$XGETTEXT `find . -name \*.cc -o -name \*.cpp -o -name \*.h` -o $podir/APPNAME.pot&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
As you can see, this script contains only three actual lines of code, and not all may even be needed. The $XGETTEXT, $PREPARETIPS, $EXTRACTRC, and $podir environment variables are predefined, you do not need to worry about setting these. The only thing that you will need to do is to replace &amp;quot;APPNAME&amp;quot; with the name of your application (but see [[#Naming .pot Files]] for exceptions).&lt;br /&gt;
&lt;br /&gt;
Try to make sure your Messages.sh script collects only those messages that are really needed. If in doubt, look at other Messages.sh files in the KDE subversion repository for inspiration, or - of course - ask.&lt;br /&gt;
&lt;br /&gt;
=== What's happening behind the scenes ===&lt;br /&gt;
&lt;br /&gt;
{{tip|If your application is in the KDE code repository, all this happens automatically. If your code is not in the KDE repository, you must perform these steps yourself. See [[#handling i18n in third party applications]].}}&lt;br /&gt;
&lt;br /&gt;
Periodically, the script {{path|extract-messages.sh}} (a.k.a. scripty) runs on the KDE server. This program basically calls all Messages.sh scripts in the repository with the appropriate parameters. The extracted messages are stored in template (.pot) files in the templates folder of the l10n module. See [[What Is Scripty]] for more information. &lt;br /&gt;
&lt;br /&gt;
The KDE translation teams translate the messages and commit them into a messages folder corresponding to the language, which is further broken down by module. For example, German translated messages for konqueror are committed to {{path|l10n/de/messages/kdebase/konqueror.po}}. &lt;br /&gt;
&lt;br /&gt;
When the l10n module is built, the .po files are compiled into a binary format for fast lookup and installed as .mo files to {{path|$KDEDIR/share/locale/xx/LC_MESSAGES/}}, where xx is the two-letter ISO 639 code for the language. These are called the message catalogs. &lt;br /&gt;
&lt;br /&gt;
At runtime, the &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; function, using the original string you coded, looks up the string in the message catalog of the user's desktop language and returns the translated string. If the message catalog is missing, or the specific string is not found, &amp;lt;tt&amp;gt;i18n(...)&amp;lt;/tt&amp;gt; falls back to the original string in your code. &lt;br /&gt;
&lt;br /&gt;
.desktop files in your project are handled separately. {{path|makemessages}} extracts strings, such as Name and Comment from the .desktop files and places them into a file named {{path|desktop_mmmm.pot}}, where mmmm is the module name, in the templates folder. Once translators have translated this file, makemessages inserts the translated strings back into the .desktop files. The list of strings extracted is in {{path|l10n/scripts/apply.cc}}. Here's the code that checks for them:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;if (checkTag(&amp;quot;Name&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Comment&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Language&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Keywords&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;About&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Description&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;GenericName&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;Query&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&lt;br /&gt;
if (checkTag(&amp;quot;ExtraNames&amp;quot;, in, argc, argv, newFile))&lt;br /&gt;
    continue;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== handling i18n in third party applications ==&lt;br /&gt;
&lt;br /&gt;
If your application is developed outside of KDE's subversion repository, you need to take care of generating and installing message catalogs yourself. This is not too hard to do, but you should make sure you have a basic understanding of all steps involved, so you will probably want to read [[#Theory: The xgettext toolchain]], first.&lt;br /&gt;
&lt;br /&gt;
Also, there is more than one way to deal with i18n in your application. We will outline one approach to do so for simple applications, but you may want to diverge from this, if you like to.&lt;br /&gt;
&lt;br /&gt;
{{note|The following improvements are needed in this section (or is this obsolete?):&lt;br /&gt;
How can messages for .desktop files be extracted? &lt;br /&gt;
How can translated .desktop messages be inserted back into .desktop files?}}&lt;br /&gt;
&lt;br /&gt;
=== General considerations ===&lt;br /&gt;
&lt;br /&gt;
The i18n generation process can roughly be divided into two steps:&lt;br /&gt;
&lt;br /&gt;
# Extracting and merging messages&lt;br /&gt;
# Compiling and installing message catalogs&lt;br /&gt;
&lt;br /&gt;
The first step really concerns the ''sources'', while the second step is a natural part of compiling and installing an application. Hence, while the second step should definitely be incorporated into the build system for your application (we assume CMake, here), there is no striking reason for the first step to be handled by the build system.&lt;br /&gt;
&lt;br /&gt;
In fact, the extraction and merging of messages does not map well onto the CMake concept of out-of-source builds, and CMake can't provide too much help for this step, either.&lt;br /&gt;
&lt;br /&gt;
Hence, in this tutorial, we will handle the first step with a standalone shell script, and only the second step will be handled by CMake.&lt;br /&gt;
&lt;br /&gt;
=== Extracting and merging messages ===&lt;br /&gt;
&lt;br /&gt;
If you have read the section [[#handling i18n in KDE's subversion repository]] you will know that in the KDE repository, message extraction and merging is handled by a simple script called Messages.sh, which is invoked by a script called {{path|extract-messages.sh}}. Outside of KDE's repository, you will need to take care of both parts, but fortunately, this is easy enough. Here's a sample script:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash n&amp;gt;&lt;br /&gt;
#!/bin/sh&lt;br /&gt;
BASEDIR=&amp;quot;../rkward/&amp;quot;	# root of translatable sources&lt;br /&gt;
PROJECT=&amp;quot;rkward&amp;quot;	# project name&lt;br /&gt;
BUGADDR=&amp;quot;http://sourceforge.net/tracker/?group_id=50231&amp;amp;atid=459007&amp;quot;	# MSGID-Bugs&lt;br /&gt;
WDIR=`pwd`		# working dir&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Preparing rc files&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# we use simple sorting to make sure the lines do not jump around too much from system to system&lt;br /&gt;
find . -name '*.rc' -o -name '*.ui' -o -name '*.kcfg' | sort &amp;gt; ${WDIR}/rcfiles.list&lt;br /&gt;
xargs --arg-file=${WDIR}/rcfiles.list extractrc &amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
# additional string for KAboutData&lt;br /&gt;
echo 'i18nc(&amp;quot;NAME OF TRANSLATORS&amp;quot;,&amp;quot;Your names&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
echo 'i18nc(&amp;quot;EMAIL OF TRANSLATORS&amp;quot;,&amp;quot;Your emails&amp;quot;);' &amp;gt;&amp;gt; ${WDIR}/rc.cpp&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
echo &amp;quot;Done preparing rc files&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Extracting messages&amp;quot;&lt;br /&gt;
cd ${BASEDIR}&lt;br /&gt;
# see above on sorting&lt;br /&gt;
find . -name '*.cpp' -o -name '*.h' -o -name '*.c' | sort &amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
echo &amp;quot;rc.cpp&amp;quot; &amp;gt;&amp;gt; ${WDIR}/infiles.list&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
xgettext --from-code=UTF-8 -C -kde -ci18n -ki18n:1 -ki18nc:1c,2 -ki18np:1,2 -ki18ncp:1c,2,3 -ktr2i18n:1 \&lt;br /&gt;
	-kI18N_NOOP:1 -kI18N_NOOP2:1c,2 -kaliasLocale -kki18n:1 -kki18nc:1c,2 -kki18np:1,2 -kki18ncp:1c,2,3 \&lt;br /&gt;
	--msgid-bugs-address=&amp;quot;${BUGADDR}&amp;quot; \&lt;br /&gt;
	--files-from=infiles.list -D ${BASEDIR} -D ${WDIR} -o ${PROJECT}.pot || { echo &amp;quot;error while calling xgettext. aborting.&amp;quot;; exit 1; }&lt;br /&gt;
echo &amp;quot;Done extracting messages&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Merging translations&amp;quot;&lt;br /&gt;
catalogs=`find . -name '*.po'`&lt;br /&gt;
for cat in $catalogs; do&lt;br /&gt;
  echo $cat&lt;br /&gt;
  msgmerge -o $cat.new $cat ${PROJECT}.pot&lt;br /&gt;
  mv $cat.new $cat&lt;br /&gt;
done&lt;br /&gt;
echo &amp;quot;Done merging translations&amp;quot;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
echo &amp;quot;Cleaning up&amp;quot;&lt;br /&gt;
cd ${WDIR}&lt;br /&gt;
rm rcfiles.list&lt;br /&gt;
rm infiles.list&lt;br /&gt;
rm rc.cpp&lt;br /&gt;
echo &amp;quot;Done&amp;quot;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Of course you will want to adjust the variable definitions at the top, and - if needed - add code to extract tips-of-the-day or other additional strings.&lt;br /&gt;
&lt;br /&gt;
The example script assumes that all .po files and the .pot file are kept in a single directory, which is appropriate for most projects.&lt;br /&gt;
&lt;br /&gt;
=== Compiling and installing message catalogs ===&lt;br /&gt;
&lt;br /&gt;
Assuming you use the script from the previous section, you can place the following CMakeLists.txt in the directory containing the .po files:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
FIND_PROGRAM(GETTEXT_MSGFMT_EXECUTABLE msgfmt)&lt;br /&gt;
&lt;br /&gt;
IF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
	MESSAGE(&lt;br /&gt;
&amp;quot;------&lt;br /&gt;
                 NOTE: msgfmt not found. Translations will *not* be installed&lt;br /&gt;
------&amp;quot;)&lt;br /&gt;
ELSE(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&lt;br /&gt;
        SET(catalogname rkward)&lt;br /&gt;
&lt;br /&gt;
	ADD_CUSTOM_TARGET(translations ALL)&lt;br /&gt;
	&lt;br /&gt;
	FILE(GLOB PO_FILES *.po)&lt;br /&gt;
	&lt;br /&gt;
	FOREACH(_poFile ${PO_FILES})&lt;br /&gt;
		GET_FILENAME_COMPONENT(_lang ${_poFile} NAME_WE)&lt;br /&gt;
		SET(_gmoFile ${CMAKE_CURRENT_BINARY_DIR}/${_lang}.gmo)&lt;br /&gt;
		ADD_CUSTOM_COMMAND(TARGET translations&lt;br /&gt;
			COMMAND ${GETTEXT_MSGFMT_EXECUTABLE} --check -o ${_gmoFile} ${_poFile}&lt;br /&gt;
			DEPENDS ${_poFile})&lt;br /&gt;
		INSTALL(FILES ${_gmoFile} DESTINATION ${LOCALE_INSTALL_DIR}/${_lang}/LC_MESSAGES/ RENAME ${catalogname}.mo)&lt;br /&gt;
	ENDFOREACH(_poFile ${PO_FILES})&lt;br /&gt;
&lt;br /&gt;
ENDIF(NOT GETTEXT_MSGFMT_EXECUTABLE)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
This iterates over all .po files in the directory, compiles them using msgfmt, and installs them to the standard location. You will want to change &amp;quot;catalogname&amp;quot; to the name of your application.&lt;br /&gt;
&lt;br /&gt;
=== Getting translations ===&lt;br /&gt;
&lt;br /&gt;
Now you just have to find translators to translate the extracted messages into the various languages. As your application gets used by more people, you will find that translators will volunteer to do this. Translated PO files then have to be stored in the po folder with the naming scheme &amp;lt;languagecode&amp;gt;.po.&lt;br /&gt;
&lt;br /&gt;
== Special cases (plugins, multiple catalogs, etc.) ==&lt;br /&gt;
&lt;br /&gt;
=== Runtime Loading Of Catalogs ===&lt;br /&gt;
&lt;br /&gt;
To have translations show up properly in an application, the name of the .pot file must match the name of the message catalog (.mo) file that your application will read at runtime. But what name will be used at runtime?&lt;br /&gt;
&lt;br /&gt;
In general, it will be the value returned by &amp;lt;tt&amp;gt;{{class|KGlobal}}::instance()-&amp;gt;instanceName()&amp;lt;/tt&amp;gt;. But what will that be? The general rules for standalone applications are:&lt;br /&gt;
* the message catalog will default to the name of the application passed as the first argument to {{class|KAboutData}}&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::setMainCatalog()&amp;lt;/tt&amp;gt;, that name will be used instead&lt;br /&gt;
* if your code calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;, the specified catalog will also be searched in addition to the main catalog&lt;br /&gt;
&lt;br /&gt;
If your code does not call either of the {{class|KLocale}} methods mentioned above and your application is a plugin, it gets a little more complicated. If your code exports your plugin using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro, like this:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;K_EXPORT_COMPONENT_FACTORY( libkhtmlkttsdplugin,&lt;br /&gt;
  KGenericFactory&amp;lt;KHTMLPluginKTTSD&amp;gt;(&amp;quot;khtmlkttsd&amp;quot;) )&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
then the catalog name will be the name passed in the {{class|KGenericFactory}} constructor - in the example above that woudl be &amp;lt;tt&amp;gt;khtmlkttsd&amp;lt;/tt&amp;gt;. This is because the macro creates a {{class|Kinstance}} for you with the specified name.&lt;br /&gt;
&lt;br /&gt;
However, some classes, such as &amp;lt;tt&amp;gt;KTextEditor&amp;lt;/tt&amp;gt; create a &amp;lt;tt&amp;gt;KPart&amp;lt;/tt&amp;gt; containing your component and the name passed in the macro is not used. In this case, you should call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; in the component's constructor.&lt;br /&gt;
&lt;br /&gt;
If in doubt, the safest thing to do is to call &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt;. &lt;br /&gt;
&lt;br /&gt;
{{tip|If you're not using the export macro for your plugin, you probably should be. See the API documentation of KGenericFactory for more information.}}&lt;br /&gt;
&lt;br /&gt;
Calling &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; if the catalog has already been inserted does nothing. However, calling &amp;lt;tt&amp;gt;{{class|KLocale}}::removeCatalog(const QString&amp;amp;)&amp;lt;/tt&amp;gt; removes the catalog no matter how many times it has been inserted. Therefore, take care that you do not inadvertently remove the catalog when multiple components are sharing a single catalog. For example, the following sequence will break translations: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;// Component A loads and uses catalog xyz by calling&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// Component B loads and also uses the same catalog.&lt;br /&gt;
insertCatalogue(&amp;quot;xyz&amp;quot;);&lt;br /&gt;
// component B unloads and calls&lt;br /&gt;
removeCatalogue(&amp;quot;xyz&amp;quot;)&lt;br /&gt;
// Component A now doesn't translate properly.&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Notice that a sequence such as above will occur automatically if both components A and B are loaded using the &amp;lt;tt&amp;gt;K_EXPORT_COMPONENT_FACTORY&amp;lt;/tt&amp;gt; macro and pass the same name argument to the KGenericFactory constructor.&lt;br /&gt;
&lt;br /&gt;
=== Naming .pot Files ===&lt;br /&gt;
&lt;br /&gt;
The name that you settle on for both the .pot file and catalog should be governed by where your code resides. If it is a component of another application and resides in that application's source tree, you'll want to share the main catalog of the application. &lt;br /&gt;
&lt;br /&gt;
If is a component of another application but resides elsewhere in the code repository, you will probably have to create a separate .pot, but keep in mind that .pot filenames must be unique across all of KDE.&lt;br /&gt;
&lt;br /&gt;
If it is a component of another application, but resides in the source tree of a second application, you should share with the second application. For example, the KDE text-to-speach daemon (KTTSD) includes a plugin for embedded Kate in {{path|kdeaccessibility/kttsd}} source tree. Since the plugin is not installed unless kttsd is installed, it shares its catalog with kttsd and calls &amp;lt;tt&amp;gt;{{class|KLocale}}::insertCatalog(&amp;quot;kttsd&amp;quot;)&amp;lt;/tt&amp;gt; to do this.&lt;br /&gt;
&lt;br /&gt;
== Handbooks ==&lt;br /&gt;
&lt;br /&gt;
Handbooks, which are written in docbook format, are handled different from applications. The translated Handbooks are committed into the l10n module in the docs folder under each language. In addition, the docs folder is broken down by module and application. For example, the German Kate Handbook is committed to the {{path|l10n/de/docs/kdebase/kate/}} folder. When compiled, the German Kate Handbook is installed to {{path|$KDEDIR/share/doc/HTML/de/kate/index.cache.bz2}}.&lt;br /&gt;
&lt;br /&gt;
Note that it is up to each translation team to generate the translated Handbook when they feel it is complete.&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials_(de)</id>
		<title>Development/Tutorials (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials_(de)"/>
				<updated>2007-12-21T14:34:26Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added two more translated chapters&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials}}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Bitte hilf, die englische Seite vollständig ins Deutsche zu übersetzen.}}&lt;br /&gt;
&lt;br /&gt;
== Einführung in die KDE 4 Programmierung ==&lt;br /&gt;
Sind Sie an der Entwicklung von Programmen für KDE 4 interesiert? Wenn ja sind Sie hier genau richtig. Diese Artikelserie richtet sich an alle, die noch nie mit KDE programmiert haben.&lt;br /&gt;
;[[Development/Tutorials/First program (de)|Hallo Welt!]]&lt;br /&gt;
:''Einführung in die Grundlagen der KDE Programmierung''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KXmlGuiWindow (de)|Erstellen eines Hauptfensters]]&lt;br /&gt;
:''Dieser Artikel erklärt, wie der wichtigste Teil eines grafischen Programmes erstellt wird: das Hauptfenster.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KActions (de)|Die Verwendung von KActions]]&lt;br /&gt;
:''In diesem Artikel erfahren Sie, wie Aktionen und Werkzeugleisten (Toolbars) im Menü hinzugefügt werden können.''&lt;br /&gt;
&lt;br /&gt;
== Grundlagen ==&lt;br /&gt;
;[[Development/Tutorials/KDE4 Porting Guide (de)|Ihre Applikation nach KDE 4 portieren]]&lt;br /&gt;
:''Anleitungen Qt3/KDE3 Applikationen nach Qt4/KDE4 zu portieren''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/CMake (de)|Einführung in CMake]]&lt;br /&gt;
:''Wie man CMake in KDE 4 benutzt''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Common Programming Mistakes (de)|Häufige Programmierfehler]]&lt;br /&gt;
:''Einige häufige Fehler die man während der Entwicklung von Qt und KDE Applikationen machen kann und wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using Qt Designer (de)|Den Qt Designer benutzen um Benutzerschnittstellen zu erzeugen]]&lt;br /&gt;
:''Wie man UI Dateien mit dem Designer erzeugt und wie man diese in einem KDE Programm integriert.''&lt;br /&gt;
&lt;br /&gt;
== Dienste: Applicationen and Plugins ==&lt;br /&gt;
;[[Development/Tutorials/Services/Introduction (de)|Einführung in das Dienst-Framework]]&lt;br /&gt;
:''Eine Einführung über das Dienst-Framework in KDE und was es dem Applikationsentwickler zur Verfügung stellen kann. Beschäftigt sich mit dem system configuration cache (SyCoCa), den benötigten Dateien und wie indizierte Informationen benutzt werden.&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Traders (de)|Dienste über Trader Queries finden]]&lt;br /&gt;
:''Wie man mit der Trader Query Syntax Dienste wie Plugins oder Mimetypes findet, die im SyCoCa zwischengespeichert wurden. ''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Plugins (de)|Erstellen und Laden von Plugins mit KService]]&lt;br /&gt;
:''Zeigt, wie man eigene Plugintypen definiert, installiere Plugins findet (einschließlich denen von anderen Herstellern) und wie man diese einfach und portabel läd, indem man KService benutzt.''&lt;br /&gt;
&lt;br /&gt;
== Lokalisation ==&lt;br /&gt;
;[[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]]&lt;br /&gt;
:''Eine Einführung was Unicode ist und wie KDE Applikationen damit umgehen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n (de)|Beim Schreiben der Applikation an die Lokalisation denken]]&lt;br /&gt;
:''Diese Anleitung beschäftigt sich damit, was Lokalisation ist, warum sie wichtig ist und wie man sicherstellt, dass die eigene Applikation bereit ist, lokalisiert zu werden. Jeder Applikationsentwickler sollte das lesen.''&lt;br /&gt;
&lt;br /&gt;
; [[Development/Tutorials/Localization/i18n Mistakes (de)|Häufige Fehler vermeiden]]&lt;br /&gt;
:''Es gibt einige häufige Fehler, die es verhindern, dass eine Applikation angemesssen übersetzt werden kann. Diese Anleitung zeigt diese Fehler auf und zeigt, wie man sie vermeidet.''&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_Mistakes_(de)</id>
		<title>Development/Tutorials/Localization/i18n Mistakes (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_Mistakes_(de)"/>
				<updated>2007-12-21T14:29:45Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and first translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n Mistakes}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
name=Häufige Fehler vermeiden|&lt;br /&gt;
&lt;br /&gt;
pre=[[../i18n (de)|Beim Schreiben der Applikation an die Lokalisation denken]]|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Build_Systems (de)|i18n in das Build System einbinden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
Es gibt ein paar häufige Fehler, die es unmöglich machen, eine Applikation angemessen zu übersetzen oder anderweitig zu lokalisieren. Das beinhaltet Pixel basierte Layouts, &amp;quot;Wort Puzzles&amp;quot; und Code, der Unicode Zeichen nicht adäquat behandelt. Diese Anleitung beschäftigt sich mit diesen Fällen und erklärt wie man sie verhindert. &lt;br /&gt;
&lt;br /&gt;
== Falle #1: Pixel basierte Layouts ==&lt;br /&gt;
&lt;br /&gt;
Englischer Text ist verglichen mit anderen Sprachen häufig sehr kompakt, der übersetze Text kann oft deutlich länger sein. Daher muß die Benutzerschnittstelle in der Lage sein, die Größe aufgrund der Länge der Übersetzung zur Laufzeit anzupassen. Kann sie das nicht, wird Text falsch angeordnet und/oder abgeschnitten.&lt;br /&gt;
&lt;br /&gt;
Die Antwort darauf ist die Benutzung von Layoutmanagern. Qt bietet eine Anzahl von solchen Managern wie geschaffen für diesen Zweck. Darunter sind {{Qt|QHBoxLayout}}, {{Qt|QVBoxLayout}}, {{Qt|QGridLayout}} und {{Qt|QStackedLayout}}, alles Unterklassen von {{Qt|QLayout}}. Sie können auch eigene Klassen abgeleitet von {{Qt|QLayout}} erzeugen, das ist aber in der Regel nicht nötig. &lt;br /&gt;
&lt;br /&gt;
Diese Layoutklassen kümmern sich um die Positionierung von Widgets zur Laufzeit, so macht es keinen Unterschied wie lang die übersetzten Zeichenketten sind. Die Benutzerschnittstelle passt sich entsprechend an. Für mehr Informationen siehe auch [http://doc.trolltech.com/qlayout.html QLayout (in englisch)].&lt;br /&gt;
&lt;br /&gt;
== Falle #2: Wort Puzzles ==&lt;br /&gt;
Eine andere Sache ist es, zu beachten, nicht mehrere Teilsätze wie folgt zu verknüpfen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString msg=i18n(&amp;quot;Do you want to replace &amp;quot;) + &lt;br /&gt;
                 oldFile+i18n(&amp;quot; with &amp;quot;) + &lt;br /&gt;
                 newFile + &amp;quot;?&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Solche &amp;quot;Wort Puzzle&amp;quot; sind sehr schwer oder überhaupt nicht zu übersetzen. Das liegt daran, dass die Struktur eines Satzes in anderen Sprachen komplett anders sein kann und daher vom Übersetzer kontrolliert werden muss. Wenn die Reihenfolge der Worte und Satzteile wie oben festkodiert ist, kann der Übersetzer keine entsprechende Übersetzung erzeugen. &lt;br /&gt;
&lt;br /&gt;
Zusätzlich zu diesem Problem erhhält der Übersetzung nur Teile des Satzes während der Übersetzung und muss daher raten, was zusammengehört. &lt;br /&gt;
&lt;br /&gt;
Die Lösung ist denkbar einfach: Benutzen Sie &amp;lt;tt&amp;gt;%&amp;lt;i&amp;gt;number&amp;lt;/i&amp;gt;&amp;lt;/tt&amp;gt; Platzhalterersetzungen, die dem Übersetzer nicht nur gute Übersetzungen aufgrund der Möglichkeit den ganzen Satz zu sehen ermöglichen, sondern es ihm oder ihr auch erlaubt auch die Reihenfolge der Argumente frei zu ändern. Die Argumente selber werden als Extraparameter an &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; übergeben.&lt;br /&gt;
&lt;br /&gt;
Das obige Beispiel sollte daher korrekterweise folgendermaßen aussehen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString msg = i18n(&amp;quot;Do you want to replace %1 with %2?&amp;quot;,&lt;br /&gt;
                   oldFile, newFile)&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Vermeiden Sie es etwas anderes als Zahlen oder Nomen mit dieser Methode einzufügen, da in einigen Sprachen die Übersetzung von den eingefügten Worten abhängt. Daher sollten möglichst komplette Sätze erzeugt werden.}}&lt;br /&gt;
&lt;br /&gt;
Ein verwandter Fehler ist es, im zu übersetzenden Text keine Markup Tags wie &amp;amp;lt;b&amp;amp;gt;&amp;amp;lt;/b&amp;amp;gt; or &amp;amp;lt;i&amp;amp;gt;&amp;amp;lt;/i&amp;amp;gt; als Rich Text einzufügen. Nicht alle Sprachen benutzen solche Markups in gleicher Weise wie im Englischen, so es kann für den Übersetzer notwendig sein, diese ebenfalls zu &amp;quot;übersetzen&amp;quot;.&lt;br /&gt;
&lt;br /&gt;
Weiterhin sollten Zeichenketten, die häufig ändernde Zeichenketten enthalten (wie zum Beispiel Versionen) statt dessen als Platzhalter (siehe oben) eingefügt werden. Das verhindert unnötige Änderungen an den Zeichenketten, die die Übersetzer zwingen, die Übersetzungen zu überarbeiten.&lt;br /&gt;
&lt;br /&gt;
Da KDE in mehr als 65 Sprachen übersetzt wird, kann die Änderung einer einzelenen Zeichenkette mindesten 65 Personen dazu zwingen, die Datei zu öffnen, die geänderte Zeichenkette zufinden, sorgfältig sicherzustellen, dass das wirklich das einzige ist, was sich geändert hat, die Neuübersetzung vorzunehemen, die Datei zu speichern und die geänderte Datei in das Repository hochzuladen. Alles in allem kann so eine kleine Änderung Stunden von Arbeit erzeugen, die einfach vermieden werden könnte. &lt;br /&gt;
&lt;br /&gt;
== Falle #3: Fehlende Unicode Unterstützung ==&lt;br /&gt;
Immer dann wenn im Quellcode Datentypen oder Klassen für Zeichenketten benutzt werden, die kein Unicode unterstützen (z.B. &amp;lt;tt&amp;gt;char&amp;lt;/tt&amp;gt; oder &amp;lt;tt&amp;gt;std::string&amp;lt;/tt&amp;gt;), ist eine Übersetzung nicht mehr möglich.&lt;br /&gt;
&lt;br /&gt;
Um das zu vermeiden, rufen Sie niemals QString::latin1() oder QString::ascii() für übersetze Zeichenketten auf. Das gilt auch für Informationen, die Sie von Benutzereingaben wie Passworten, URLs und Dateinamen erhalten. Benötigen Sie wirklich eine einfache &amp;lt;tt&amp;gt;char*&amp;lt;/tt&amp;gt; Darstellung einer Zeichenkette benutzen Sie lieber QString::utf8().&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Für mehr Informationen über Zeichensätze und Unicode siehe  [[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]].}}&lt;br /&gt;
&lt;br /&gt;
KIO slaves können Pfade und Dateinamen in UTF-8 verschlüsselt zur Verfügung stellen. Es liegt jedoch am Programmierer, entsprechend codierte Dateinamen an KIO Methoden zu übergeben. Der richtige Weg das zu tun, ist nicht zu raten, welches Codierungssystem das Dateisystem des Benutzers hat sondern statt dessen die Methoden QFile::encodeName() und QFile::decodeName() zu benutzen.&lt;br /&gt;
&lt;br /&gt;
{{tip|Sie können testweise die UTF-8 Dateinamenunterstützung von KIO einschalten, indem Sie die Umgebungsvariable KDE_UTF8_FILENAMES (z.B. in ~/.bashrc) exportieren.}}&lt;br /&gt;
&lt;br /&gt;
== Erfolg! ==&lt;br /&gt;
Wenn Sie diese drei häufigen Fehler verhindern, so wie es in dieser Anleitung beschrieben ist, wird Ihre Applikation von den verschiedenen KDE Übersetzerteams vollständig lokalisierbar sein und Ihre Applikation der Mehrheit der Menscheit zugänglich machen.&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_Mistakes</id>
		<title>Development/Tutorials/Localization/i18n Mistakes</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_Mistakes"/>
				<updated>2007-12-21T13:53:10Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n Mistakes}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
&lt;br /&gt;
series=Localization|&lt;br /&gt;
&lt;br /&gt;
name=Avoiding Common Localization Pitfalls|&lt;br /&gt;
&lt;br /&gt;
pre=[[../i18n|Writing Applications With Localization in Mind]]|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Build_Systems|Incorporating i18n Into the Build System]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
&lt;br /&gt;
There are a few common pitfalls that prevent applications from being properly translated or otherwise localized. These include using pixel based layouts, &amp;quot;word puzzles&amp;quot; and writing code that does not deal with Unicode characters properly. This tutorial covers each of these issues, explaining what to avoid and how to do it properly.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Pitfall #1: Pixel Based Layouts ==&lt;br /&gt;
&lt;br /&gt;
English text is often very compact compared to other languages where the translated text is often substantially longer. Therefore the interface much be able to adjust size to accommodate the length of translations provided at runtime. If it can't do this, then messages will end up misaligned and truncated.&lt;br /&gt;
&lt;br /&gt;
The answer is to use layout managers. Qt provides a number of such layout managers pre-made for you. They include &amp;lt;tt&amp;gt;QHBoxLayout&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;QVBoxLayout&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;QGridLayout&amp;lt;/tt&amp;gt; and &amp;lt;tt&amp;gt;QStackedLayout&amp;lt;/tt&amp;gt;, all of which are subclasses of &amp;lt;tt&amp;gt;QLayout&amp;lt;/tt&amp;gt;. You may also create your own &amp;lt;tt&amp;gt;QLayout&amp;lt;/tt&amp;gt; based classes, but this is generally not needed. &lt;br /&gt;
&lt;br /&gt;
These layout classes manage the pixel positioning of widgets for you at runtime, so no matter what the size of the translated strings your interface will adjust properly. For more information look at the documentation for [[http://doc.trolltech.com/qlayout.html QLayout]].&lt;br /&gt;
&lt;br /&gt;
== Pitfall #2: Word Puzzles ==&lt;br /&gt;
&lt;br /&gt;
Another thing to be aware of is to not concatenate pieces of sentences together like this: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString msg=i18n(&amp;quot;Do you want to replace &amp;quot;) + &lt;br /&gt;
                 oldFile+i18n(&amp;quot; with &amp;quot;) + &lt;br /&gt;
                 newFile + &amp;quot;?&amp;quot;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Such &amp;quot;word puzzles&amp;quot; are very hard or even impossible to translate. This is because the structure of the sentence will often be completely different in another language and thus must be controlled by the translator. When the order of words and phrases is hard-coded as in the above example, the translator can not create a proper translation.&lt;br /&gt;
&lt;br /&gt;
Adding to this problem, a translator will only see parts of the sentence while translating and will have to guess at what belongs together. &lt;br /&gt;
&lt;br /&gt;
The solution thankfully is quite simple: use &amp;lt;tt&amp;gt;%&amp;lt;i&amp;gt;number&amp;lt;/i&amp;gt;&amp;lt;/tt&amp;gt; placeholder substitution, which lets the translators not only make good translations because they can see the entirety of the sentence during translation, but which also lets them change the order of the arguments freely. The arguments themselves are passed as extra parameters to &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
The above example written properly would then look like this: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QString msg = i18n(&amp;quot;Do you want to replace %1 with %2?&amp;quot;,&lt;br /&gt;
                   oldFile, newFile)&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note|Avoid inserting anything other than numbers or nouns with this method, since in some languages the translation depends on the inserted words. It is therefore best to create strings that are as complete sentences as possible.}}&lt;br /&gt;
&lt;br /&gt;
A related mistake is not including markup tags in rich text, such as &amp;amp;lt;b&amp;amp;gt;&amp;amp;lt;/b&amp;amp;gt; or &amp;amp;lt;i&amp;amp;gt;&amp;amp;lt;/i&amp;amp;gt;, in the translatable string. Not all languages use such markup in an identical fashion to English and so it is necessary for the translator to be able to &amp;quot;translate&amp;quot; the markup accordingly as well.&lt;br /&gt;
&lt;br /&gt;
Similarly, messages that contain a version string or other often changing parts should be inserted by placeholders into the message. This prevents unnecessary changes that cause the translators to have to change the translated messages as well. &lt;br /&gt;
&lt;br /&gt;
Since KDE is translated into more than 65 languages a single string change causes at least 65 people to open the file, find the changed message, look carefully if this is the only thing that has changed, change the translation, save the file again and commit the changed file into the code repository. All in all such a small change might create hours of work which could be easily avoided.&lt;br /&gt;
&lt;br /&gt;
== Pitfall #3: Lack of Unicode Support ==&lt;br /&gt;
&lt;br /&gt;
Whenever there is source code that handles strings using a datatype (such as &amp;lt;tt&amp;gt;char&amp;lt;/tt&amp;gt;) or class (such as &amp;lt;tt&amp;gt;std::string&amp;lt;/tt&amp;gt;) that can not handle Unicode, translations will break.&lt;br /&gt;
&lt;br /&gt;
To avoid this, never call QString::latin1() or QString::ascii() on translated strings. This also applies to information resulting from user input such as passwords, URLs and filenames. If you really need a plain &amp;lt;tt&amp;gt;char*&amp;lt;/tt&amp;gt; representation of a string, it is better to use QString::utf8(). &lt;br /&gt;
&lt;br /&gt;
{{note|For more information on character sets and Unicode, see the [[Development/Tutorials/Localization/Unicode|Unicode tutorial]].}}&lt;br /&gt;
&lt;br /&gt;
KIO slaves may also provide paths and file names encoded using UTF-8. It is up to the programmer, however, to take care of passing properly encoded filenames to any KIO method in question. The correct way to do this is not to guess at user's filesystem encoding but to use QFile::encodeName() and QFile::decodeName() instead.&lt;br /&gt;
&lt;br /&gt;
{{tip|You can turn KIO's UTF-8 file name support on for testing by exporting the KDE_UTF8_FILENAMES environment variable in your shell's startup file (e.g. ~/.bashrc).}}&lt;br /&gt;
&lt;br /&gt;
== Success! ==&lt;br /&gt;
&lt;br /&gt;
If you avoid the three common categories of pitfalls detailed in this tutorial, your application should be fully localizable by the various KDE translation teams around the world and open up your application to the majority of people on the planet.&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)</id>
		<title>Development/Tutorials/Localization/i18n (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)"/>
				<updated>2007-12-21T13:51:17Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Translated the rest&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode (de)|Introduction to Unicode]] ist empfohlen wenn auch nicht notwendig|&lt;br /&gt;
&lt;br /&gt;
name=Beim Applikationen schreiben an die Lokalisation denken|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes (de)|Häufige Fehler vermeiden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Eine breite Schar an Benutzern und Entwicklern zu erreichen erfordert, dass Ihre Software übersetzt werden kann und sich auch anderweitig an sprachliche und kulturelle Gegebenheiten desjenigen anpassen kann, der Ihre Applikation benutzt. Das ist die Aufgabe von Lokalisation und diese Anleitung leitet Sie durch die grundlegenden Schritte, Ihre Applikation lokalisierungsfähig zu machen. &lt;br /&gt;
&lt;br /&gt;
== Was ist Internationalisation and Lokalisation? ==&lt;br /&gt;
&lt;br /&gt;
Internationalisation, oder i18n ('i', gefolgt von 18 Buchstaben und dann ein  'n'), bezeichnet den Prozess, Ihre Applikation so zu schreiben, dass sie in jeder beliebigen Sprache und Kultur laufen kann. Dabei müssen folgende Dinge berücksichtigt werden:&lt;br /&gt;
* Textmitteilungen, die dem Benutzer mitgeteilt werden&lt;br /&gt;
* Dateneingabe vom Benutzer, Dateien und anderen Quellen&lt;br /&gt;
* Das Format von Datum, Zahlen, Währungen, etc. &lt;br /&gt;
&lt;br /&gt;
Lokalisation, oder l10n ('l' gefolgt von 10 Zeichen und dann ein 'n') ist der Prozess, eine internationalisierte Applikation an bestimmte lokale Gegebenheiten anzupassen.&lt;br /&gt;
&lt;br /&gt;
Im allgemeinen internationalisieren Programmierer ihre Applikationen und Übersetzerteams lokalisieren sie. &lt;br /&gt;
&lt;br /&gt;
== Warum ist das wichtig? ==&lt;br /&gt;
&lt;br /&gt;
KDE Entwicklung findet primär in Englisch statt, da dies eine breite Entwickler- und Übersetzerschaft erreicht. Englisch ist jedoch nicht die Muttersprache der meisten Menschen auf der Welt. Tatsächlich sprechen weniger als 8% der Menschheit Englisch und weniger als 5% sprechen es als Muttersprache. Auch im Internet benutzen nur 35% der Menschen die online sind Englisch als primäre Sprache und je mehr Teile der Welt an das Internet angeschlossen werden, desto geringer wird dieser Anteil werden. Zusätzlich benutzen die meisten sprachen, alleine 9 der 10 häufigsten, nicht-ASCII Zeichen in ihrer geschriebenen Form. Daher ist es einfach zu erkennen, warum es notwendig ist, Software zu lokalisieren. &lt;br /&gt;
&lt;br /&gt;
Als internationales Projekt das den gesamten Globul umspannt, ist diese Lokalisation ein wichtiges Gut der KDE Kultur. Tatsächlich entwickeln viele KDE Entwickler ihre Applikationen in Englisch benutzen jedoch ihren KDE-Desktop in der jeweils lokalisierten Version.&lt;br /&gt;
&lt;br /&gt;
== Übersetzbaren Code mit i18n() ==&lt;br /&gt;
Um sicherzustellen, dass Ihre Applikation für eine Lokalisation vorbereitet ist, müssen Sie einigen wenigen einfachen Regeln folgen. Alle für Benutzer sichtbaren Zeichenketten Ihrer Applikation sollten übersetzt werden, bevor Sie auf dem Bildschirm des Benutzers dargestellt werden, ausgenommen davon sind Debug-Ausgaben, Konfigurationsdaten und andere ähnliche Textdaten. &lt;br /&gt;
&lt;br /&gt;
KDE stellt als Teil von &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; die Klasse {{Class|KLocale}} zur Verfügung, um die technischen Aspekte der Lokalisierung zu erledigen. KLocale macht es Entwicklern so einfach wie möglich, ihren Code i18n fähig zu machen, dennoch bleiben einige Dinge, die Sie als Entwickler beachten müssen, damit die Applikation in anderen Sprachen und Ländern eingesetzt werden kann.&lt;br /&gt;
&lt;br /&gt;
Zugriff auf das globale &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; Objekt wird über &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt; zur Verfügung gestellt. Dieses &amp;lt;tt&amp;gt;Klocale&amp;lt;/tt&amp;gt; Objekt wird automatisch von {{Class|KInstance}} erzeugt und kümmert sich um alle i18n betreffenden Einstellungen. Beim Verlassen der Applikation wird das Objekt automatisch gelöscht. &lt;br /&gt;
&lt;br /&gt;
Übersetzungen werden von der i18n(const char*) Methode von {{Qt|QString}} ermöglicht, definiert in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;. Darin müssen alle Zeichenketten, die dargestellt werden, eingebettet werden. Der von &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; zurückgegebene QString ist die (wenn nötig) übersetze Zeichenkette. Dadurch werden übersetzbare Widgets so einfach möglich, wie das nachfolgende Beispiel zeigt:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die native Unicode-Unterstützung von QString stellt sicher, das alle Übersetzungen richtig dargestellt werden. Alle Zeichenkettenbehandlungen Ihrer Applikation sollten daher QString benutzen.&lt;br /&gt;
&lt;br /&gt;
{{tip|Wenn die Zeichenkette, die übersetzt werden soll, irgendwelche nicht-UTF8 Zeichen enthält, benutzen Sie die Methode utf8() um ein char* zu erhalten.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
Die &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; Methoden benötigt ein existierendes {{Class|KInstance}} (z.B. ein {{Class|KApplication}}) Objekt. Für Zeichenketten die vor der Erzeugung erstellt werden muss eine andere Methode zur Verfügung gestellt werden: &amp;lt;tt&amp;gt;ki18n&amp;lt;/tt&amp;gt;. Diese erlaubt es, Zeichenketten zur späteren übersetzung zu markieren. ki18n() gibt ein {{Class|KLocalizedString}} zurück, welches letztlich in ein {{Qt|QString}} konvertiert wird (also schließlich übersetzt wird), nachdem KInstance erzeugt wurde. Dabei wird dessen toString() Methode benutzt. &lt;br /&gt;
&lt;br /&gt;
ki18n() wird typischerweise in Zeichenketten benutzt, die an {{Class|KAboutData}} übergeben werden, da dieses von {{Class|KApplication}} erzeugt wird. Außerhalb dieser Sonderfälle kann man immer ohne Bedenken i18n() benutzen, wenn man sicher ist, dass dieser Code ausgeführt nachdem KApplication oder eine andere {{Class|KInstance}} konstruiert wurde.&lt;br /&gt;
&lt;br /&gt;
=== Kontext hinzufügen ===&lt;br /&gt;
Es gibt eine erweiterte Version von &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt;, die zwei&lt;br /&gt;
&amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; Argumente übernimmt. Das erste Argument ist eine zusätzliche Beschreibung des Kontext, in dem die zweite Zeichenkette übersetzt wird. Die erste Zeichenkette wird dabei benutzt, um zur Laufzeit die zum Kontext passende Übersetzung finden und wird den Übersetzer angezeigt, um diesen zu helfen, die Bedeutung der Zeichenkette zu verstehen.&lt;br /&gt;
&lt;br /&gt;
Benutzen Sie &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; immer dann, wenn der Sinn des Textes mehrdeutig sein kann ohne die Angabe eines Kontext. Stellen Sie sich zum Beispiel das Kontextmenü eines Dateimanagers vor, in dem ein Eintrag namens &amp;quot;View&amp;quot; existiert, die einen Betrachter für die momentan ausgewählte Datei startet. In diesem Kontext ist &amp;quot;View&amp;quot; ein Verb. In der gleichen Applikation könnte jetzt aber auch ein Menüeintrag namens &amp;quot;View&amp;quot; existieren und in diesem Kontext ein Nomen sein. In der englisches Version dieser Applikation würde jetzt alles in Ordnung aussehen, doch in den meisten anderen Spreachen wären diese beiden &amp;quot;View&amp;quot; Zeichenketten nicht gleich. &lt;br /&gt;
&lt;br /&gt;
Zusätzlich benötigen Übersetzer bei ihrer Arbeit manchmal zusätzliche Hilfe zu verstehen, worauf sich der aktuelle Text gerade bezieht. &lt;br /&gt;
&lt;br /&gt;
Im obigen Beispiel des Dateimanagers könnte man daher schreiben:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Jetzt wären diese beiden Zeichenketten angemessen zu übersetzen, sowohl für den menschlichen Übersetzung als auch zur Laufzeit für KLocale. &lt;br /&gt;
&lt;br /&gt;
Benutzen Sie diese Form von i18n immer dann, wenn die Zeichenkette, die übersetzt werden soll, kurz ist oder die Bedeutung schwer zu entscheiden ist, wenn des Kontext nicht bekannt ist. Zum Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Es gibt auch eine ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) Methode, die Kontext zu Zeichenkette hinzufügt, die vor {{Class|KInstance}} erzeugt werden (siehe oben). Es liefert ein {{Class|KLocalizedString}} zurück, damit die Methode toString() hinterher daraus einen QString erzeugen kann.}}&lt;br /&gt;
&lt;br /&gt;
Kontext kann auch in Formularen, die mit dem Qt Designer erzeugt werden, hinzugefügt werden. Jedes Widget Label, einschließlich tooltips und whatsthis Texte haben ein &amp;quot;comment&amp;quot; Attribut, welches den gleichen Zweck wie das erste Argument von &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; hat. &lt;br /&gt;
&lt;br /&gt;
=== Standard Kontext für häufige Ausdrücke ===&lt;br /&gt;
&lt;br /&gt;
Es folgt eine Tabelle, die einige häufige Worte und Satzfragmente im Englischen und den entsprechend zu benutzenden Kontext, der benutzt werden muß, um die entsprechende Übersetzung in andere Sprachen zu bestimmen, auflistet. &lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Kontexte&lt;br /&gt;
|-&lt;br /&gt;
! Satzfragment !! Kontext !! i18nc Call !! Beispiel&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plural ===&lt;br /&gt;
Plural wird von Sprache zu Sprache unterschiedlich behandelt. Viele Sprachen haben einen unterschiedlichen Plural für 2, 10, 20, 100 usw. Wennn die Zeichenkette, die übersetzt werden soll sich auf mehr als ein Item beziehen kann, müssen Sie eine dritte Form von &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt; benutzen, nämlich &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. Die Funktion übernimmt die Singular- und Pluralversion in Englisch als erste beide Argumebnte, gefolgt von beliebigen Argumenten, die ersetzt werden sollen. Davon muß jedoch mindestens eines eine Ganzzahl sein. Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; wird enstrechend der in der Sprache des Benutzers notwenidigen Fälle erweitert. Im Englischen gibt es nur diese beiden Formen, während in anderen Sprachen mehrere existieren können, abhängig vom ersten Ganzzahlargument. &lt;br /&gt;
&lt;br /&gt;
Beachten Sie, dass diese Form auch dann benutzt werden sollte, wenn die Zeichenkeitte sich immer auf mehrere Items bezieht, da manche Sprachen auch in anderen Fällen Singular (typischerweise bei 21, 32, etc.) benutzen. Dieser Code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
ist daher falsch und sollte lauten:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Um neben Pluralangaben auch einen Kontext zu übergeben, benutzen Sie &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; wie in diesem Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Datum und Zahlen formatieren ==&lt;br /&gt;
&lt;br /&gt;
When dem Benutzer Zahlen angezeigt werden, muss Ihr Programm die richtigen Dezimaltrennzeichen, Tausendertrennzeichen und Währungssymbol (falls überhaupt) darstellen. Diese Sysmbole unterschieden sich von Region zu Region. In englischsprachigen Ländern wird ein Punkt (.) benutzt um den gebrochenen Teil einer Zahl anzuzeigen (z.B. 12.5), während einige europäische Länder ein Komma (,) benutzen (z.B. 12,5). Es folgt eine Tabelle, die die Funktionen zusammenfasst, die Ihnen dabei hilft, diese lokalen Konventionen korrekt zu behandeln. &lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Funktionen um Zahlen zu formatieren&lt;br /&gt;
|-&lt;br /&gt;
! Formatiert&amp;amp;nbsp;ein(e).. !! Von&amp;amp;nbsp;einem.. !! Funktions&amp;amp;nbsp;Prototyp&lt;br /&gt;
|-&lt;br /&gt;
| Zahl || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Zahl || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Währung || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Währung || Zahl || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Datum || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Uhrzeit || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Datum&amp;amp;nbsp;und&amp;amp;nbsp;Uhrzeit || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
&lt;br /&gt;
Ähnliche Funktionen existieren umd Informationen zu lesen, die der Benutzer zur Laufzeit in seinem lokalisierten Format eingibt, z.B. readNumber() oder readMoney().&lt;br /&gt;
&lt;br /&gt;
== Kalender ==&lt;br /&gt;
&lt;br /&gt;
Applikationen zu entwickeln, die sich mit Datum und Zeit beschäftigen, zum Beispiel Kalender, ist ein sehr komplexes Gebiet. Nicht nur Zeichenketten die ein Datum oder eine Uhrzeit beinhalten müssen lokal angepasst werden, man muss auch andere Aspekte bedenken, wie zum Beispiel:&lt;br /&gt;
* Welcher Dag in der Woche der erste ist (cf int weekStartDay())&lt;br /&gt;
* Wieviele Monate in einem Jahr sind&lt;br /&gt;
* &amp;quot;Ära&amp;quot;-basierte Kalender&lt;br /&gt;
* Ob ein 24-Stunden Zeitformat benutzt wird (cf bool use12Clock())&lt;br /&gt;
&lt;br /&gt;
KLocale stellt neben anderen diese Methoden zur verfügung:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Kalenderdaten Funktionen&lt;br /&gt;
|-                &lt;br /&gt;
! Formatiert&amp;amp;nbsp;ein(e).. !! von&amp;amp;nbsp;einem.. !! Funktions Prototyp&lt;br /&gt;
|-&lt;br /&gt;
| Datum || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Uhrzeit || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Datum&amp;amp;nbsp;und&amp;amp;nbsp;Uhrzeit || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Mehr Informationen für verschiedene Kalendersysteme geben}}&lt;br /&gt;
&lt;br /&gt;
== Häufige Fallen vermeiden ==&lt;br /&gt;
Es gibt eine Reihe von häufigen Problemen die es unmöglich machen, eine Applikation angemessen zu lokalisieren. Im nächsten Kapitel [[../i18n Mistakes (de)|Häufige Fehler in der Lokalisation vermeiden]] lernen Sie mehr darüber und wie man solche Fehler vermeidet.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Dank geht an Lukáš Tinkl, Matthias Kiefer und Gary Cramblitt für die Originalversion dieser Anleitung.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/KDE_TechBase:Contributors</id>
		<title>KDE TechBase:Contributors</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/KDE_TechBase:Contributors"/>
				<updated>2007-12-21T12:36:02Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* German Team */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;Welcome to the contributors page.&lt;br /&gt;
&lt;br /&gt;
'''This site contains a list of ''active'' contributors. It should help to build teams which maintain KDE TechBase's content. If you have questions about KDE TechBase you can ask/email the corresponding person.'''&lt;br /&gt;
&lt;br /&gt;
Please add yourself to the list where appropriate. If you are inactive, please remove yourself again.&lt;br /&gt;
&lt;br /&gt;
== Administrators ==&lt;br /&gt;
&lt;br /&gt;
This is a list of KDE TechBase administrators.&lt;br /&gt;
&lt;br /&gt;
* [[User:Danimo|Danimo]]&lt;br /&gt;
* [[User:Dhaumann|Dhaumann]], &amp;lt;dhaumann at kde dot org&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Reviewers and Article Writers ==&lt;br /&gt;
&lt;br /&gt;
If you are continuously reviewing KDE TechBase changes or writing articles add yourself to the list.&lt;br /&gt;
&lt;br /&gt;
* [[User:Dhaumann|Dhaumann]], &amp;lt;dhaumann at kde dot org&amp;gt;&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Translation Teams ==&lt;br /&gt;
&lt;br /&gt;
KDE TechBase is [[Help:Wiki Translation|translated]] into many languages. If you translate pages please add yourself to the right translation team.&lt;br /&gt;
&lt;br /&gt;
=== German Team ===&lt;br /&gt;
* DrSlowDecay, kde at metalhorde dot de&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== ... Team ===&lt;br /&gt;
* name, &amp;lt;email&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)</id>
		<title>Development/Tutorials/Localization/i18n (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)"/>
				<updated>2007-12-21T12:30:38Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More Translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode (de)|Introduction to Unicode]] ist empfohlen wenn auch nicht notwendig|&lt;br /&gt;
&lt;br /&gt;
name=Beim Applikationen schreiben an die Lokalisation denken|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes (de)|Häufige Fehler vermeiden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Eine breite Schar an Benutzern und Entwicklern zu erreichen erfordert, dass Ihre Software übersetzt werden kann und sich auch anderweitig an sprachliche und kulturelle Gegebenheiten desjenigen anpassen kann, der Ihre Applikation benutzt. Das ist die Aufgabe von Lokalisation und diese Anleitung leitet Sie durch die grundlegenden Schritte, Ihre Applikation lokalisierungsfähig zu machen. &lt;br /&gt;
&lt;br /&gt;
== Was ist Internationalisation and Lokalisation? ==&lt;br /&gt;
&lt;br /&gt;
Internationalisation, oder i18n ('i', gefolgt von 18 Buchstaben und dann ein  'n'), bezeichnet den Prozess, Ihre Applikation so zu schreiben, dass sie in jeder beliebigen Sprache und Kultur laufen kann. Dabei müssen folgende Dinge berücksichtigt werden:&lt;br /&gt;
* Textmitteilungen, die dem Benutzer mitgeteilt werden&lt;br /&gt;
* Dateneingabe vom Benutzer, Dateien und anderen Quellen&lt;br /&gt;
* Das Format von Datum, Zahlen, Währungen, etc. &lt;br /&gt;
&lt;br /&gt;
Lokalisation, oder l10n ('l' gefolgt von 10 Zeichen und dann ein 'n') ist der Prozess, eine internationalisierte Applikation an bestimmte lokale Gegebenheiten anzupassen.&lt;br /&gt;
&lt;br /&gt;
Im allgemeinen internationalisieren Programmierer ihre Applikationen und Übersetzerteams lokalisieren sie. &lt;br /&gt;
&lt;br /&gt;
== Warum ist das wichtig? ==&lt;br /&gt;
&lt;br /&gt;
KDE Entwicklung findet primär in Englisch statt, da dies eine breite Entwickler- und Übersetzerschaft erreicht. Englisch ist jedoch nicht die Muttersprache der meisten Menschen auf der Welt. Tatsächlich sprechen weniger als 8% der Menschheit Englisch und weniger als 5% sprechen es als Muttersprache. Auch im Internet benutzen nur 35% der Menschen die online sind Englisch als primäre Sprache und je mehr Teile der Welt an das Internet angeschlossen werden, desto geringer wird dieser Anteil werden. Zusätzlich benutzen die meisten sprachen, alleine 9 der 10 häufigsten, nicht-ASCII Zeichen in ihrer geschriebenen Form. Daher ist es einfach zu erkennen, warum es notwendig ist, Software zu lokalisieren. &lt;br /&gt;
&lt;br /&gt;
Als internationales Projekt das den gesamten Globul umspannt, ist diese Lokalisation ein wichtiges Gut der KDE Kultur. Tatsächlich entwickeln viele KDE Entwickler ihre Applikationen in Englisch benutzen jedoch ihren KDE-Desktop in der jeweils lokalisierten Version.&lt;br /&gt;
&lt;br /&gt;
== Übersetzbaren Code mit i18n() ==&lt;br /&gt;
Um sicherzustellen, dass Ihre Applikation für eine Lokalisation vorbereitet ist, müssen Sie einigen wenigen einfachen Regeln folgen. Alle für Benutzer sichtbaren Zeichenketten Ihrer Applikation sollten übersetzt werden, bevor Sie auf dem Bildschirm des Benutzers dargestellt werden, ausgenommen davon sind Debug-Ausgaben, Konfigurationsdaten und andere ähnliche Textdaten. &lt;br /&gt;
&lt;br /&gt;
KDE stellt als Teil von &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; die Klasse {{Class|KLocale}} zur Verfügung, um die technischen Aspekte der Lokalisierung zu erledigen. KLocale macht es Entwicklern so einfach wie möglich, ihren Code i18n fähig zu machen, dennoch bleiben einige Dinge, die Sie als Entwickler beachten müssen, damit die Applikation in anderen Sprachen und Ländern eingesetzt werden kann.&lt;br /&gt;
&lt;br /&gt;
Zugriff auf das globale &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; Objekt wird über &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt; zur Verfügung gestellt. Dieses &amp;lt;tt&amp;gt;Klocale&amp;lt;/tt&amp;gt; Objekt wird automatisch von {{Class|KInstance}} erzeugt und kümmert sich um alle i18n betreffenden Einstellungen. Beim Verlassen der Applikation wird das Objekt automatisch gelöscht. &lt;br /&gt;
&lt;br /&gt;
Übersetzungen werden von der i18n(const char*) Methode von {{Qt|QString}} ermöglicht, definiert in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;. Darin müssen alle Zeichenketten, die dargestellt werden, eingebettet werden. Der von &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; zurückgegebene QString ist die (wenn nötig) übersetze Zeichenkette. Dadurch werden übersetzbare Widgets so einfach möglich, wie das nachfolgende Beispiel zeigt:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Die native Unicode-Unterstützung von QString stellt sicher, das alle Übersetzungen richtig dargestellt werden. Alle Zeichenkettenbehandlungen Ihrer Applikation sollten daher QString benutzen.&lt;br /&gt;
&lt;br /&gt;
{{tip|Wenn die Zeichenkette, die übersetzt werden soll, irgendwelche nicht-UTF8 Zeichen enthält, benutzen Sie die Methode utf8() um ein char* zu erhalten.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
Die &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; Methoden benötigt ein existierendes {{Class|KInstance}} (z.B. ein {{Class|KApplication}}) Objekt. Für Zeichenketten die vor der Erzeugung erstellt werden muss eine andere Methode zur Verfügung gestellt werden: &amp;lt;tt&amp;gt;ki18n&amp;lt;/tt&amp;gt;. Diese erlaubt es, Zeichenketten zur späteren übersetzung zu markieren. ki18n() gibt ein {{Class|KLocalizedString}} zurück, welches letztlich in ein {{Qt|QString}} konvertiert wird (also schließlich übersetzt wird), nachdem KInstance erzeugt wurde. Dabei wird dessen toString() Methode benutzt. &lt;br /&gt;
&lt;br /&gt;
ki18n() wird typischerweise in Zeichenketten benutzt, die an {{Class|KAboutData}} übergeben werden, da dieses von {{Class|KApplication}} erzeugt wird. Außerhalb dieser Sonderfälle kann man immer ohne Bedenken i18n() benutzen, wenn man sicher ist, dass dieser Code ausgeführt nachdem KApplication oder eine andere {{Class|KInstance}} konstruiert wurde.&lt;br /&gt;
&lt;br /&gt;
=== Kontext hinzufügen ===&lt;br /&gt;
&lt;br /&gt;
There is an extended version of &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; which takes two &amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; arguments. The first argument is an additional contextual description of the second string which will be translated. The first  string is used to find the proper corresponding translation at run-time and is shown to translators to help them understand the meaning of the string. &lt;br /&gt;
&lt;br /&gt;
Use &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; whenever the purpose of the text might be ambiguous without further context. For example, consider a context menu in a file manager with an entry called &amp;quot;View&amp;quot; which opens a viewer for the currently selected file. In this context &amp;quot;View&amp;quot; is a verb. However, the same application also may have a menu called &amp;quot;View&amp;quot; in the menubar. In that context &amp;quot;View&amp;quot; is a noun. In the English version of the application everything looks fine, but in most other languages one of the two &amp;quot;View&amp;quot; strings will be incorrect.&lt;br /&gt;
&lt;br /&gt;
Additionally, translators sometimes need extra help in understanding what the text is actually referring to during the translation process.&lt;br /&gt;
&lt;br /&gt;
In the file manager example above, one might therefore write:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now the two strings will be properly translatable, both by the human translators and at runtime by KLocale.&lt;br /&gt;
&lt;br /&gt;
Use this form of i18n whenever the string to translate is short or the meaning is hard to discern when the context is not exactly known. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note (de)|There is also a ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) method for providing context to strings which are constructed before the KInstance. It returns a KLocalizedString, so use the toString() method afterwards to convert it into a QString.}}&lt;br /&gt;
&lt;br /&gt;
Contexts can also be added when building forms in Qt Designer. Each widget label, including tooltips and whatsthis texts, has a &amp;quot;comment&amp;quot; attribute, which will serve the same purpose as first argument to &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; call.&lt;br /&gt;
&lt;br /&gt;
=== Standard Kontext für häufige Ausdrücke ===&lt;br /&gt;
&lt;br /&gt;
Below is a chart showing some common words and phrases in English and the context that must be used with them to ensure proper translation of them in other languages.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Contexts&lt;br /&gt;
|-&lt;br /&gt;
! Phrase !! Context !! i18nc Call !! Example&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plural ===&lt;br /&gt;
&lt;br /&gt;
Plurals are handled differently from language to language. Many languages have different plurals for 2, 10, 20, 100, etc. When the string you want translated refers to more than one item, you must use the third form of &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt;,  the &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. It takes the singular and plural English forms as its first two arguments, followed by any substitution arguments as usual, but at least one of which should be integer-valued. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; gets expanded to as many cases as required by the user's language. In English, this is just two forms while in other languages it may be more, depending on the value of the first integer-valued argument.&lt;br /&gt;
&lt;br /&gt;
Note that this form should be used even if the string always refers to more than one item as some languages use a singular form even when referring to a multiple (typically for 21, 31, etc.). This code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
is therefore incorrect and should instead be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To provide context as well as pluralization, use &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Datum und Zahlen formatieren ==&lt;br /&gt;
&lt;br /&gt;
When displaying a number to the user, your program must take care of the decimal separator, thousand separator and currency symbol (if any) being used. These symbols differ from region to region. In English speaking countries a dot (.) is used to separate the fractional part of a number, while in some European countries a comma (,) is used instead. Below is a short summary of functions that will help you format the numbers correctly, taking the local conventions into account for you.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Functions to Format Numbers&lt;br /&gt;
|-&lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function&amp;amp;nbsp;Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Number || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Number || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || Number || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
 &lt;br /&gt;
Similar functions exist to read information provided by the user at runtime in their localized format, e.g. readNumber() or readMoney().&lt;br /&gt;
&lt;br /&gt;
== Kalender ==&lt;br /&gt;
&lt;br /&gt;
Applikationen zu entwickeln, die sich mit Datum und Zeit beschäftigen, zum Beispiel Kalender, ist ein sehr komplexes Gebiet. Nicht nur Zeichenketten die ein Datum oder eine Uhrzeit beinhalten müssen lokal angepasst werden, man muss auch andere Aspekte bedenken, wie zum Beispiel:&lt;br /&gt;
* Welcher Dag in der Woche der erste ist (cf int weekStartDay())&lt;br /&gt;
* Wieviele Monate in einem Jahr sind&lt;br /&gt;
* &amp;quot;Ära&amp;quot;-basierte Kalender&lt;br /&gt;
* Ob ein 24-Stunden Zeitformat benutzt wird (cf bool use12Clock())&lt;br /&gt;
&lt;br /&gt;
KLocale stellt neben anderen diese Methoden zur verfügung:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Kalenderdaten Funktionen&lt;br /&gt;
|-                &lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Date || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Mehr Informationen für verschiedene Kalendersysteme geben}}&lt;br /&gt;
&lt;br /&gt;
== Häufige Fallen vermeiden ==&lt;br /&gt;
Es gibt eine Reihe von häufigen Problemen die es unmöglich machen, eine Applikation angemessen zu lokalisieren. Im nächsten Kapitel [[../i18n Mistakes (de)|Häufige Fehler in der Lokalisation vermeiden]] lernen Sie mehr darüber und wie man solche Fehler vermeidet.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Dank geht an Lukáš Tinkl, Matthias Kiefer und Gary Cramblitt für die Originalversion dieser Anleitung.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Common_Programming_Mistakes_(de)</id>
		<title>Development/Tutorials/Common Programming Mistakes (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Common_Programming_Mistakes_(de)"/>
				<updated>2007-12-21T11:17:28Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Iteratoren */ Changed template to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Common Programming Mistakes}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Grundlagen|&lt;br /&gt;
&lt;br /&gt;
name=Häufige Programmierfehler|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
Diese Anleitung gibt ein paar Tips aus dem Erfahrungsschatz von KDE Entwicklern bezüglich was man in Qt und KDE machen und was lieber sein lassen sollte. Neben aktuellen Fehler behandelt es auch Dinge, die nicht unbedingt als Fehler gelten jedoch den Code langsamer oder weniger lesbar machen. &lt;br /&gt;
&lt;br /&gt;
== C++ allgemein==&lt;br /&gt;
Dieses Kapitel beschäftigt sich mit einigen dunklen Ecken von C++, die gerne falsch benutzt oder schlicht und einfach falsch verstanden werden.&lt;br /&gt;
&lt;br /&gt;
=== Anonyme Namensräume vs. statics ===&lt;br /&gt;
Wenn Sie eine Methode in einer Klasse haben, die nicht auf Members zugreift und daher kein Objekt zu seiner Arbeit benötigt, machen Sie es static. Wenn diese Methode dann zusätzlich nur eine private Hilfsfunktion ist, welche außerhalb dieser Datei nicht benötigt wird, machen Sie daraus eine file-static Funktion, dadurch wird das Symbol komplett verborgen.&lt;br /&gt;
&lt;br /&gt;
Symbole die in C++ in einem anonymen Namensraum definiert werden, haben keine interne Verknüpfung. Anonyme Namensräume vergeben nur einen eindeutigen Namen für diese Übersetzungseinheit und das ist alles. Die Verknüpfung des Symbols wird überhaupt nicht verändert, weil die zweite Phase einer zwei-Phasen Namenssuche Funktionen mit interner Verknüfung ignoriert. Weiterhin können Elemente mit interner Verknüpfung nicht als Argumente für Templates benutzt werden.&lt;br /&gt;
&lt;br /&gt;
Wenn Sie also nicht wollen, dass ein Symbol exportiert wird, benutzen Sie statt anonymen Namensräumen statische. &lt;br /&gt;
&lt;br /&gt;
=== NULL Zeiger Probleme ===&lt;br /&gt;
Als erstes und wichtigstes: Es ist OK einen Null Zeiger zu löschen. Daher sind Konstrukte, die einen Zeiger auf Null testen reduntant:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
if ( ptr ) {&lt;br /&gt;
   delete ptr;&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Beachten Sie jedoch, dass '''ein Null-Check erforderlich ''ist'', wenn Sie ein Array löschen''' - das liegt daran, dass ein relativ neuer Compiler auf Solaris-Systemen das anderweitig nicht richtig behandelt. &lt;br /&gt;
&lt;br /&gt;
Wenn Sie einen Zeiger löschen, stellen Sie sicher, dass sie ihn auf 0 setzen, so dass zukünftige Löschversuche nicht mit einer doppelten Löschung fehlschlagen. Der entsprechende Code dazu:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
delete ptr; &lt;br /&gt;
ptr = 0;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Ihnen mag aufgefallen sein, dass Null-Zeiger auf eine von drei Arten bezeichnet werden können: 0, 0L und NULL. In C ist NULL als null void Zeiger definiert. In C++ ist dies jedoch nicht möglich aufgrund einer strengeren Typprüfung. Daher definieren moderne C++ Implementationen eine &amp;quot;magische&amp;quot; Null-Zeiger Konstante, die einem beliebigen Zeiger zugewiesen werden kann. Ältere C++ Implementationen definierten es einfach als 0L oder 0, was keine zusätzliche Typsicherheit bietet - man könnte es einer Integervariable zuweisen, was offensichtlich falsch ist. &lt;br /&gt;
&lt;br /&gt;
Bei Zeigern bedeutet die Integerkonstante Null &amp;quot;Null-Zeiger&amp;quot; - unabhängig von der aktuellen Binärdarstellung eines Null-Zeigers. Daher ist die Entscheidung zwischen 0, 0L und NULL eine Frage des persönlichen Stils und der Gewohnheit statt technischer Gegebenheiten - was den Code in KDE's SVN betrifft, werden Sie mehr 0 als NULL verwendet sehen.&lt;br /&gt;
&lt;br /&gt;
Beachten Sie jedoch, das wenn Sie eine Null-Zeiger Konstante an eine Funktion mit variabler Parameterliste übergeben, Sie diese explizit in eine Zeiger-Variable ändern müssen - der Compiler nimmt per Voreinstellung den Integerkontext an, was möglicherweise nicht der Binärdarstellung eines Null-Zeigers entspricht. Wieder ist es egal, ob Sie 0, 0L oder NULL verwenden, im Allgemeinen wird die kürzere Darstellung bevorzugt. &lt;br /&gt;
&lt;br /&gt;
=== Member Variablen ===&lt;br /&gt;
Sie werden vielleicht vier Hauptstile bemerkt haben, wie in KDE-Klassen Member-Variablen benannt werden:&lt;br /&gt;
&lt;br /&gt;
* '''m_variable''' kleines m, Unterstrich und der Name der Variable mit einem Kleinbuchstaben am Anfang. Das ist der am meisten verwendete Stil und wird im Code von kdelibs bevorzugt. &lt;br /&gt;
* '''mVariable''' kleines m und der Name der Variable mit einem Großbuchstaben am Anfang&lt;br /&gt;
* '''variable_''' Name der Variable mit einem Kleinbuchstaben am Anfang und variable einem Unterstrich am Ende&lt;br /&gt;
* '''_variable''' Unterstrich und der Name der Variable mit einem Kleinbuchstaben am Anfang. Dieser Stil wird nicht so gerne gesehen, da diese Notation auch in Code für Funktionsparameter verwendet wird. &lt;br /&gt;
&lt;br /&gt;
Wie immer gibt es nicht nur einen korrekten Weg es zu machen, so folgen Sie einfach der Syntax der Applikation/Bibliothek zu welcher Sie Code ergänzen. &lt;br /&gt;
&lt;br /&gt;
=== Static variablen ===&lt;br /&gt;
&lt;br /&gt;
Versuchen Sie die Anzahl der static Variablen in Ihrem Code zu limitieren, besonders wenn Sie an einer Bibliothek arbeiten. Konstruktion und Initialisierung einer großen Anzahl von static Variablen kann die Startzeit stark verlängern. &lt;br /&gt;
&lt;br /&gt;
Benutzen Sie keine class-static Variablen, besonders nicht in Bibliotheken und ladbaren Modulen obwohl es sogar in Applikationen nicht empfohlen wird. Static Objekte führen zu einer Menge Problemen wie schwer zu verolgende Abstürze wegen einer undefinierten Reihenfolge des Konstruktion/Destruktion.&lt;br /&gt;
&lt;br /&gt;
Benutzen Sie stattdessen einen static Zeiger, zusammen mit &amp;lt;tt&amp;gt;K_GLOBAL_STATIC&amp;lt;/tt&amp;gt; welches in &amp;lt;tt&amp;gt;kglobal.h&amp;lt;/tt&amp;gt; definiert wird und wie folgt benutzt wird:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
class A { ... };&lt;br /&gt;
&lt;br /&gt;
K_GLOBAL_STATIC(A, globalA)&lt;br /&gt;
&lt;br /&gt;
void doSomething()&lt;br /&gt;
{&lt;br /&gt;
     A *a = globalA;&lt;br /&gt;
     ...&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void doSomethingElse()&lt;br /&gt;
{&lt;br /&gt;
    if (globalA.isDestroyed()) {&lt;br /&gt;
        return;&lt;br /&gt;
    }&lt;br /&gt;
    A *a = globalA;&lt;br /&gt;
    ...&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void installPostRoutine()&lt;br /&gt;
{&lt;br /&gt;
    qAddPostRoutine(globalA.destroy);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Sehen Sie auch [http://www.englishbreakfastnetwork.org/apidocs/apidox-kde-4.0/kdelibs-apidocs/kdecore/html/kglobal_8h.html#75ca0c60b03dc5e4f9427263bf4043c7 API Dokumentation] für &amp;lt;tt&amp;gt;K_GLOBAL_STATIC&amp;lt;/tt&amp;gt;, um weitere Informationen zu erhalten.&lt;br /&gt;
&lt;br /&gt;
=== Forward Deklarationen ===&lt;br /&gt;
&lt;br /&gt;
Die Übersetzungszeit kann reduziert werden, indem man Klassen ''forward'' deklariert anstatt den entsprechenden Header einzubinden. Ein Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;QWidget&amp;gt;     // langsam&lt;br /&gt;
#include &amp;lt;QStringList&amp;gt; // langsam&lt;br /&gt;
#include &amp;lt;QString&amp;gt;     // langsam&lt;br /&gt;
class SomeInterface&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    virtual void widgetAction( QWidget *widget ) =0;&lt;br /&gt;
    virtual void stringAction( const QString&amp;amp; str ) =0;&lt;br /&gt;
    virtual void stringListAction( const QStringList&amp;amp; strList ) =0;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;  &lt;br /&gt;
  &lt;br /&gt;
Das obige sollte statt dessen folgendermaßen formuliert werden:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
class QWidget;     // schnell&lt;br /&gt;
class QStringList; // schnell&lt;br /&gt;
class QString;     // schnell&lt;br /&gt;
class SomeInterface&lt;br /&gt;
{&lt;br /&gt;
public:&lt;br /&gt;
    virtual void widgetAction( QWidget *widget ) =0;&lt;br /&gt;
    virtual void stringAction( const QString&amp;amp; str ) =0;&lt;br /&gt;
    virtual void stringListAction( const QStringList&amp;amp; strList ) =0;&lt;br /&gt;
};&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Iteratoren ===&lt;br /&gt;
Bevorzugen Sie &amp;lt;tt&amp;gt;const_iterators&amp;lt;/tt&amp;gt; vor normalen Iterationen wann immer es möglich ist.&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Einige Abschnitte in diesem Kapitel konnte ich leider nicht übersetzen.}}&lt;br /&gt;
&lt;br /&gt;
Containers, which are being implicitly shared often detach when a call to a non-const &amp;lt;tt&amp;gt;begin()&amp;lt;/tt&amp;gt; or &amp;lt;tt&amp;gt;end()&amp;lt;/tt&amp;gt; methods is made ({{qt|List}} ist ein Beispiel eines solchen Containers). &lt;br /&gt;
&lt;br /&gt;
Wenn Sie einen const_iterator benutzen, achten Sie auch darauf, wirklich die const-Version von &amp;lt;tt&amp;gt;begin()&amp;lt;/tt&amp;gt; und &amp;lt;tt&amp;gt;end()&amp;lt;/tt&amp;gt; aufzurufen. &lt;br /&gt;
&lt;br /&gt;
Unless your container is actually const itself this probably will not be the case, possibly causing an unnecessary detach of your container. So basically whenever you use const_iterator initialize them using &amp;lt;tt&amp;gt;constBegin()&amp;lt;/tt&amp;gt;/&amp;lt;tt&amp;gt;constEnd()&amp;lt;/tt&amp;gt; instead, to be on the safe side. &lt;br /&gt;
&lt;br /&gt;
Speichern Sie den Rückgabewert des &amp;lt;tt&amp;gt;end()&amp;lt;/tt&amp;gt; Methodenaufrufs zwischen bevor Sie eine Iteration in großen Containern ausführen. Zum Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QValueList&amp;lt;SomeClass&amp;gt; container;&lt;br /&gt;
&lt;br /&gt;
//Code, der eine große Anzahl von Elementen in den Container einfügt.&lt;br /&gt;
&lt;br /&gt;
QValueListConstIterator end( container.end() );&lt;br /&gt;
&lt;br /&gt;
for ( QValueListConstIterator itr( container.begin() );&lt;br /&gt;
     itr != end; ++itr ) {&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Dadruch wird die unnötige Erzeugung eines temporären Rückgabe Objektes für &amp;lt;tt&amp;gt;end()&amp;lt;/tt&amp;gt; in jedem Schleifendurchlauf vermieden und dadurch die Ausführung beschleunigt.&lt;br /&gt;
&lt;br /&gt;
Prefer to use pre-increment over post-increment operators on iterators as this avoids creating an unnecessary temporary object in the process.&lt;br /&gt;
&lt;br /&gt;
'''Seien Sie vorsichtig wenn Sie Elemente innerhalb einer Schleife löschen'''&lt;br /&gt;
&lt;br /&gt;
Wenn Sie einige Elemente aus der Liste löschen wollen, könnten Sie vielleicht einen Code wie folgenden benutzen wollen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QMap&amp;lt;int, Job *&amp;gt;::iterator it = m_activeTimers.begin();&lt;br /&gt;
QMap&amp;lt;int, Job *&amp;gt;::iterator itEnd = m_activeTimers.end();&lt;br /&gt;
&lt;br /&gt;
for( ; it!=itEnd ; ++it )&lt;br /&gt;
{&lt;br /&gt;
    if(it.value() == job)&lt;br /&gt;
    {&lt;br /&gt;
        //A timer for this job has been found. Let's stop it.&lt;br /&gt;
        killTimer(it.key());&lt;br /&gt;
        m_activeTimers.erase(it);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Dieser Code wird eventuell wegen eines hängenden Iterators nach dem Aufruf von erase() einen Crash erzeugen. &lt;br /&gt;
Sie müssen den Code folgendermaßen umschreiben:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QMap&amp;lt;int, Job *&amp;gt;::iterator it = m_activeTimers.begin();&lt;br /&gt;
while (it != m_activeTimers.end())&lt;br /&gt;
{&lt;br /&gt;
    QMap&amp;lt;int, Job *&amp;gt;::iterator prev = it;&lt;br /&gt;
    ++it;&lt;br /&gt;
    if(prev.value() == job)&lt;br /&gt;
    {&lt;br /&gt;
        //A timer for this job has been found. Let's stop it.&lt;br /&gt;
        killTimer(prev.key());&lt;br /&gt;
        m_activeTimers.erase(prev);&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Dieses Problem wird auch in [http://doc.trolltech.com/4.3/qmap-iterator.html#details Qt documentation for QMap::iterator] diskutiert, trifft aber auf alle Qt Iteratoren zu.&lt;br /&gt;
&lt;br /&gt;
== Programm Design ==&lt;br /&gt;
In diesem Abschnitt beschäftigen wir uns mit einigen allgemeinen Problemen im Zusammenhang mit den Design von Qt/KDE Applikationen.&lt;br /&gt;
&lt;br /&gt;
=== Verspätete Initialisierung ===&lt;br /&gt;
Obwohl das Design von modernen C++ Applikationen sehr komplex sein kann, ist ein immer wieder auftretendes Problem - was jedoch leicht zu beheben ist - die Tatsache nicht die Technik der [http://www.kdedevelopers.org/node/view/509 verspäteten Initialisierung] zu benutzen. &lt;br /&gt;
&lt;br /&gt;
Zunächst sehen wir uns den Standardweg einer Initialisierung einer KDE Applikation an:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
int main( int argc, char **argv )&lt;br /&gt;
{&lt;br /&gt;
    ....&lt;br /&gt;
    KApplication a;&lt;br /&gt;
&lt;br /&gt;
    KCmdLineArgs *args = KCmdLineArgs::parsedArgs();&lt;br /&gt;
&lt;br /&gt;
    MainWindow *window = new MainWindow( args );&lt;br /&gt;
&lt;br /&gt;
    a.setMainWidget( window );&lt;br /&gt;
    window-&amp;gt;show();&lt;br /&gt;
&lt;br /&gt;
    return a.exec();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Beachten Sie, dass &amp;lt;tt&amp;gt;window&amp;lt;/tt&amp;gt; vor dem Aufruf von &amp;lt;tt&amp;gt;a.exec()&amp;lt;/tt&amp;gt;, der die Ereignisschleife startet, erzeugt wird. Das bedeutet, dass wir es vermeiden sollten, nicht-triviales im obersten Konstruktor durchzuführen, da dieser Läuft bevor das Fenster überhaupt dargestellt werden kann.&lt;br /&gt;
&lt;br /&gt;
Die Lösung ist einfach: Wir müssen die Konsruktion von Dingen außer der GUI solange verzögern, bis die Ereignisschleife startet. Hier ist ein Beispiel, wie der Konstruktor eines MainWindows aussehen sollte, um das zu erreichen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
MainWindow::MainWindow()&lt;br /&gt;
{&lt;br /&gt;
    initGUI();&lt;br /&gt;
    QTimer::singleShot( 0, this, SLOT(initObject()) );&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::initGUI()&lt;br /&gt;
{&lt;br /&gt;
    /* Erzeugen Sie Ihre Widgets hier. Beachten Sie das die Widgets&lt;br /&gt;
     * die Sie hier erzeugen, keine komplexe Initialisierung beötigen sollten&lt;br /&gt;
     * da ansonsten die Ganze Aktion nicht viel Sinn macht. Alles was&lt;br /&gt;
     * hier geschehen sollte, ist die Erzeugung der GUI Objekte und das&lt;br /&gt;
     * Verknüfen via QObject::connect der entsprechenden Signals mit deren  &lt;br /&gt;
     * Slots&lt;br /&gt;
     */&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::initObject()&lt;br /&gt;
{&lt;br /&gt;
    /* Dieser Slot wird aufgrufen sobald die Ereignisschleife startet. &lt;br /&gt;
     * Implementieren Sie hier alles was sonst noch getan werden muss,&lt;br /&gt;
     * inklusive dem Wiederherstellen von Werten, dem Lesen von Dateien, &lt;br /&gt;
     * Wiederherstellung von Sitzungen, etc. &lt;br /&gt;
     * Das wird immer noch eine Zeit dauern, aber wenigstens ist Ihr &lt;br /&gt;
     * Fenster in dieser Zeit sichtbar und so macht die Applikation&lt;br /&gt;
     * einen aktiven Eindruck.&lt;br /&gt;
     */&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Diese Technik gibt ihnen keinen Zeitvorteil (es läuft nichts schneller dadurch), aber die Applikation macht für den Benutzer den Eindruck, als würde sie schneller starten. Das wird dadurch bewerkstelligt, dass der Benutzer eine schnelle Antwort auf das starten der Applikation erhält. &lt;br /&gt;
   &lt;br /&gt;
Wenn (und nur dann) der Start nicht in einem vernünftigen Zeitrahmen erfolgen kann, überlegen Sie sich, ein {{class|KSplashScreen}} einzusetzen.&lt;br /&gt;
&lt;br /&gt;
== Daten Strukturen ==&lt;br /&gt;
&lt;br /&gt;
In this section we will go over some of our most common pet-peeves which affect data structures very commonly seen in Qt/KDE applications.&lt;br /&gt;
&lt;br /&gt;
=== non-POD typen übergeben ===&lt;br /&gt;
&lt;br /&gt;
Nicht-POD (&amp;quot;plain old data&amp;quot;) Typen sollten als const Referenz übergeben werden, wann immer das möglich ist. Das beinhaltet alle Datentypen außer &amp;lt;tt&amp;gt;char&amp;lt;/tt&amp;gt; und &amp;lt;tt&amp;gt;int&amp;lt;/tt&amp;gt;.&lt;br /&gt;
&lt;br /&gt;
Nehemen Sie zum Beispiel {{qt|QString}}. Diese sollten als Parameter an Methoden immer als &amp;lt;tt&amp;gt;const {{qt|QString}}&amp;amp;&amp;lt;/tt&amp;gt; übergeben werden. Auch wenn {{qt|QString}} implicitly shared ist, ist das immer noch effizienter (und sicherer) es als const Referenz zu übergeben statt als Wert.&lt;br /&gt;
&lt;br /&gt;
So allgemein sollte eine Methode, die QString als Argument nimmt, so aussehen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
void myMethod( const QString &amp;amp; foo, const QString &amp;amp; bar );&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== QObject ===&lt;br /&gt;
Sollten Sie jemals eine von QObject abgeleitete Klasse aus den eigenen Methoden heraus löschen sollen, löschen Sie es ''nicht'' folgendermaßen:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
   delete this;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Das wird früher oder später in einen Absturz führen, da eine Methode dieses Objektes aus der Qt-Ereignisschleife heraus via slots/signals aufgerufen werden könnte, nachdem Sie es gelöscht haben.&lt;br /&gt;
&lt;br /&gt;
Nutzen Sie statt dessen immer &amp;lt;tt&amp;gt;{{qt|QObject}}::deleteLater()&amp;lt;/tt&amp;gt;, was das gleiche wie &amp;lt;tt&amp;gt;delete this&amp;lt;/tt&amp;gt; erledigt jedoch in einer sicheren Art und Weise.&lt;br /&gt;
&lt;br /&gt;
=== Leere QStrings ===&lt;br /&gt;
Häufig muss geprüft werden, ob ein {{qt|QString}} leer ist. Hier sind drei Ansätze das zu prüfen, wobei nur die ersten beiden korrekt sind:&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
// Richtig&lt;br /&gt;
if ( mystring.isEmpty() ) {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
// Richtig&lt;br /&gt;
if ( mystring == QString() ) {&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
// Falsch! &amp;quot;&amp;quot;&lt;br /&gt;
if ( mystring == &amp;quot;&amp;quot; ) {&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Obwohl es ein Unterschied zwischen &amp;quot;null&amp;quot; {{qt|QString}}s und leeren gibt, ist das nur ein historisches Artefakt, neuer Code sollte das nicht mehr benutzen.&lt;br /&gt;
&lt;br /&gt;
=== QString und das Lesen aus Dateien ===&lt;br /&gt;
Wenn Sie aus einer Datei lesen, ist es schneller, in einem Rutsch von der lokalen Verschlüsselung nach Unicode ({{qt|QString}}) zu konvertieren als zeilenweise. Das bedeutet, dass Methoden wie &amp;lt;tt&amp;gt;{{qt|QIODevice}}::readAll()&amp;lt;/tt&amp;gt; meist eine gute Lösung sind, gefolgt von einer einizigen {{qt|QString}} instantierung.&lt;br /&gt;
&lt;br /&gt;
Bei größeren Dateien sollte sich in Betracht ziehen, einen Block von Zeilen zu lesen und dann zu konvertieren. Auf diese Art und Weise haben Sie die Möglichkeit ihre GUI zu aktualisieren. Das kann bewekstelligt werden, indem Sie wieder in die Ereignisschleife eintreten und gleichteitig mittels eines Timers die Blöcke im Hintergrund lesen oder indem Sie eine lokale Ereignisschleife definieren. &lt;br /&gt;
&lt;br /&gt;
Man könnte auch &amp;lt;tt&amp;gt;qApp-&amp;gt;processEvents()&amp;lt;/tt&amp;gt; aufrufen, davon wird jedoch abgetraten, da es leicht zu zum Teil fatalen Problemen führt. &lt;br /&gt;
&lt;br /&gt;
=== QString aus einem KProcess lesen ===&lt;br /&gt;
{{class|KProcess}} löst das Signal &amp;lt;tt&amp;gt;readyReadStandard{Output|Error}&amp;lt;/tt&amp;gt; aus, sobald Daten eintreffen.&lt;br /&gt;
&lt;br /&gt;
Ein häufiger Fehler ist es, alle verfügbaren Daten im verbundenen Slot zu lesen und sofort in ein {{qt|QString}} zu konvertieren: Die Daten könnten in kleineren unregelmäßigen Portionen einreffen, daher könnten multi-byte Zeichen in Stücke geschnitten und daher ungültig werden. Mehrere Ansätze existieren:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;ul&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Müssen Sie die Daten wirklich sofort verarbeiten sobald sie eintreffen? Wenn nicht, benutzen Sie lieber &amp;lt;tt&amp;gt;readAllStandard{Output|Error}&amp;lt;/tt&amp;gt; nachdem der Prozess beendet wurde. Anders als in KDE3 ist KProcess nun in der Lage, die Daten zu sammeln.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Sammeln Sie die Datenbrocken im Slot und bearbeiten Sie sie immer dann, wenn ein Newline kommt oder ein bestimmter Timeout auftritt.[http://websvn.kde.org/branches/KDE/3.5/kdevelop/lib/widgets/processlinemaker.cpp?view=markup&amp;amp;rev=737977 Example code] (KDE3 based)&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;li&amp;gt;Fügen Sie den Prozess in ein {{qt|QTextStream}} ein und lesen Sie diesen zeilenweise. Während das zumindest theoretisch funktionieren sollte, funktioniert das in der Praxis derzeit '''nicht'''.&amp;lt;/li&amp;gt;&lt;br /&gt;
&amp;lt;/ul&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== QString und QByteArray ===&lt;br /&gt;
Während {{qt|QString}} das Werkzeug der Wahl für viele Situationen ist, in denen mit Zeichenketten gearbeitet wird, gibt es eine Situation, wo dies äußerst ineffizient ist. Wenn Sie mit Daten arbeitet, die in einem {{qt|QByteArray}} gespeichert sind, sehen Sie sich vor, dass Sie diese nicht an Methoden übergeben, die einen {{qt|QString}} Parameter benötigen und daraus wieder ein QByteArray macht.&lt;br /&gt;
&lt;br /&gt;
For example: &lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QByteArray myData;&lt;br /&gt;
QString myNewData = mangleData( myData );&lt;br /&gt;
&lt;br /&gt;
QString mangleData( const QString&amp;amp; data ) {&lt;br /&gt;
    QByteArray str = data.toLatin1();&lt;br /&gt;
    // mangle &lt;br /&gt;
    return QString(str);&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Der kostspielige Teil hier ist die Konvertierung nach {{qt|QString}}, was intern als Konvertierung in Unicode durchgeführt wird. Das ist unnötig, da das erste, was die Methode tut, eine Rückkonvertierung nach &amp;lt;tt&amp;gt;toLatin1()&amp;lt;/tt&amp;gt; ist. Wenn Sie sich also sicher sind, dass eine Unicode Konvertierung nicht bennötigt wird, versuchen sich Zwischenschritte mit QString zu vermeiden.&lt;br /&gt;
&lt;br /&gt;
Das obige Beispiel sollte statt dessen geschrieben werden als:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
QByteArray myData;&lt;br /&gt;
QByteArray myNewData = mangleData( myData );&lt;br /&gt;
&lt;br /&gt;
QByteArray mangleData( const QByteArray&amp;amp; data )&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== QDomElement ===&lt;br /&gt;
When ein XML Dokument geparst wird, benötigt man häufig eine Iteration über alle Elemente. Man könnte versucht sein, folgenden Code dafür zu benutzen:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
for ( QDomElement e = baseElement.firstChild().toElement();&lt;br /&gt;
      !e.isNull();&lt;br /&gt;
      e = e.nextSibling().toElement() ) {&lt;br /&gt;
       ...&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Das ist jedoch nicht korrekt: Die obige Schleife wird vorzeitig beendet wenn es auf einen {{qt|QDomNode}} trifft, der etwas anderes als ein Element ist (zum Beispiel ein Kommentar).&lt;br /&gt;
&lt;br /&gt;
Die korrekte Schleife sieht so aus:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
for ( QDomNode n = baseElement.firstChild(); !n.isNull();&lt;br /&gt;
      n = n.nextSibling() ) {&lt;br /&gt;
    QDomElement e = n.toElement();&lt;br /&gt;
    if ( e.isNull() ) {&lt;br /&gt;
        continue;&lt;br /&gt;
    }&lt;br /&gt;
    ...&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/KDE4_Porting_Guide_(de)</id>
		<title>Development/Tutorials/KDE4 Porting Guide (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/KDE4_Porting_Guide_(de)"/>
				<updated>2007-12-21T11:16:13Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* Qt Designer UI Dateien */ Adjusted template to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/KDE4_Porting_Guide}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Grundlagen|&lt;br /&gt;
&lt;br /&gt;
name=Anleitung zur Portierung nach KDE 4|&lt;br /&gt;
&lt;br /&gt;
pre=|&lt;br /&gt;
&lt;br /&gt;
next=[[Development/Tutorials/CMake (de)|Einführung in CMake]]| &lt;br /&gt;
&lt;br /&gt;
reading=[http://www.trolltech.com/products/qt/whatsnew/porting &amp;quot;Moving from Qt 3 to Qt 4&amp;quot;]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Einführung==&lt;br /&gt;
Diese Anleitung richtet sich an Entwickler, die ihre Qt3/KDE3 basierten Applikationen nach Qt4/KDE4 portieren wollen. Das muß nämlich kein komplizierter Prozess sein. Es gibt bereits viele Skripte und Dokumentationen, die dabei helfen.&lt;br /&gt;
&lt;br /&gt;
==Konventionen==&lt;br /&gt;
Für die Anweisungen dieser Anleitung gelten folgende Konventionen:&lt;br /&gt;
* {{program|program}} bezeichnet ein ausführbares Programm&lt;br /&gt;
* {{path|path}} bezeichnet einen Pfad&lt;br /&gt;
* {{path|file}} bezeichnet eine Datei&lt;br /&gt;
* $SVN ist der vollständige Pfad zu Ihrem KDE subversion depot. &lt;br /&gt;
&lt;br /&gt;
==CMake==&lt;br /&gt;
Anders als KDE4 werden KDE4 Applikationen mit der Hilfe von [[Development/Tutorials/CMake (de)| CMake]] erstellt. Der einfachste Weg die autotools Dateien nach CMake zu portieren ist, das Script {{program|am2cmake}} zu benutzen, welches im Verzeichnis {{path|cmake/scripts}} des [http://websvn.kde.org/trunk/KDE/kdesdk/ kdesdk] Modules zu finden ist. Das erzeugt eine Reihe von {{path|CMakeLists.txt}} Dateien neben den alten autotools Dateien.&lt;br /&gt;
&lt;br /&gt;
Ist Ihr Code zum Beispiel unter {{path|/path/to/src}} gespeichert, dann:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% cd /path/to/src&lt;br /&gt;
% $SVN/trunk/KDE/kdesdk/cmake/scripts/am2cmake --kde4&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Führen Sie &amp;lt;tt&amp;gt;am2cmake --help&amp;lt;/tt&amp;gt; aus, um zu prüfen, ob Sie das &amp;lt;tt&amp;gt;--kde4&amp;lt;/tt&amp;gt; Flag benötigen.&lt;br /&gt;
&lt;br /&gt;
Weiterhin gibt es ein Werkzeug, welches in den erzeugten {{path|CMakeList.txt}} Dateien nach möglichen Problemen sucht. Dieses Werkzeugt heißt {{program|cmakelint.pl}} und ist unter{{path|$SVN/trunk/kde/kdesdk/scripts}} gespeichert.  Benutzen Sie es folgendermaßen:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% cd /path/to/src&lt;br /&gt;
% $SVN/trunk/KDE/kdesdk/scripts/cmakelint.pl CMakeLists.txt&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Oder wenden Sie es auf das gesamte Quellcodevrzeichnis an:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% cd /path/to/src&lt;br /&gt;
% find . -name CMakeLists.txt | \&lt;br /&gt;
  xargs $SVN/trunk/KDE/kdesdk/scripts/cmakelint.pl&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Qt4 API==&lt;br /&gt;
Einen Überblick über den Übergang von Qt3 nach Qt4 wird in der Anleitung [http://www.trolltech.com/products/qt/whatsnew/porting &amp;quot;Moving from Qt 3 to Qt 4&amp;quot;] von Trolltech erläutert. Dieses Dokument bietet einen sehr guter Überblick über die Änderungen in der Funktionalität, die Qt4 mit sich bring und ist daher sehr zu empfehlen.&lt;br /&gt;
&lt;br /&gt;
Die nachfolgende Anleitung [http://doc.trolltech.com/latest/porting4.html &amp;quot;Porting to Qt 4&amp;quot;] gibt eine sehr detailierte Beschreibung des Portierungsprozesses, neben einer Liste von Änderungen in den Klassen und Funktionen.&lt;br /&gt;
&lt;br /&gt;
Diese Dokumente beschreiben auch ein Werkzeug, das von Trolltech zur Verfügung gestellt wird und sich {{program|qt3to4}} nennt. Dieses Programm kann dabei helfen, die Qt Teile Ihres Codes von Qt3 nach Qt4 zu portieren, indem es spezielle Funktionen zur Kompatibilität benutzt. Rufen Sie {{program|qt3to4}} folgendermaßen auf:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% $SVN/trunk/qt-copy/bin/qt3to4 [options] &amp;lt;Infile&amp;gt;, [Infile], ...&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Infile kann eine Quellcodedatei oder eine Projektdatei sein. Möchten Sie eine Projektdatei angeben (mit der Endung '.pro' oder '.pri'), {{program|qt3to4}} wird alle Dateien portieren, die in dieser Datei angegeben sind.&lt;br /&gt;
&lt;br /&gt;
Für mehr Informationen können Sie {{program|qt3to4}} mit der &amp;quot;--help&amp;quot; Option aufrufen oder unter [http://doc.trolltech.com/latest/qt3to4.html &amp;quot;qt3to4-The Qt 3 to 4 Porting Tool&amp;quot;] nachschlagen.&lt;br /&gt;
&lt;br /&gt;
Weiterhin gibt es ein Programm namens {{program|remove-qt3-support.pl}} im Modul {{module|kdesdk}}, welches nach vielen veralteten Qt3 Strukturen sucht und diese ersetzt. Rufen Sie einfach dieses Programm ohne weitere Optionen im Quellverzeichnis auf.&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% $SVN/trunk/KDE/kdesdk/scripts/qt4/remove-qt3-support.pl&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==KDE4 API==&lt;br /&gt;
Ein Großteil der Arbeit beim Portieren besteht einfach aus dem umbenennen von Klassen und Header-Dateien. Da es ziemlich ermüdend ist, dies von Hand zu machen, gibt es ein nützliches Script im {{path|scripts/qt4}} Verzeichnis des Modules {{module|kdesdk}} namens {{program|adapt-to-kde4-api.pl}}. Dieses scant alle Ihre Dateien und erzeugt eine {{program|diff}} Ausgabe, die dann benutzt werden kann, um Ihren Code zu patchen. &lt;br /&gt;
&lt;br /&gt;
Wenn diese einfache Codeersetzung erledigt ist, müssen Sie trotzdem noch Ihren zu portierenden Code nachbearbeiten, zum Beispiel wegen der neuen &amp;lt;tt&amp;gt;KAction&amp;lt;/tt&amp;gt; API. Über alle API Änderungen informiert Sie die Datei [http://websvn.kde.org/*checkout*/trunk/KDE/kdelibs/KDE4PORTING.html KDE4PORTING.html] des Modules {{module|kdelibs}}.&lt;br /&gt;
&lt;br /&gt;
==Qt Designer UI Dateien==&lt;br /&gt;
Die &amp;quot;.ui&amp;quot; Dateien, die vom Qt Designer unter Qt3 produziert wurden müssen in das neue Qt4 Format konvertiert werden. Dazu kann man das Programm {{program|uic3}} benutze, welches in Ihrer Qt4 Installation zur Verfügung gestellt wird.&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% $SVN/trunk/qt-copy/bin/uic3 -convert file.ui &amp;gt; foo.ui&lt;br /&gt;
% mv foo.ui file.ui&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Oder, wenn Sie ein graphisches Werkzeug vorziehen, können Sie auch das Designer Programm von Qt4 benutzen&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% $SVN/trunk/qt-copy/bin/designer file.ui&lt;br /&gt;
(you can save file.ui over top itself, or save to a new file)&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
{{Warning (de)|Beachten Sie, dass durch den Konvertierungsprozess einige selbstdefinierten Slots, Tabellen Spalten, etc verloren gehen können. Es kann also sein, dass Sie diese Dinge dann von Hand wiederherstellen müssen.}}&lt;br /&gt;
&lt;br /&gt;
Sie sollten auch das Programm {{program|fixuifiles}} aus dem Modul {{module|kdesdk}} ausführen, welches einige Säuberungen und Plausibilitätsprüfungen durchführt.&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
% $SVN/trunk/KDE/kdesdk/scripts/fixuifiles&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==D-Bus==&lt;br /&gt;
Statt DCOP, wie es in KDE3 benutzt wird, kommt in KDE4 nun D-Bus für die Kommunikation zwischen Prozessen (interprocess communication) zum Einsatz. Die Portierung von DCOP nach D-BUS ist ein großes Thema, welches im Detail in der Anleitung [[Development/Tutorials/Porting_to_D-Bus|Porting to D-Bus]] (in englisch) beschrieben wird.&lt;br /&gt;
&lt;br /&gt;
Für mehr Informationen sehen Sie bitte auch [[Development/Tutorials#D-Bus|D-Bus tutorials]].&lt;br /&gt;
&lt;br /&gt;
==Icons==&lt;br /&gt;
KDE4 richtet sich nach dem Namensschema für Icons, welches unter [http://standards.freedesktop.org/icon-naming-spec/icon-naming-spec-latest.html freedesktop.org icon naming specification] (englisch) spezifiziert wird. Das bedeutet, dass sowohl Icons die mit KDE4 (Oxygen) ausgeliefert werden, als auch Komponenten in kdelibs, die Icons benutzen diesem Schema folgen.&lt;br /&gt;
&lt;br /&gt;
Um Ihre Applikation von den Iconnamen, die in KDE3 benutzt wurden, in diejenigen, die jetzt in KDE4 benutzt werden zu konvertieren, rufen Sie einfach das [http://websvn.kde.org/*checkout*/trunk/KDE/kdesdk/scripts/qt4/adapt-to-icon-spec.py adapt-to-icon-spec.py] Skript aus dem Wurzelverzeichnis Ihres Projekts auf und folgen Sie den Anweisungen auf dem Bildschirm. &lt;br /&gt;
&lt;br /&gt;
Das Skript konvertiert automatisch alle Icons, die sicher eine überprüfbare Entsprechung haben (z.B. die Benutzung von KIcon oder KIconLoader), überspringt diejenigen die überprüfbar keine Entsprechung haben und fragt bei den fraglich positiven Fällen nach. Letzteres geschieht mit zusätzlichen Kontextinformationen (wenn das gewünscht ist) und so muß man nur 'y' oder 'n' drücken, um die möglichen Treffer zu bestätigen oder abzulehenen und den Portierungsvorgang abzuschließen. &lt;br /&gt;
&lt;br /&gt;
==Internationalization==&lt;br /&gt;
Um Ihre &amp;quot;.pot&amp;quot; Datei zu erzeugen, kopieren Sie die Kommandos aus der 'messages' Regel der {{path|Makefile.am}} Datei Ihres Projektes in ein Shell-Skript namens {{path|Messages.sh}}. Sie dürfen hier die gleichen Variablen ($PREPARETIPS, $XGETTEXT, $podir, etc.) als existent voraussetzen, doch beachten Sie, dass Makefiles und Shell-Skripten eine unterschiedliche Syntax haben.&lt;br /&gt;
&lt;br /&gt;
Seien Sie auch vorsichtig, wenn Sie den -k Parameter mit $XGETTTEXT benutzen. Dann müssen Sie explizit alle Varianten auflisten, die Sie benutzen. &lt;br /&gt;
&lt;br /&gt;
So wird zum Beispiel aus der 'messages' Erzeugungsregel:&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
messages: rc.cpp&lt;br /&gt;
        rm -f tips.cpp&lt;br /&gt;
        $(PREPARETIPS) &amp;gt; tips.cpp&lt;br /&gt;
        $(XGETTEXT) -ktranslate *.cpp *.h -o $(podir)/kmail.pot&lt;br /&gt;
        rm -f tips.cpp&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
folgendes {{path|Messages.sh}} Skript:&lt;br /&gt;
&amp;lt;code bash&amp;gt;&lt;br /&gt;
#! /usr/bin/env bash&lt;br /&gt;
$PREPARETIPS &amp;gt; tips.cpp&lt;br /&gt;
$XGETTEXT -ktranslate:1,1t -ktranslate:1c,2,2t *.cpp *.h -o $podir/kmail.pot&lt;br /&gt;
rm -f tips.cpp&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Do's und Don'ts==   &lt;br /&gt;
* Benutzen Sie nicht die alten Socket-Klassen&lt;br /&gt;
* Benutzen Sie nicht {{qt3|QPtrList}}, und allgemein, setAutoDelete()   &lt;br /&gt;
* Benutzen Sie keine Rasteroperationen.&lt;br /&gt;
* Kodieren Sie keine Darstellungsaufgaben außerhalb des paint events.&lt;br /&gt;
* Vermeiden Sie die Benutzung von {{qt3|QHBox}}, {{qt3|QVBox}}, {{qt3|QGrid}}. Bevorzugen Sie lieber Layouts.   &lt;br /&gt;
* Spielen Sie nicht mit Rahmen von Groupboxes, Labels oder Lineedits um ein anderes Widget zu imitieren. Benutzen Sie lieber das passende Widget. Anstatt ein Label so zu ändern, dass es einen eingesunkenen Lineedit-Rand hat, lieber ein nur-lesen {{class|KLineEdit}} benutzen. Und statt {{class|KLineEdit}} ohne Rahmen für Widgets mit Kopierfunktion lieber {{class|KActiveLabel}} benutzen.   &lt;br /&gt;
* Benutzen Sie keine Groupbox ohne Rahmen um Widgets zu gruppieren. Statt dessen einfach ein Layout benutzen.&lt;br /&gt;
&lt;br /&gt;
==Mehr Informationen==   &lt;br /&gt;
===Dokumentation===   &lt;br /&gt;
* [http://doc.trolltech.com/4.3 Qt4.3 Reference]   &lt;br /&gt;
* [http://developer.kde.org/documentation/library/svn-api.php KDE4 API Reference]   &lt;br /&gt;
* [http://www.cmake.org/HTML/Documentation.html CMake Cross Platform Make]   &lt;br /&gt;
* [http://websvn.kde.org/*checkout*/trunk/KDE/kdelibs/KDE4PORTING.html KDE4PORTING.html]&lt;br /&gt;
&lt;br /&gt;
===Weitere Hilfe===   &lt;br /&gt;
* #kde4-devel on irc.freenode.net   &lt;br /&gt;
&lt;br /&gt;
[[Category:KDE4]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Using_KActions_(de)</id>
		<title>Development/Tutorials/Using KActions (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Using_KActions_(de)"/>
				<updated>2007-12-21T11:15:10Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: /* XmlGui */ Adjusted template to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Using_KActions}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Anleitungen für Anfänger|&lt;br /&gt;
&lt;br /&gt;
name=KActions benutzen|&lt;br /&gt;
&lt;br /&gt;
pre=[[Development/Tutorials/Using_KXmlGuiWindow (de)|Anleitung 2 - KXmlGuiWindow]]|&lt;br /&gt;
&lt;br /&gt;
next=Todo| &lt;br /&gt;
&lt;br /&gt;
reading=none&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Zusammenfassung==&lt;br /&gt;
In diesem Kapitel wird das Konzept der Aktionen eingeführt. Aktionen sind ein vereinheitlichter Weg, dem Benutzer eine Interaktion mit Ihrem Programm zu ermöglichen&lt;br /&gt;
&lt;br /&gt;
Soll zum Beispiel durch das Klicken eines Buttons, einem Eintrag im Dateimenü oder einem Tastaturshortcut das Textfeld geleert werden, wird dies alles durch eine {{class|KAction}} bewerkstelligt.&lt;br /&gt;
&lt;br /&gt;
[[image:introtokdetutorial3.png|frame|center]]&lt;br /&gt;
&lt;br /&gt;
==KAction==&lt;br /&gt;
Eine {{class|KAction}} ist ein Objekt, welches alle Informationen über das Icon und Shortcuts enthält, welche mit einer bestimmten Aktion assoziiert sind. Diese Aktion läßt sich mit einem[http://doc.trolltech.com/latest/signalsandslots.html slot] verbinden, welcher dann bestimmte Arbeiten ausführt, die bei dieser Aktion vorgesehen sind. &lt;br /&gt;
&lt;br /&gt;
===Eine eigene Aktion erzeugen===&lt;br /&gt;
Um eine Aktion zu erzeugen, muss &amp;lt;tt&amp;gt;#include &amp;lt;KAction&amp;gt;&amp;lt;/tt&amp;gt; in die  &amp;lt;tt&amp;gt;.cpp&amp;lt;/tt&amp;gt; Datei eingefügt werden.  &lt;br /&gt;
&lt;br /&gt;
=====Das Objekt erzeugen=====&lt;br /&gt;
Wir werden hier eine Aktion erzeugen, welche die Applikation aus Kapitel 2 dahingehend erweitert, dass durch sie das Textfeld geleert wird. Die KAction wird in einer Reihe einzelner Schritte zusammengestellt. Zunächst wird das Objekt selber erzeugt:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;KAction* clearAction = new KAction(this);&amp;lt;/code&amp;gt;&lt;br /&gt;
Das erzeugt ein KAction-Objekt welches &amp;lt;tt&amp;gt;clearAction&amp;lt;/tt&amp;gt; heißt.&lt;br /&gt;
&lt;br /&gt;
=====Text=====&lt;br /&gt;
Bei dem jetzt erzeugten KAction Objekt können jetzt die Eigenschaften gesetzt werden. Zunächst setzen wir einen Text der im Menü und unter seinem Icon in der Werkzeugleiste angezeigt wird:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;clearAction-&amp;gt;setText(i18n(&amp;quot;Clear&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
Wie man sieht, muss dieser Text durch die &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; Funktion geleitet werden, wenn man das Benutzerinterface später übersetzen möchte. &lt;br /&gt;
&lt;br /&gt;
=====Icon=====&lt;br /&gt;
Soll in der Werkzeugleiste die Aktion angezeigt werden, muss man ein Icon verknüpfen, welches die Aktion bildlich beschreibt. Um das zu bewekstelligen, benutzen wir die &amp;lt;tt&amp;gt;setIcon()&amp;lt;/tt&amp;gt; Funktion:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;clearAction-&amp;gt;setIcon(KIcon(&amp;quot;document-new&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
Hier wird das Standardicon &amp;lt;tt&amp;gt;document-new&amp;lt;/tt&amp;gt; von KDE benutzt.&lt;br /&gt;
&lt;br /&gt;
=====Shortcut=====&lt;br /&gt;
Wir können auch einen Tastaturshortcut definieren, welcher die Aktion ausführt.. Das wird ganz einfach durch &amp;lt;code cppqt&amp;gt;clearAction-&amp;gt;setShortcut(Qt::CTRL+Qt::Key_W);&amp;lt;/code&amp;gt; bewekstelligt. In diesem Fall wird Ctrl+W mit der Aktion verknüpft.&lt;br /&gt;
&lt;br /&gt;
=====Zur Sammlung hinzufügen=====&lt;br /&gt;
Damit das XmlGui Framework auf unsere Aktion zugreifen kann, muss diese in die ''action collection'' (Sammlung der Aktionen) der Applikation eingefügt werden. Auf diese wird über die &amp;lt;tt&amp;gt;actionCollection()&amp;lt;/tt&amp;gt; Funktion zugegriffen: &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
actionCollection()-&amp;gt;addAction(&amp;quot;clear&amp;quot;, clearAction);&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Dieser Code fügt die &amp;lt;tt&amp;gt;clearAction&amp;lt;/tt&amp;gt; KAction in die Sammlung ein und gibt ihr den Namen ''clear''. Dieser Name wird vom XmlGui Framework benutzt.&lt;br /&gt;
&lt;br /&gt;
=====Die Aktion verbinden=====&lt;br /&gt;
Jetzt ist unsere Aktion vollständig aufgesetzt und sie muss nun noch verknüpft werden, damit sie etwas sinnvolles macht. Wir werden unsere Aktion mit dem &amp;lt;tt&amp;gt;clear()&amp;lt;/tt&amp;gt; Slot, der zu einem KTextArea Objekt gehört, verknüpfen:&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
connect( clearAction, SIGNAL( triggered(bool) ), &lt;br /&gt;
         textArea, SLOT( clear() ) );&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
Das gleiche würden wir in Qt mit einer {{qt|QAction}} machen&lt;br /&gt;
&lt;br /&gt;
===KStandardAction===&lt;br /&gt;
&lt;br /&gt;
Manche Aktionen, wie zum Beispiel 'beenden', 'speichern' und 'laden', benötigt fast jede KDE Applikation. Daher gibt es zur Vereinfachung vorgefertigte KActions, auf welche über {{class|KStandardAction}} zugegriffen wird. &lt;br /&gt;
&lt;br /&gt;
Diese sind sehr einfach zu benutzen. Sobald man &amp;lt;tt&amp;gt;#include &amp;lt;KStandardAction&amp;gt;&amp;lt;/tt&amp;gt; im Quellcode eingefügt hat, muss man nur noch festlegen, welche Funktion bei Auslösung aufgerufen werden soll und zu welcher &amp;lt;tt&amp;gt;KActionCollection&amp;lt;/tt&amp;gt; die Aktion hinzugefügt werden soll. Beispiel:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;KStandardAction::quit(kapp, SLOT(quit()), actionCollection());&amp;lt;/code&amp;gt;&lt;br /&gt;
Dieser Code erzeugt ein KAction Objekt mit dem entsprechenden Icon, Text und Shortcut und fügt dieses sogar zum Datei-Menü hinzu.&lt;br /&gt;
&lt;br /&gt;
==Der Code==&lt;br /&gt;
===mainwindow.h===&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
#ifndef MAINWINDOW_H&lt;br /&gt;
#define MAINWINDOW_H&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;KXmlGuiWindow&amp;gt;&lt;br /&gt;
#include &amp;lt;KTextEdit&amp;gt;&lt;br /&gt;
&lt;br /&gt;
class MainWindow : public KXmlGuiWindow&lt;br /&gt;
{&lt;br /&gt;
  public:&lt;br /&gt;
    MainWindow(QWidget *parent=0);&lt;br /&gt;
	&lt;br /&gt;
  private:&lt;br /&gt;
    KTextEdit* textArea;&lt;br /&gt;
    void setupActions();&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
#endif&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===mainwindow.cpp===&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
#include &amp;lt;KApplication&amp;gt;&lt;br /&gt;
#include &amp;lt;KAction&amp;gt;&lt;br /&gt;
#include &amp;lt;KLocale&amp;gt;&lt;br /&gt;
#include &amp;lt;KActionCollection&amp;gt;&lt;br /&gt;
#include &amp;lt;KStandardAction&amp;gt;&lt;br /&gt;
&lt;br /&gt;
MainWindow::MainWindow(QWidget *parent)&lt;br /&gt;
    : KXmlGuiWindow(parent)&lt;br /&gt;
{&lt;br /&gt;
  textArea = new KTextEdit;&lt;br /&gt;
  setCentralWidget(textArea);&lt;br /&gt;
&lt;br /&gt;
  setupActions();&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
void MainWindow::setupActions()&lt;br /&gt;
{&lt;br /&gt;
  KAction* clearAction = new KAction(this);&lt;br /&gt;
  clearAction-&amp;gt;setText(i18n(&amp;quot;Clear&amp;quot;));&lt;br /&gt;
  clearAction-&amp;gt;setIcon(KIcon(&amp;quot;document-new&amp;quot;));&lt;br /&gt;
  clearAction-&amp;gt;setShortcut(Qt::CTRL+Qt::Key_W);&lt;br /&gt;
  actionCollection()-&amp;gt;addAction(&amp;quot;clear&amp;quot;, clearAction);&lt;br /&gt;
  connect(clearAction, SIGNAL(triggered(bool)),&lt;br /&gt;
          textArea, SLOT(clear()));&lt;br /&gt;
&lt;br /&gt;
  KStandardAction::quit(kapp, SLOT(quit()),&lt;br /&gt;
                        actionCollection());&lt;br /&gt;
&lt;br /&gt;
  setupGUI();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
===main.cpp===&lt;br /&gt;
&amp;lt;code cppqt n&amp;gt;&lt;br /&gt;
#include &amp;lt;KApplication&amp;gt;&lt;br /&gt;
#include &amp;lt;KAboutData&amp;gt;&lt;br /&gt;
#include &amp;lt;KCmdLineArgs&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#include &amp;quot;mainwindow.h&amp;quot;&lt;br /&gt;
&lt;br /&gt;
int main (int argc, char *argv[])&lt;br /&gt;
{&lt;br /&gt;
  KAboutData aboutData( &amp;quot;tutorial3&amp;quot;, &amp;quot;tutorial3&amp;quot;,&lt;br /&gt;
      ki18n(&amp;quot;Tutorial 3&amp;quot;), &amp;quot;1.0&amp;quot;,&lt;br /&gt;
      ki18n(&amp;quot;A simple text area using KAction etc.&amp;quot;),&lt;br /&gt;
      KAboutData::License_GPL,&lt;br /&gt;
      ki18n(&amp;quot;Copyright (c) 2007 Developer&amp;quot;) );&lt;br /&gt;
  KCmdLineArgs::init( argc, argv, &amp;amp;aboutData );&lt;br /&gt;
  KApplication app;&lt;br /&gt;
 &lt;br /&gt;
  MainWindow* window = new MainWindow();&lt;br /&gt;
  window-&amp;gt;show();&lt;br /&gt;
  return app.exec();&lt;br /&gt;
}&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Die Aktionen mit den Menüs und Werkzeugleisten verknüpfen==&lt;br /&gt;
Zur Zeit haben wir nur unsere neue &amp;quot;Clear&amp;quot; Aktion erzeugt. Zum jetzigen Zeitpunkt würde diese weder in den Menüs noch in den Werkzeugleisten erscheinen. Um der Applikation mitzuteilen wo die Aktion eingefügt werden soll (und dem Benutzer zu ermöglichen, diese dann beliebig umherzuschieben) wird die KDE-Technik namens XmlGui genutzt. &lt;br /&gt;
&lt;br /&gt;
===XmlGui===&lt;br /&gt;
{{note (de)|In einer späteren Version von KDE4 könnte XmlGui durch ein neues Framework namens liveui ersetzt werden. Doch zum jetzigen Zeitpunkt ist XmlGui die einzige und korrekte Art, das UI aufzusetzen.}}&lt;br /&gt;
&lt;br /&gt;
Ruft man &amp;lt;tt&amp;gt;setupGUI()&amp;lt;/tt&amp;gt; in der {{class|KXmlGuiWindow}} Klasse auf, wird das XmlGui System aufgerufen, welche eine XML Datei einliest, welche das entsprechende interface beschreibt und die Buttons und Menüeinträge entsprechend erzeugt. Diese Datei wird im nächsten Schritt für unsere Applikation erzeugt.&lt;br /&gt;
&lt;br /&gt;
Natürlich muss das XmlGui System wissen, welche Beschreibungs-Datei zu der jeweiligen Applikation gehört. Es muss also dem Namen und den Pfad dieser Datei kennen. Standardmäßig soll die Datei &amp;lt;tt&amp;gt;appnameui.rc&amp;lt;/tt&amp;gt; genannt werden(&amp;lt;tt&amp;gt;appname&amp;lt;/tt&amp;gt; ist dabei der Name, der in {{class|KAboutData}}) gesetzt wurde). In unserem Beispiel wird die Datei also &amp;lt;tt&amp;gt;tutorial3ui.rc&amp;lt;/tt&amp;gt; heißen. Wo die Datei zu finden ist, wird von CMake erledigt.&lt;br /&gt;
&lt;br /&gt;
===Die ''appname''ui.rc Datei schreiben===&lt;br /&gt;
&lt;br /&gt;
Da die Beschreibung unseres UI mit XML definiert wird, muss der Inhalt der Beschreibung strengen Regeln folgen. Wir werden hier nicht alle Regeln auflisten. Darüber wird es eine gesonderte und detailierte Seite geben (die aber noch nicht fertig ist).&lt;br /&gt;
&lt;br /&gt;
===tutorial3ui.rc===&lt;br /&gt;
&amp;lt;code xml n&amp;gt;&lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-8&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE kpartgui SYSTEM &amp;quot;kpartgui.dtd&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;gui name=&amp;quot;tutorial3&amp;quot; version=&amp;quot;1&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;ToolBar name=&amp;quot;mainToolBar&amp;quot; &amp;gt;&lt;br /&gt;
    &amp;lt;text&amp;gt;Main Toolbar&amp;lt;/text&amp;gt;&lt;br /&gt;
    &amp;lt;Action name=&amp;quot;clear&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;ActionList name=&amp;quot;dynamicActionlist&amp;quot; /&amp;gt;&lt;br /&gt;
  &amp;lt;/ToolBar&amp;gt;&lt;br /&gt;
  &amp;lt;MenuBar&amp;gt;&lt;br /&gt;
    &amp;lt;Menu name=&amp;quot;file&amp;quot; &amp;gt;&lt;br /&gt;
      &amp;lt;text&amp;gt;&amp;amp;amp;File&amp;lt;/text&amp;gt;&lt;br /&gt;
      &amp;lt;Action name=&amp;quot;clear&amp;quot; /&amp;gt;&lt;br /&gt;
    &amp;lt;/Menu&amp;gt;&lt;br /&gt;
  &amp;lt;/MenuBar&amp;gt;&lt;br /&gt;
&amp;lt;/gui&amp;gt;&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Das &amp;lt;tt&amp;gt;&amp;lt;Toolbar&amp;gt;&amp;lt;/tt&amp;gt; Tag beschreibt die Werkzeugleiste (der Balken mit Icons am oberen Rand des Fensters). Wir geben dieser hier den eindeutigen Namen ''mainToolBar'', setzen den Namen, der für den Benutzer sichtbar ist, auf  ''Main Toolbar'', indem wir das &amp;lt;tt&amp;gt;&amp;lt;text&amp;gt;&amp;lt;/tt&amp;gt; Tag anwenden und fügen letztlich unsere Clear-Aktion in die Werkzeugleiste ein, indem wir das &amp;lt;tt&amp;gt;&amp;lt;Action&amp;gt;&amp;lt;/tt&amp;gt; Tag benutzen. Der Parameter &amp;quot;name&amp;quot; dieses Tags ist die gleiche Zeichenkette, die der &amp;lt;tt&amp;gt;addAction()&amp;lt;/tt&amp;gt; Funktion im C++ Code übergeben wurde. &lt;br /&gt;
&lt;br /&gt;
Neben der Werkzeugleiste können wir die Aktion auch in das Hauptmenü einfügen. Dieses erfolgt über das &amp;lt;tt&amp;gt;&amp;lt;MenuBar&amp;gt;&amp;lt;/tt&amp;gt; Tag. Hier wird festgelegt, dass die Aktion in das ''File'' Menü eingefügt werden soll. Die Aktion selber wird auf die gleiche Art und Weise eingefügt wie bereits in der der Werkzeugleiste beschrieben. &lt;br /&gt;
&lt;br /&gt;
Bitte beachten Sie, dass sie auch eine dynamische Aktionsliste in die Konfigurationsdatei einfügen können, wenn Sie das &amp;lt;tt&amp;gt;&amp;lt;ActionList&amp;gt;&amp;lt;/tt&amp;gt; Tag benutzen. Mehr Informationen darüber finden Sie in der Methodenbeschreibung &amp;lt;tt&amp;gt;plugActionList()&amp;lt;/tt&amp;gt; der {{class|KXMLGUIClient}} Dokumentation.&lt;br /&gt;
&lt;br /&gt;
Ändern Sie jedesmal das &amp;quot;version&amp;quot; Attribut des Gui-Tags wenn Sie die .rc Datei geändert haben, damit ein Auffrisches des Systemcaches erfolgt. &lt;br /&gt;
&lt;br /&gt;
==CMake==&lt;br /&gt;
Da wir jetzt XmlGui benutzen, muß die &amp;lt;tt&amp;gt;tutorial3ui.rc&amp;lt;/tt&amp;gt; Datei irgendwo hin kopiert werden, wo KDE sie finden kann. '''Aus diesem Grund muss unser Programm irgendwo hin installiert werden.'''&lt;br /&gt;
&lt;br /&gt;
===CMakeLists.txt===&lt;br /&gt;
&amp;lt;code&amp;gt;&lt;br /&gt;
project(tutorial3)&lt;br /&gt;
&lt;br /&gt;
find_package(KDE4 REQUIRED)&lt;br /&gt;
include_directories( ${KDE4_INCLUDES} )&lt;br /&gt;
&lt;br /&gt;
set(tutorial3_SRCS &lt;br /&gt;
  main.cpp&lt;br /&gt;
  mainwindow.cpp&lt;br /&gt;
)&lt;br /&gt;
&lt;br /&gt;
kde4_add_executable(tutorial3 ${tutorial3_SRCS})&lt;br /&gt;
&lt;br /&gt;
target_link_libraries(tutorial3 ${KDE4_KDEUI_LIBS})&lt;br /&gt;
&lt;br /&gt;
install(TARGETS tutorial3 DESTINATION ${BIN_INSTALL_DIR})&lt;br /&gt;
install( FILES tutorial3ui.rc &lt;br /&gt;
         DESTINATION  ${DATA_INSTALL_DIR}/tutorial3 )&lt;br /&gt;
&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Diese Datei sieht fast genau so aus wie diejenige für Kapitel2, hat aber zwei extra Zeilen am Ende. Diese beschreiben, wohin die Dateien installiert werden sollen. Zunächst wird das &amp;lt;tt&amp;gt;tutorial3&amp;lt;/tt&amp;gt; Ziel in das Verzeichnis &amp;lt;tt&amp;gt;BIN_INSTALL_DIR&amp;lt;/tt&amp;gt; Verzeichnis installiert und anschließend die &amp;lt;tt&amp;gt;tutorial3ui.rc&amp;lt;/tt&amp;gt; Datei, die das Layout unseres Userinterfaces beschreibt in das Datenverzeichnis unserer Applikation. &lt;br /&gt;
&lt;br /&gt;
===Erzeugen, Installieren und Ausführen===&lt;br /&gt;
Wenn Sie keinen Schreibzugriff auf das KDE4 Installationsverzeichnis haben, können Sie das Programm auch in ein Verzeichnis innerhalb Ihres Heimatverzeichnissen installieren. &lt;br /&gt;
&lt;br /&gt;
Um CMake mitzuteilen, wohin das Programm installiert werden soll, setzen Sie den &amp;lt;tt&amp;gt;DCMAKE_INSTALL_PREFIX&amp;lt;/tt&amp;gt; Schalter. Um also das Programm in das KDE Verzeichnis zu installieren, rufen Sie&lt;br /&gt;
 cmake . -DCMAKE_INSTALL_PREFIX=$KDEDIR&lt;br /&gt;
 make install&lt;br /&gt;
 tutorial3&lt;br /&gt;
auf.&lt;br /&gt;
&lt;br /&gt;
Wenn man hingegen das Programm irgendwo lokal zu Testzwecken installieren will (bei der zurzeit etwas eingeschränkten Funktionalität unsere Applikation ist es vielleicht nicht unbedingt sinnvoll diese in das KDE Hauptverzeichnis zu installieren), wird mit dem Befehl&lt;br /&gt;
 cmake . -DCMAKE_INSTALL_PREFIX=/home/kde-devel/kdetmp&lt;br /&gt;
eine KDE-artige Verzeichnisstruktur innerhalb des ~/kdetmp Verzeichnissen angelegt und die Applikation in das {{path|/home/kde-devel/kdetmp/bin/tutorial3}} Verzeichnis kopiert.&lt;br /&gt;
&lt;br /&gt;
==Weiter geht's==&lt;br /&gt;
TODO&lt;br /&gt;
&lt;br /&gt;
[[Category:C++]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials_(de)</id>
		<title>Development/Tutorials (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials_(de)"/>
				<updated>2007-12-21T11:13:47Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Changed template to german version&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials}}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Bitte hilf, die englische Seite vollständig ins Deutsche zu übersetzen.}}&lt;br /&gt;
&lt;br /&gt;
== Einführung in die KDE 4 Programmierung ==&lt;br /&gt;
Sind Sie an der Entwicklung von Programmen für KDE 4 interesiert? Wenn ja sind Sie hier genau richtig. Diese Artikelserie richtet sich an alle, die noch nie mit KDE programmiert haben.&lt;br /&gt;
;[[Development/Tutorials/First program (de)|Hallo Welt!]]&lt;br /&gt;
:''Einführung in die Grundlagen der KDE Programmierung''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KXmlGuiWindow (de)|Erstellen eines Hauptfensters]]&lt;br /&gt;
:''Dieser Artikel erklärt, wie der wichtigste Teil eines grafischen Programmes erstellt wird: das Hauptfenster.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KActions (de)|Die Verwendung von KActions]]&lt;br /&gt;
:''In diesem Artikel erfahren Sie, wie Aktionen und Werkzeugleisten (Toolbars) im Menü hinzugefügt werden können.''&lt;br /&gt;
&lt;br /&gt;
== Grundlagen ==&lt;br /&gt;
;[[Development/Tutorials/KDE4 Porting Guide (de)|Ihre Applikation nach KDE 4 portieren]]&lt;br /&gt;
:''Anleitungen Qt3/KDE3 Applikationen nach Qt4/KDE4 zu portieren''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/CMake (de)|Einführung in CMake]]&lt;br /&gt;
:''Wie man CMake in KDE 4 benutzt''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Common Programming Mistakes (de)|Häufige Programmierfehler]]&lt;br /&gt;
:''Einige häufige Fehler die man während der Entwicklung von Qt und KDE Applikationen machen kann und wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using Qt Designer (de)|Den Qt Designer benutzen um Benutzerschnittstellen zu erzeugen]]&lt;br /&gt;
:''Wie man UI Dateien mit dem Designer erzeugt und wie man diese in einem KDE Programm integriert.''&lt;br /&gt;
&lt;br /&gt;
== Dienste: Applicationen and Plugins ==&lt;br /&gt;
;[[Development/Tutorials/Services/Introduction (de)|Einführung in das Dienst-Framework]]&lt;br /&gt;
:''Eine Einführung über das Dienst-Framework in KDE und was es dem Applikationsentwickler zur Verfügung stellen kann. Beschäftigt sich mit dem system configuration cache (SyCoCa), den benötigten Dateien und wie indizierte Informationen benutzt werden.&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Traders (de)|Dienste über Trader Queries finden]]&lt;br /&gt;
:''Wie man mit der Trader Query Syntax Dienste wie Plugins oder Mimetypes findet, die im SyCoCa zwischengespeichert wurden. ''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Plugins (de)|Erstellen und Laden von Plugins mit KService]]&lt;br /&gt;
:''Zeigt, wie man eigene Plugintypen definiert, installiere Plugins findet (einschließlich denen von anderen Herstellern) und wie man diese einfach und portabel läd, indem man KService benutzt.''&lt;br /&gt;
&lt;br /&gt;
== Lokalisation ==&lt;br /&gt;
;[[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]]&lt;br /&gt;
:''Eine Einführung was Unicode ist und wie KDE Applikationen damit umgehen.''&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)</id>
		<title>Development/Tutorials/Localization/i18n (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)"/>
				<updated>2007-12-21T11:01:39Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode (de)|Introduction to Unicode]] ist empfohlen wenn auch nicht notwendig|&lt;br /&gt;
&lt;br /&gt;
name=Beim Applikationen schreiben an die Lokalisation denken|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes (de)|Häufige Fehler vermeiden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Eine breite Schar an Benutzern und Entwicklern zu erreichen erfordert, dass Ihre Software übersetzt werden kann und sich auch anderweitig an sprachliche und kulturelle Gegebenheiten desjenigen anpassen kann, der Ihre Applikation benutzt. Das ist die Aufgabe von Lokalisation und diese Anleitung leitet Sie durch die grundlegenden Schritte, Ihre Applikation lokalisierungsfähig zu machen. &lt;br /&gt;
&lt;br /&gt;
== Was ist Internationalisation and Lokalisation? ==&lt;br /&gt;
&lt;br /&gt;
Internationalisation, oder i18n ('i', gefolgt von 18 Buchstaben und dann ein  'n'), bezeichnet den Prozess, Ihre Applikation so zu schreiben, dass sie in jeder beliebigen Sprache und Kultur laufen kann. Dabei müssen folgende Dinge berücksichtigt werden:&lt;br /&gt;
* Textmitteilungen, die dem Benutzer mitgeteilt werden&lt;br /&gt;
* Dateneingabe vom Benutzer, Dateien und anderen Quellen&lt;br /&gt;
* Das Format von Datum, Zahlen, Währungen, etc. &lt;br /&gt;
&lt;br /&gt;
Lokalisation, oder l10n ('l' gefolgt von 10 Zeichen und dann ein 'n') ist der Prozess, eine internationalisierte Applikation an bestimmte lokale Gegebenheiten anzupassen.&lt;br /&gt;
&lt;br /&gt;
Im allgemeinen internationalisieren Programmierer ihre Applikationen und Übersetzerteams lokalisieren sie. &lt;br /&gt;
&lt;br /&gt;
== Warum ist das wichtig? ==&lt;br /&gt;
&lt;br /&gt;
KDE Entwicklung findet primär in Englisch statt, da dies eine breite Entwickler- und Übersetzerschaft erreicht. Englisch ist jedoch nicht die Muttersprache der meisten Menschen auf der Welt. Tatsächlich sprechen weniger als 8% der Menschheit Englisch und weniger als 5% sprechen es als Muttersprache. Auch im Internet benutzen nur 35% der Menschen die online sind Englisch als primäre Sprache und je mehr Teile der Welt an das Internet angeschlossen werden, desto geringer wird dieser Anteil werden. Zusätzlich benutzen die meisten sprachen, alleine 9 der 10 häufigsten, nicht-ASCII Zeichen in ihrer geschriebenen Form. Daher ist es einfach zu erkennen, warum es notwendig ist, Software zu lokalisieren. &lt;br /&gt;
&lt;br /&gt;
Als internationales Projekt das den gesamten Globul umspannt, ist diese Lokalisation ein wichtiges Gut der KDE Kultur. Tatsächlich entwickeln viele KDE Entwickler ihre Applikationen in Englisch benutzen jedoch ihren KDE-Desktop in der jeweils lokalisierten Version.&lt;br /&gt;
&lt;br /&gt;
== Übersetzbaren Code mit i18n() ==&lt;br /&gt;
&lt;br /&gt;
To ensure your application is ready to be localized you have to follow a few simple rules. All user-visible strings in your application should be translated before they are displayed on the user's screen, exceptions to this being debugging messages, configuration keys and similar types of text data.&lt;br /&gt;
&lt;br /&gt;
KDE provides the &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; class as part of &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; to facilitate the technical details of localization. KLocale makes it as easy as possible for developers to make their code i18n aware, but there are some things you need to be aware of so that applications are usable in other languages and countries.&lt;br /&gt;
&lt;br /&gt;
Access to a global &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is provided via &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt;. This &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is created automatically by &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; and takes care of all user i18n related settings. It is deleted automatically on application exit.&lt;br /&gt;
&lt;br /&gt;
Translations are made possible by the &amp;lt;tt&amp;gt;QString i18n(const char*)&amp;lt;/tt&amp;gt; method, defined in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;, which you must wrap all strings that should be displayed in. The QString returned by &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; is the translated (if necessary) string. This makes creating translatable widgets as simple as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
QString's native Unicode support ensures that all translations are represented correctly. All string handling done by your application should therefore use QString.&lt;br /&gt;
&lt;br /&gt;
{{tip|If the string to be translated contains any non-UTF8 characters, use the utf8() method to get a char*.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; method requires that a &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; (e.g. &amp;lt;tt&amp;gt;KApplication&amp;lt;/tt&amp;gt;) has been created. For any strings that are created prior  to this there is another method provided: &amp;lt;tt&amp;gt;ki18n()&amp;lt;/tt&amp;gt;. This allows one to mark strings that should be translated later as such. The ki18n() will return a &amp;lt;tt&amp;gt;KLocalizedString&amp;lt;/tt&amp;gt;, which can be finalized into a QString (i.e. translated for real) after the KInstance has been created, using its toString() method.&lt;br /&gt;
&lt;br /&gt;
ki18n() is typically used for strings given to KAboutData, because it is constructed before the KApplication and you can use i18n() only after the construction of the KApplication. Other than these special cases, it is always safe to use i18n() if you are sure that the code will be executed after construction of KApplication or some other KInstance.&lt;br /&gt;
&lt;br /&gt;
=== Kontext hinzufügen ===&lt;br /&gt;
&lt;br /&gt;
There is an extended version of &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; which takes two &amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; arguments. The first argument is an additional contextual description of the second string which will be translated. The first  string is used to find the proper corresponding translation at run-time and is shown to translators to help them understand the meaning of the string. &lt;br /&gt;
&lt;br /&gt;
Use &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; whenever the purpose of the text might be ambiguous without further context. For example, consider a context menu in a file manager with an entry called &amp;quot;View&amp;quot; which opens a viewer for the currently selected file. In this context &amp;quot;View&amp;quot; is a verb. However, the same application also may have a menu called &amp;quot;View&amp;quot; in the menubar. In that context &amp;quot;View&amp;quot; is a noun. In the English version of the application everything looks fine, but in most other languages one of the two &amp;quot;View&amp;quot; strings will be incorrect.&lt;br /&gt;
&lt;br /&gt;
Additionally, translators sometimes need extra help in understanding what the text is actually referring to during the translation process.&lt;br /&gt;
&lt;br /&gt;
In the file manager example above, one might therefore write:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now the two strings will be properly translatable, both by the human translators and at runtime by KLocale.&lt;br /&gt;
&lt;br /&gt;
Use this form of i18n whenever the string to translate is short or the meaning is hard to discern when the context is not exactly known. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note (de)|There is also a ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) method for providing context to strings which are constructed before the KInstance. It returns a KLocalizedString, so use the toString() method afterwards to convert it into a QString.}}&lt;br /&gt;
&lt;br /&gt;
Contexts can also be added when building forms in Qt Designer. Each widget label, including tooltips and whatsthis texts, has a &amp;quot;comment&amp;quot; attribute, which will serve the same purpose as first argument to &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; call.&lt;br /&gt;
&lt;br /&gt;
=== Standard Kontext für häufige Ausdrücke ===&lt;br /&gt;
&lt;br /&gt;
Below is a chart showing some common words and phrases in English and the context that must be used with them to ensure proper translation of them in other languages.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Contexts&lt;br /&gt;
|-&lt;br /&gt;
! Phrase !! Context !! i18nc Call !! Example&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plural ===&lt;br /&gt;
&lt;br /&gt;
Plurals are handled differently from language to language. Many languages have different plurals for 2, 10, 20, 100, etc. When the string you want translated refers to more than one item, you must use the third form of &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt;,  the &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. It takes the singular and plural English forms as its first two arguments, followed by any substitution arguments as usual, but at least one of which should be integer-valued. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; gets expanded to as many cases as required by the user's language. In English, this is just two forms while in other languages it may be more, depending on the value of the first integer-valued argument.&lt;br /&gt;
&lt;br /&gt;
Note that this form should be used even if the string always refers to more than one item as some languages use a singular form even when referring to a multiple (typically for 21, 31, etc.). This code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
is therefore incorrect and should instead be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To provide context as well as pluralization, use &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Datum und Zahlen formatieren ==&lt;br /&gt;
&lt;br /&gt;
When displaying a number to the user, your program must take care of the decimal separator, thousand separator and currency symbol (if any) being used. These symbols differ from region to region. In English speaking countries a dot (.) is used to separate the fractional part of a number, while in some European countries a comma (,) is used instead. Below is a short summary of functions that will help you format the numbers correctly, taking the local conventions into account for you.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Functions to Format Numbers&lt;br /&gt;
|-&lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function&amp;amp;nbsp;Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Number || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Number || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || Number || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
 &lt;br /&gt;
Similar functions exist to read information provided by the user at runtime in their localized format, e.g. readNumber() or readMoney().&lt;br /&gt;
&lt;br /&gt;
== Kalender ==&lt;br /&gt;
&lt;br /&gt;
Applikationen zu entwickeln, die sich mit Datum und Zeit beschäftigen, zum Beispiel Kalender, ist ein sehr komplexes Gebiet. Nicht nur Zeichenketten die ein Datum oder eine Uhrzeit beinhalten müssen lokal angepasst werden, man muss auch andere Aspekte bedenken, wie zum Beispiel:&lt;br /&gt;
* Welcher Dag in der Woche der erste ist (cf int weekStartDay())&lt;br /&gt;
* Wieviele Monate in einem Jahr sind&lt;br /&gt;
* &amp;quot;Ära&amp;quot;-basierte Kalender&lt;br /&gt;
* Ob ein 24-Stunden Zeitformat benutzt wird (cf bool use12Clock())&lt;br /&gt;
&lt;br /&gt;
KLocale stellt neben anderen diese Methoden zur verfügung:&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Kalenderdaten Funktionen&lt;br /&gt;
|-                &lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Date || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Mehr Informationen für verschiedene Kalendersysteme geben}}&lt;br /&gt;
&lt;br /&gt;
== Häufige Fallen vermeiden ==&lt;br /&gt;
Es gibt eine Reihe von häufigen Problemen die es unmöglich machen, eine Applikation angemessen zu lokalisieren. Im nächsten Kapitel [[../i18n Mistakes (de)|Häufige Fehler in der Lokalisation vermeiden]] lernen Sie mehr darüber und wie man solche Fehler vermeidet.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Dank geht an Lukáš Tinkl, Matthias Kiefer und Gary Cramblitt für die Originalversion dieser Anleitung.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)</id>
		<title>Development/Tutorials/Localization/i18n (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)"/>
				<updated>2007-12-21T10:41:20Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: More translation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode (de)|Introduction to Unicode]] ist empfohlen wenn auch nicht notwendig|&lt;br /&gt;
&lt;br /&gt;
name=Beim Applikationen schreiben an die Lokalisation denken|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes (de)|Häufige Fehler vermeiden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Eine breite Schar an Benutzern und Entwicklern zu erreichen erfordert, dass Ihre Software übersetzt werden kann und sich auch anderweitig an sprachliche und kulturelle Gegebenheiten desjenigen anpassen kann, der Ihre Applikation benutzt. Das ist die Aufgabe von Lokalisation und diese Anleitung leitet Sie durch die grundlegenden Schritte, Ihre Applikation lokalisierungsfähig zu machen. &lt;br /&gt;
&lt;br /&gt;
== Was ist Internationalisation and Lokalisation? ==&lt;br /&gt;
&lt;br /&gt;
Internationalisation, oder i18n ('i', gefolgt von 18 Buchstaben und dann ein  'n'), bezeichnet den Prozess, Ihre Applikation so zu schreiben, dass sie in jeder beliebigen Sprache und Kultur laufen kann. Dabei müssen folgende Dinge berücksichtigt werden:&lt;br /&gt;
* Textmitteilungen, die dem Benutzer mitgeteilt werden&lt;br /&gt;
* Dateneingabe vom Benutzer, Dateien und anderen Quellen&lt;br /&gt;
* Das Format von Datum, Zahlen, Währungen, etc. &lt;br /&gt;
&lt;br /&gt;
Lokalisation, oder l10n ('l' gefolgt von 10 Zeichen und dann ein 'n') ist der Prozess, eine internationalisierte Applikation an bestimmte lokale Gegebenheiten anzupassen.&lt;br /&gt;
&lt;br /&gt;
Im allgemeinen internationalisieren Programmiere ihre Applikationen und Übersetzerteams lokalisieren sie. &lt;br /&gt;
&lt;br /&gt;
== Warum ist das wichtig? ==&lt;br /&gt;
&lt;br /&gt;
KDE development happens primarily in English as this allows the broadest reach into the development and translation communities. However, English is not the primary language of most people on the planet. In fact, fewer than 8% of humanity speaks English and less than 5% speak it as their mother tongue. Even on the Internet, only 35% people who are online use English as their primary language and as more and more of the world gets wired this number is only decreasing. Additionally most languages, including 9 out of the 10 most common languages, use non-ASCII characters in their written form. It is easy to see, then, why it has become a necessity to provide localized software. &lt;br /&gt;
&lt;br /&gt;
As an international project that spans the globe, such localization is a core value within the KDE culture. In fact, while many KDE developers write their software in English they use the desktop in their native locale.&lt;br /&gt;
&lt;br /&gt;
== Übersetzbaren Code mit i18n() ==&lt;br /&gt;
&lt;br /&gt;
To ensure your application is ready to be localized you have to follow a few simple rules. All user-visible strings in your application should be translated before they are displayed on the user's screen, exceptions to this being debugging messages, configuration keys and similar types of text data.&lt;br /&gt;
&lt;br /&gt;
KDE provides the &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; class as part of &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; to facilitate the technical details of localization. KLocale makes it as easy as possible for developers to make their code i18n aware, but there are some things you need to be aware of so that applications are usable in other languages and countries.&lt;br /&gt;
&lt;br /&gt;
Access to a global &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is provided via &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt;. This &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is created automatically by &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; and takes care of all user i18n related settings. It is deleted automatically on application exit.&lt;br /&gt;
&lt;br /&gt;
Translations are made possible by the &amp;lt;tt&amp;gt;QString i18n(const char*)&amp;lt;/tt&amp;gt; method, defined in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;, which you must wrap all strings that should be displayed in. The QString returned by &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; is the translated (if necessary) string. This makes creating translatable widgets as simple as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
QString's native Unicode support ensures that all translations are represented correctly. All string handling done by your application should therefore use QString.&lt;br /&gt;
&lt;br /&gt;
{{tip|If the string to be translated contains any non-UTF8 characters, use the utf8() method to get a char*.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; method requires that a &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; (e.g. &amp;lt;tt&amp;gt;KApplication&amp;lt;/tt&amp;gt;) has been created. For any strings that are created prior  to this there is another method provided: &amp;lt;tt&amp;gt;ki18n()&amp;lt;/tt&amp;gt;. This allows one to mark strings that should be translated later as such. The ki18n() will return a &amp;lt;tt&amp;gt;KLocalizedString&amp;lt;/tt&amp;gt;, which can be finalized into a QString (i.e. translated for real) after the KInstance has been created, using its toString() method.&lt;br /&gt;
&lt;br /&gt;
ki18n() is typically used for strings given to KAboutData, because it is constructed before the KApplication and you can use i18n() only after the construction of the KApplication. Other than these special cases, it is always safe to use i18n() if you are sure that the code will be executed after construction of KApplication or some other KInstance.&lt;br /&gt;
&lt;br /&gt;
=== Kontext hinzufügen ===&lt;br /&gt;
&lt;br /&gt;
There is an extended version of &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; which takes two &amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; arguments. The first argument is an additional contextual description of the second string which will be translated. The first  string is used to find the proper corresponding translation at run-time and is shown to translators to help them understand the meaning of the string. &lt;br /&gt;
&lt;br /&gt;
Use &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; whenever the purpose of the text might be ambiguous without further context. For example, consider a context menu in a file manager with an entry called &amp;quot;View&amp;quot; which opens a viewer for the currently selected file. In this context &amp;quot;View&amp;quot; is a verb. However, the same application also may have a menu called &amp;quot;View&amp;quot; in the menubar. In that context &amp;quot;View&amp;quot; is a noun. In the English version of the application everything looks fine, but in most other languages one of the two &amp;quot;View&amp;quot; strings will be incorrect.&lt;br /&gt;
&lt;br /&gt;
Additionally, translators sometimes need extra help in understanding what the text is actually referring to during the translation process.&lt;br /&gt;
&lt;br /&gt;
In the file manager example above, one might therefore write:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now the two strings will be properly translatable, both by the human translators and at runtime by KLocale.&lt;br /&gt;
&lt;br /&gt;
Use this form of i18n whenever the string to translate is short or the meaning is hard to discern when the context is not exactly known. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note (de)|There is also a ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) method for providing context to strings which are constructed before the KInstance. It returns a KLocalizedString, so use the toString() method afterwards to convert it into a QString.}}&lt;br /&gt;
&lt;br /&gt;
Contexts can also be added when building forms in Qt Designer. Each widget label, including tooltips and whatsthis texts, has a &amp;quot;comment&amp;quot; attribute, which will serve the same purpose as first argument to &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; call.&lt;br /&gt;
&lt;br /&gt;
=== Standard Kontext für häufige Ausdrücke ===&lt;br /&gt;
&lt;br /&gt;
Below is a chart showing some common words and phrases in English and the context that must be used with them to ensure proper translation of them in other languages.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Contexts&lt;br /&gt;
|-&lt;br /&gt;
! Phrase !! Context !! i18nc Call !! Example&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plural ===&lt;br /&gt;
&lt;br /&gt;
Plurals are handled differently from language to language. Many languages have different plurals for 2, 10, 20, 100, etc. When the string you want translated refers to more than one item, you must use the third form of &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt;,  the &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. It takes the singular and plural English forms as its first two arguments, followed by any substitution arguments as usual, but at least one of which should be integer-valued. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; gets expanded to as many cases as required by the user's language. In English, this is just two forms while in other languages it may be more, depending on the value of the first integer-valued argument.&lt;br /&gt;
&lt;br /&gt;
Note that this form should be used even if the string always refers to more than one item as some languages use a singular form even when referring to a multiple (typically for 21, 31, etc.). This code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
is therefore incorrect and should instead be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To provide context as well as pluralization, use &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Datum und Zahlen formatieren ==&lt;br /&gt;
&lt;br /&gt;
When displaying a number to the user, your program must take care of the decimal separator, thousand separator and currency symbol (if any) being used. These symbols differ from region to region. In English speaking countries a dot (.) is used to separate the fractional part of a number, while in some European countries a comma (,) is used instead. Below is a short summary of functions that will help you format the numbers correctly, taking the local conventions into account for you.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Functions to Format Numbers&lt;br /&gt;
|-&lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function&amp;amp;nbsp;Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Number || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Number || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || Number || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
 &lt;br /&gt;
Similar functions exist to read information provided by the user at runtime in their localized format, e.g. readNumber() or readMoney().&lt;br /&gt;
&lt;br /&gt;
== Kalender ==&lt;br /&gt;
&lt;br /&gt;
Developing applications dealing with dates and time, such as calendars, is a very complex area. Not only may the displayed string containing a date or time may look different based on locale, but one also has to take care of other aspects such as:&lt;br /&gt;
* which day in the week is the first one (cf int weekStartDay()) &lt;br /&gt;
* how many months in a year there are &lt;br /&gt;
* &amp;quot;era&amp;quot;-based calendars &lt;br /&gt;
* whether to use 24-hour time format (cf bool use12Clock()) &lt;br /&gt;
&lt;br /&gt;
KLocale provides, among others, these methods: &lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Calendar Data Functions&lt;br /&gt;
|-                &lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Date || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve (de)|Mehr Informationen für verschiedene Kalendersysteme geben}}&lt;br /&gt;
&lt;br /&gt;
== Häufige Fallen vermeiden ==&lt;br /&gt;
There are a number of common problems that may prevent an application being properly localized. See [[../i18n Mistakes|Avoiding Common Localization Pitfalls]] to learn more about them, and how to avoid them.&lt;br /&gt;
&lt;br /&gt;
{{note (de)|Dank geht an Lukáš Tinkl, Matthias Kiefer und Gary Cramblitt für die Originalversion dieser Anleitung.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Template:Improve_(de)</id>
		<title>Template:Improve (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Template:Improve_(de)"/>
				<updated>2007-12-21T10:28:43Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Created template&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Warning (de)|&lt;br /&gt;
'''Dieser Abschnitt muss verbessert werden''': Bitte hilf mit, verwirrende Abschnitte zu ''bereinigen'' und ''Abschnitte zu reparieren'' die ein '''todo''' beinhalten&lt;br /&gt;
&amp;lt;!--&amp;lt;remove these comments once ParserFunctions are installed?&amp;gt;{{#if:{{{1|}}} |--&amp;gt; &amp;lt;br /&amp;gt; {{{1|}}} &amp;lt;!--}}--&amp;gt; }}&lt;br /&gt;
&amp;lt;noinclude&amp;gt;[[Category:Maintenance Templates]] [[Category:Template]]&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Template:Warning_(de)</id>
		<title>Template:Warning (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Template:Warning_(de)"/>
				<updated>2007-12-21T10:25:06Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Created template&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Box|1={{{3|Warnung}}}|2=[[Image:Action_stop.svg|noframe|left|40px]]{{{1}}} &amp;lt;div class=&amp;quot;clear&amp;quot;&amp;gt;&amp;lt;/div&amp;gt; }}&lt;br /&gt;
&amp;lt;noinclude&amp;gt;&lt;br /&gt;
[[Category:Template]]&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Template:Note_(de)</id>
		<title>Template:Note (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Template:Note_(de)"/>
				<updated>2007-12-21T10:21:36Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Created template&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Box|Anmerkung|2=[[Image:Action_pen.svg|noframe|left|40px]]{{{1}}} &amp;lt;div class=&amp;quot;clear&amp;quot;&amp;gt;&amp;lt;/div&amp;gt; }}&lt;br /&gt;
&amp;lt;noinclude&amp;gt;&lt;br /&gt;
[[Category:Template]]&lt;br /&gt;
&amp;lt;/noinclude&amp;gt;&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)</id>
		<title>Development/Tutorials/Localization/i18n (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n_(de)"/>
				<updated>2007-12-21T10:13:22Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Page created and first translations&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode|Introduction to Unicode (de)]] ist empfohlen wenn auch nicht notwendig|&lt;br /&gt;
&lt;br /&gt;
name=Applikationen schreiben und dabei an die Lokalisation denken|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes (de)|Häufige Fehler vermeiden]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
&lt;br /&gt;
Reaching a broad audience of users and developers requires that your software can be translated and otherwise shaped at runtime to be linguistically and culturally relevant to whomever is sitting in front of the computer. This is the realm of localization and this tutorial steps you through what is needed to make your application localizable.&lt;br /&gt;
&lt;br /&gt;
== Was ist Internationalisation and Lokalisation? ==&lt;br /&gt;
&lt;br /&gt;
Internationalization, or i18n ('i', followed by 18 letters, then an 'n'), is the process of writing your application so that it can be run in any locale. This means taking into account such things as:&lt;br /&gt;
* textual messages that are displayed to the user&lt;br /&gt;
* data input from the user, files and other sources&lt;br /&gt;
* format of dates, numbers, currency, dates, etc.&lt;br /&gt;
&lt;br /&gt;
Localization, or l10n ('l', followed by 10 characters, then an 'n'), is the process of taking an internationalized application and adapting it for a specific locale.&lt;br /&gt;
&lt;br /&gt;
Generaly speaking, programmers internationalize their applications and translation teams localize them.&lt;br /&gt;
&lt;br /&gt;
== Warum ist das wichtig? ==&lt;br /&gt;
&lt;br /&gt;
KDE development happens primarily in English as this allows the broadest reach into the development and translation communities. However, English is not the primary language of most people on the planet. In fact, fewer than 8% of humanity speaks English and less than 5% speak it as their mother tongue. Even on the Internet, only 35% people who are online use English as their primary language and as more and more of the world gets wired this number is only decreasing. Additionally most languages, including 9 out of the 10 most common languages, use non-ASCII characters in their written form. It is easy to see, then, why it has become a necessity to provide localized software. &lt;br /&gt;
&lt;br /&gt;
As an international project that spans the globe, such localization is a core value within the KDE culture. In fact, while many KDE developers write their software in English they use the desktop in their native locale.&lt;br /&gt;
&lt;br /&gt;
== Übersetzbaren Code mit i18n() ==&lt;br /&gt;
&lt;br /&gt;
To ensure your application is ready to be localized you have to follow a few simple rules. All user-visible strings in your application should be translated before they are displayed on the user's screen, exceptions to this being debugging messages, configuration keys and similar types of text data.&lt;br /&gt;
&lt;br /&gt;
KDE provides the &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; class as part of &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; to facilitate the technical details of localization. KLocale makes it as easy as possible for developers to make their code i18n aware, but there are some things you need to be aware of so that applications are usable in other languages and countries.&lt;br /&gt;
&lt;br /&gt;
Access to a global &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is provided via &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt;. This &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is created automatically by &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; and takes care of all user i18n related settings. It is deleted automatically on application exit.&lt;br /&gt;
&lt;br /&gt;
Translations are made possible by the &amp;lt;tt&amp;gt;QString i18n(const char*)&amp;lt;/tt&amp;gt; method, defined in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;, which you must wrap all strings that should be displayed in. The QString returned by &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; is the translated (if necessary) string. This makes creating translatable widgets as simple as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
QString's native Unicode support ensures that all translations are represented correctly. All string handling done by your application should therefore use QString.&lt;br /&gt;
&lt;br /&gt;
{{tip|If the string to be translated contains any non-UTF8 characters, use the utf8() method to get a char*.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; method requires that a &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; (e.g. &amp;lt;tt&amp;gt;KApplication&amp;lt;/tt&amp;gt;) has been created. For any strings that are created prior  to this there is another method provided: &amp;lt;tt&amp;gt;ki18n()&amp;lt;/tt&amp;gt;. This allows one to mark strings that should be translated later as such. The ki18n() will return a &amp;lt;tt&amp;gt;KLocalizedString&amp;lt;/tt&amp;gt;, which can be finalized into a QString (i.e. translated for real) after the KInstance has been created, using its toString() method.&lt;br /&gt;
&lt;br /&gt;
ki18n() is typically used for strings given to KAboutData, because it is constructed before the KApplication and you can use i18n() only after the construction of the KApplication. Other than these special cases, it is always safe to use i18n() if you are sure that the code will be executed after construction of KApplication or some other KInstance.&lt;br /&gt;
&lt;br /&gt;
=== Kontext hinzufügen ===&lt;br /&gt;
&lt;br /&gt;
There is an extended version of &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; which takes two &amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; arguments. The first argument is an additional contextual description of the second string which will be translated. The first  string is used to find the proper corresponding translation at run-time and is shown to translators to help them understand the meaning of the string. &lt;br /&gt;
&lt;br /&gt;
Use &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; whenever the purpose of the text might be ambiguous without further context. For example, consider a context menu in a file manager with an entry called &amp;quot;View&amp;quot; which opens a viewer for the currently selected file. In this context &amp;quot;View&amp;quot; is a verb. However, the same application also may have a menu called &amp;quot;View&amp;quot; in the menubar. In that context &amp;quot;View&amp;quot; is a noun. In the English version of the application everything looks fine, but in most other languages one of the two &amp;quot;View&amp;quot; strings will be incorrect.&lt;br /&gt;
&lt;br /&gt;
Additionally, translators sometimes need extra help in understanding what the text is actually referring to during the translation process.&lt;br /&gt;
&lt;br /&gt;
In the file manager example above, one might therefore write:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now the two strings will be properly translatable, both by the human translators and at runtime by KLocale.&lt;br /&gt;
&lt;br /&gt;
Use this form of i18n whenever the string to translate is short or the meaning is hard to discern when the context is not exactly known. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note|There is also a ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) method for providing context to strings which are constructed before the KInstance. It returns a KLocalizedString, so use the toString() method afterwards to convert it into a QString.}}&lt;br /&gt;
&lt;br /&gt;
Contexts can also be added when building forms in Qt Designer. Each widget label, including tooltips and whatsthis texts, has a &amp;quot;comment&amp;quot; attribute, which will serve the same purpose as first argument to &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; call.&lt;br /&gt;
&lt;br /&gt;
=== Standard Kontext für häufige Ausdrücke ===&lt;br /&gt;
&lt;br /&gt;
Below is a chart showing some common words and phrases in English and the context that must be used with them to ensure proper translation of them in other languages.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Contexts&lt;br /&gt;
|-&lt;br /&gt;
! Phrase !! Context !! i18nc Call !! Example&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plural ===&lt;br /&gt;
&lt;br /&gt;
Plurals are handled differently from language to language. Many languages have different plurals for 2, 10, 20, 100, etc. When the string you want translated refers to more than one item, you must use the third form of &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt;,  the &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. It takes the singular and plural English forms as its first two arguments, followed by any substitution arguments as usual, but at least one of which should be integer-valued. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; gets expanded to as many cases as required by the user's language. In English, this is just two forms while in other languages it may be more, depending on the value of the first integer-valued argument.&lt;br /&gt;
&lt;br /&gt;
Note that this form should be used even if the string always refers to more than one item as some languages use a singular form even when referring to a multiple (typically for 21, 31, etc.). This code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
is therefore incorrect and should instead be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To provide context as well as pluralization, use &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Datum und Zahlen formatieren ==&lt;br /&gt;
&lt;br /&gt;
When displaying a number to the user, your program must take care of the decimal separator, thousand separator and currency symbol (if any) being used. These symbols differ from region to region. In English speaking countries a dot (.) is used to separate the fractional part of a number, while in some European countries a comma (,) is used instead. Below is a short summary of functions that will help you format the numbers correctly, taking the local conventions into account for you.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Functions to Format Numbers&lt;br /&gt;
|-&lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function&amp;amp;nbsp;Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Number || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Number || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || Number || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
 &lt;br /&gt;
Similar functions exist to read information provided by the user at runtime in their localized format, e.g. readNumber() or readMoney().&lt;br /&gt;
&lt;br /&gt;
== Kalender ==&lt;br /&gt;
&lt;br /&gt;
Developing applications dealing with dates and time, such as calendars, is a very complex area. Not only may the displayed string containing a date or time may look different based on locale, but one also has to take care of other aspects such as:&lt;br /&gt;
* which day in the week is the first one (cf int weekStartDay()) &lt;br /&gt;
* how many months in a year there are &lt;br /&gt;
* &amp;quot;era&amp;quot;-based calendars &lt;br /&gt;
* whether to use 24-hour time format (cf bool use12Clock()) &lt;br /&gt;
&lt;br /&gt;
KLocale provides, among others, these methods: &lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Calendar Data Functions&lt;br /&gt;
|-                &lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Date || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve|Mehr Informationen für verschiedene Kalendersysteme geben}}&lt;br /&gt;
&lt;br /&gt;
== Häufige Fallen vermeiden ==&lt;br /&gt;
There are a number of common problems that may prevent an application being properly localized. See [[../i18n Mistakes|Avoiding Common Localization Pitfalls]] to learn more about them, and how to avoid them.&lt;br /&gt;
&lt;br /&gt;
{{note|Dank geht an Lukáš Tinkl, Matthias Kiefer und Gary Cramblitt für die Originalversion dieser Anleitung.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/i18n</id>
		<title>Development/Tutorials/Localization/i18n</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/i18n"/>
				<updated>2007-12-21T10:07:35Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added language navigation&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/i18n}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser|&lt;br /&gt;
&lt;br /&gt;
series=Localization|&lt;br /&gt;
&lt;br /&gt;
pre=[[../Unicode|Introduction to Unicode]] is recommended, though not required|&lt;br /&gt;
&lt;br /&gt;
name=Writing Applications With Localization In Mind|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n_Mistakes|Avoiding Common Localization Pitfalls]]|&lt;br /&gt;
&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Abstract ==&lt;br /&gt;
&lt;br /&gt;
Reaching a broad audience of users and developers requires that your software can be translated and otherwise shaped at runtime to be linguistically and culturally relevant to whomever is sitting in front of the computer. This is the realm of localization and this tutorial steps you through what is needed to make your application localizable.&lt;br /&gt;
&lt;br /&gt;
== What is Internationalization and Localization? ==&lt;br /&gt;
&lt;br /&gt;
Internationalization, or i18n ('i', followed by 18 letters, then an 'n'), is the process of writing your application so that it can be run in any locale. This means taking into account such things as:&lt;br /&gt;
* textual messages that are displayed to the user&lt;br /&gt;
* data input from the user, files and other sources&lt;br /&gt;
* format of dates, numbers, currency, dates, etc.&lt;br /&gt;
&lt;br /&gt;
Localization, or l10n ('l', followed by 10 characters, then an 'n'), is the process of taking an internationalized application and adapting it for a specific locale.&lt;br /&gt;
&lt;br /&gt;
Generaly speaking, programmers internationalize their applications and translation teams localize them.&lt;br /&gt;
&lt;br /&gt;
== Why is This Important? ==&lt;br /&gt;
&lt;br /&gt;
KDE development happens primarily in English as this allows the broadest reach into the development and translation communities. However, English is not the primary language of most people on the planet. In fact, fewer than 8% of humanity speaks English and less than 5% speak it as their mother tongue. Even on the Internet, only 35% people who are online use English as their primary language and as more and more of the world gets wired this number is only decreasing. Additionally most languages, including 9 out of the 10 most common languages, use non-ASCII characters in their written form. It is easy to see, then, why it has become a necessity to provide localized software. &lt;br /&gt;
&lt;br /&gt;
As an international project that spans the globe, such localization is a core value within the KDE culture. In fact, while many KDE developers write their software in English they use the desktop in their native locale.&lt;br /&gt;
&lt;br /&gt;
== Translatable Code Using i18n() ==&lt;br /&gt;
&lt;br /&gt;
To ensure your application is ready to be localized you have to follow a few simple rules. All user-visible strings in your application should be translated before they are displayed on the user's screen, exceptions to this being debugging messages, configuration keys and similar types of text data.&lt;br /&gt;
&lt;br /&gt;
KDE provides the &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; class as part of &amp;lt;tt&amp;gt;libkdecore&amp;lt;/tt&amp;gt; to facilitate the technical details of localization. KLocale makes it as easy as possible for developers to make their code i18n aware, but there are some things you need to be aware of so that applications are usable in other languages and countries.&lt;br /&gt;
&lt;br /&gt;
Access to a global &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is provided via &amp;lt;tt&amp;gt;KGlobal::locale()&amp;lt;/tt&amp;gt;. This &amp;lt;tt&amp;gt;KLocale&amp;lt;/tt&amp;gt; object is created automatically by &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; and takes care of all user i18n related settings. It is deleted automatically on application exit.&lt;br /&gt;
&lt;br /&gt;
Translations are made possible by the &amp;lt;tt&amp;gt;QString i18n(const char*)&amp;lt;/tt&amp;gt; method, defined in &amp;lt;tt&amp;gt;klocalizedstring.h&amp;lt;/tt&amp;gt;, which you must wrap all strings that should be displayed in. The QString returned by &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; is the translated (if necessary) string. This makes creating translatable widgets as simple as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;&lt;br /&gt;
#include &amp;lt;klocalizedstring.h&amp;gt;&lt;br /&gt;
[...]&lt;br /&gt;
QPushButton* myButton = new QPushButton(i18n(&amp;quot;Translate this!&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
QString's native Unicode support ensures that all translations are represented correctly. All string handling done by your application should therefore use QString.&lt;br /&gt;
&lt;br /&gt;
{{tip|If the string to be translated contains any non-UTF8 characters, use the utf8() method to get a char*.}}&lt;br /&gt;
&lt;br /&gt;
=== ki18n ===&lt;br /&gt;
&lt;br /&gt;
The &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt; method requires that a &amp;lt;tt&amp;gt;KInstance&amp;lt;/tt&amp;gt; (e.g. &amp;lt;tt&amp;gt;KApplication&amp;lt;/tt&amp;gt;) has been created. For any strings that are created prior  to this there is another method provided: &amp;lt;tt&amp;gt;ki18n()&amp;lt;/tt&amp;gt;. This allows one to mark strings that should be translated later as such. The ki18n() will return a &amp;lt;tt&amp;gt;KLocalizedString&amp;lt;/tt&amp;gt;, which can be finalized into a QString (i.e. translated for real) after the KInstance has been created, using its toString() method.&lt;br /&gt;
&lt;br /&gt;
ki18n() is typically used for strings given to KAboutData, because it is constructed before the KApplication and you can use i18n() only after the construction of the KApplication. Other than these special cases, it is always safe to use i18n() if you are sure that the code will be executed after construction of KApplication or some other KInstance.&lt;br /&gt;
&lt;br /&gt;
=== Adding Context ===&lt;br /&gt;
&lt;br /&gt;
There is an extended version of &amp;lt;tt&amp;gt;i18n()&amp;lt;/tt&amp;gt;, &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; which takes two &amp;lt;tt&amp;gt;const char*&amp;lt;/tt&amp;gt; arguments. The first argument is an additional contextual description of the second string which will be translated. The first  string is used to find the proper corresponding translation at run-time and is shown to translators to help them understand the meaning of the string. &lt;br /&gt;
&lt;br /&gt;
Use &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; whenever the purpose of the text might be ambiguous without further context. For example, consider a context menu in a file manager with an entry called &amp;quot;View&amp;quot; which opens a viewer for the currently selected file. In this context &amp;quot;View&amp;quot; is a verb. However, the same application also may have a menu called &amp;quot;View&amp;quot; in the menubar. In that context &amp;quot;View&amp;quot; is a noun. In the English version of the application everything looks fine, but in most other languages one of the two &amp;quot;View&amp;quot; strings will be incorrect.&lt;br /&gt;
&lt;br /&gt;
Additionally, translators sometimes need extra help in understanding what the text is actually referring to during the translation process.&lt;br /&gt;
&lt;br /&gt;
In the file manager example above, one might therefore write:&lt;br /&gt;
  &lt;br /&gt;
&amp;lt;code cppqt&amp;gt;contextMenu-&amp;gt;addAction(i18nc(&amp;quot;verb, to view something&amp;quot;, &amp;quot;View&amp;quot;));&lt;br /&gt;
viewMenu-&amp;gt;addAction(i18nc(&amp;quot;noun, the view&amp;quot;, &amp;quot;View&amp;quot;));&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Now the two strings will be properly translatable, both by the human translators and at runtime by KLocale.&lt;br /&gt;
&lt;br /&gt;
Use this form of i18n whenever the string to translate is short or the meaning is hard to discern when the context is not exactly known. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;QString up = i18nc(&amp;quot;Go one directory up in the hierarchy&amp;quot;, &amp;quot;Up&amp;quot;);&lt;br /&gt;
QString relation = i18nc(&amp;quot;A person's name and their familial relationship to you.&amp;quot;, &amp;quot;%1 is your %2&amp;quot;, name, relationship);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{note|There is also a ki18nc(&amp;quot;context&amp;quot;,&amp;quot;text&amp;quot;) method for providing context to strings which are constructed before the KInstance. It returns a KLocalizedString, so use the toString() method afterwards to convert it into a QString.}}&lt;br /&gt;
&lt;br /&gt;
Contexts can also be added when building forms in Qt Designer. Each widget label, including tooltips and whatsthis texts, has a &amp;quot;comment&amp;quot; attribute, which will serve the same purpose as first argument to &amp;lt;tt&amp;gt;i18nc()&amp;lt;/tt&amp;gt; call.&lt;br /&gt;
&lt;br /&gt;
=== Standard Context For Common Phrases ===&lt;br /&gt;
&lt;br /&gt;
Below is a chart showing some common words and phrases in English and the context that must be used with them to ensure proper translation of them in other languages.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Standard Contexts&lt;br /&gt;
|-&lt;br /&gt;
! Phrase !! Context !! i18nc Call !! Example&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Busy || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing is busy&amp;quot;, &amp;quot;Busy&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Color || Color mode, as opposed to Grayscale || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Color mode&amp;quot;, &amp;quot;Color&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who creates&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Creator || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Creator&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Display || Refering to hardware || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Hardware display&amp;quot;, &amp;quot;Display&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person who edits&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Editor || Refering to software || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Software&amp;quot;, &amp;quot;Editor&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to drawing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Draw a line&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Line || Refering to text || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Line of text&amp;quot;, &amp;quot;Line&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to a name of thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's name&amp;quot;, &amp;quot;Name&amp;quot;) || In theme change dialog: i18nc(&amp;quot;Theme name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Name || Refering to first name and last name of person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;) || In KAddessbook contact edit dialog: i18nc(&amp;quot;Person's first and last name&amp;quot;, &amp;quot;Name&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| No || Availability of a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;No&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)load a document, medium etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)load a document&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| (Re)load || (Re)start a program, daemon etc. || &amp;lt;tt&amp;gt;i18nc(&amp;quot;(Re)start a program&amp;quot;, &amp;quot;(Re)load&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a person || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A person's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Title || Refering to a thing || &amp;lt;tt&amp;gt;i18nc(&amp;quot;A thing's title&amp;quot;, &amp;quot;Title&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to sound || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Sound volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to a filesystem || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Filesystem volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Volume || Refering to books || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Book volume&amp;quot;, &amp;quot;Volume&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Answer to a question || &amp;lt;tt&amp;gt;i18nc(&amp;quot;Answer to a question&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Yes || Availability of a thing|| &amp;lt;tt&amp;gt;i18nc(&amp;quot;Availability&amp;quot;, &amp;quot;Yes&amp;quot;)&amp;lt;/tt&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=== Plurals ===&lt;br /&gt;
&lt;br /&gt;
Plurals are handled differently from language to language. Many languages have different plurals for 2, 10, 20, 100, etc. When the string you want translated refers to more than one item, you must use the third form of &amp;lt;tt&amp;gt;i18n&amp;lt;/tt&amp;gt;,  the &amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt;. It takes the singular and plural English forms as its first two arguments, followed by any substitution arguments as usual, but at least one of which should be integer-valued. For example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;msgStr = i18np(&amp;quot;1 image in album %2&amp;quot;, &amp;quot;%1 images in album %2&amp;quot;, numImages, albumName);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;tt&amp;gt;i18np()&amp;lt;/tt&amp;gt; gets expanded to as many cases as required by the user's language. In English, this is just two forms while in other languages it may be more, depending on the value of the first integer-valued argument.&lt;br /&gt;
&lt;br /&gt;
Note that this form should be used even if the string always refers to more than one item as some languages use a singular form even when referring to a multiple (typically for 21, 31, etc.). This code:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18n(&amp;quot;%1 files were deleted&amp;quot;, numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
is therefore incorrect and should instead be:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18np(&amp;quot;1 file was deleted&amp;quot;, &lt;br /&gt;
     &amp;quot;%1 files were deleted&amp;quot;,&lt;br /&gt;
     numFilesDeleted);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
To provide context as well as pluralization, use &amp;lt;tt&amp;gt;i18ncp&amp;lt;/tt&amp;gt; as in this example:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;code cppqt&amp;gt;i18ncp(&amp;quot;Personal file&amp;quot;, &amp;quot;1 file&amp;quot;, &amp;quot;%1 files&amp;quot;, numFiles);&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Formatting Dates and Numbers ==&lt;br /&gt;
&lt;br /&gt;
When displaying a number to the user, your program must take care of the decimal separator, thousand separator and currency symbol (if any) being used. These symbols differ from region to region. In English speaking countries a dot (.) is used to separate the fractional part of a number, while in some European countries a comma (,) is used instead. Below is a short summary of functions that will help you format the numbers correctly, taking the local conventions into account for you.&lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Functions to Format Numbers&lt;br /&gt;
|-&lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function&amp;amp;nbsp;Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Number || String || &amp;lt;pre&amp;gt;QString formatNumber( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Number || Integer,&amp;amp;nbsp;double || &amp;lt;pre&amp;gt;formatNumber( double num, &lt;br /&gt;
              int precision = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || String || &amp;lt;pre&amp;gt;formatMoney( const QString &amp;amp; numStr )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Money || Number || &amp;lt;pre&amp;gt;formatMoney( double num, &lt;br /&gt;
             const QString &amp;amp; currency,&lt;br /&gt;
             int digits = -1 )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date || String || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime, &lt;br /&gt;
            bool includeSecs=false)&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat = true,&lt;br /&gt;
                bool includeSecs = false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}   &lt;br /&gt;
 &lt;br /&gt;
Similar functions exist to read information provided by the user at runtime in their localized format, e.g. readNumber() or readMoney().&lt;br /&gt;
&lt;br /&gt;
== Calendaring ==&lt;br /&gt;
&lt;br /&gt;
Developing applications dealing with dates and time, such as calendars, is a very complex area. Not only may the displayed string containing a date or time may look different based on locale, but one also has to take care of other aspects such as:&lt;br /&gt;
* which day in the week is the first one (cf int weekStartDay()) &lt;br /&gt;
* how many months in a year there are &lt;br /&gt;
* &amp;quot;era&amp;quot;-based calendars &lt;br /&gt;
* whether to use 24-hour time format (cf bool use12Clock()) &lt;br /&gt;
&lt;br /&gt;
KLocale provides, among others, these methods: &lt;br /&gt;
&lt;br /&gt;
{|&lt;br /&gt;
|+ Calendar Data Functions&lt;br /&gt;
|-                &lt;br /&gt;
! Formats&amp;amp;nbsp;a.. !! From&amp;amp;nbsp;a.. !! Function Prototype&lt;br /&gt;
|-&lt;br /&gt;
| Date || QDate || &amp;lt;pre&amp;gt;formatDate( const QDate &amp;amp; pDate,&lt;br /&gt;
            bool shortFormat=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Time || QTime || &amp;lt;pre&amp;gt;formatTime( const QTime &amp;amp; pTime,&lt;br /&gt;
            bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|-&lt;br /&gt;
| Date&amp;amp;nbsp;and&amp;amp;nbsp;time || QDateTime || &amp;lt;pre&amp;gt;formatDateTime( const QDateTime &amp;amp;pDateTime,&lt;br /&gt;
                bool shortFormat=true,&lt;br /&gt;
                bool includeSecs=false )&amp;lt;/pre&amp;gt;&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
{{improve|provide more info on the different calendar systems}}&lt;br /&gt;
&lt;br /&gt;
== Avoiding Common Traps ==&lt;br /&gt;
There are a number of common problems that may prevent an application being properly localized. See [[../i18n Mistakes|Avoiding Common Localization Pitfalls]] to learn more about them, and how to avoid them.&lt;br /&gt;
&lt;br /&gt;
{{note|Thanks to Lukáš Tinkl, Matthias Kiefer and Gary Cramblitt for writing the original version of this tutorial.}}&lt;br /&gt;
&lt;br /&gt;
[[Category:Programming]]&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials_(de)</id>
		<title>Development/Tutorials (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials_(de)"/>
				<updated>2007-12-21T10:06:05Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Added &amp;quot;Lokalisation&amp;quot;&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials}}&lt;br /&gt;
&lt;br /&gt;
{{improve|Bitte hilf, die englische Seite vollständig ins Deutsche zu übersetzen.}}&lt;br /&gt;
&lt;br /&gt;
== Einführung in die KDE 4 Programmierung ==&lt;br /&gt;
Sind Sie an der Entwicklung von Programmen für KDE 4 interesiert? Wenn ja sind Sie hier genau richtig. Diese Artikelserie richtet sich an alle, die noch nie mit KDE programmiert haben.&lt;br /&gt;
;[[Development/Tutorials/First program (de)|Hallo Welt!]]&lt;br /&gt;
:''Einführung in die Grundlagen der KDE Programmierung''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KXmlGuiWindow (de)|Erstellen eines Hauptfensters]]&lt;br /&gt;
:''Dieser Artikel erklärt, wie der wichtigste Teil eines grafischen Programmes erstellt wird: das Hauptfenster.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using KActions (de)|Die Verwendung von KActions]]&lt;br /&gt;
:''In diesem Artikel erfahren Sie, wie Aktionen und Werkzeugleisten (Toolbars) im Menü hinzugefügt werden können.''&lt;br /&gt;
&lt;br /&gt;
== Grundlagen ==&lt;br /&gt;
;[[Development/Tutorials/KDE4 Porting Guide (de)|Ihre Applikation nach KDE 4 portieren]]&lt;br /&gt;
:''Anleitungen Qt3/KDE3 Applikationen nach Qt4/KDE4 zu portieren''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/CMake (de)|Einführung in CMake]]&lt;br /&gt;
:''Wie man CMake in KDE 4 benutzt''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Common Programming Mistakes (de)|Häufige Programmierfehler]]&lt;br /&gt;
:''Einige häufige Fehler die man während der Entwicklung von Qt und KDE Applikationen machen kann und wie man sie vermeidet.''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Using Qt Designer (de)|Den Qt Designer benutzen um Benutzerschnittstellen zu erzeugen]]&lt;br /&gt;
:''Wie man UI Dateien mit dem Designer erzeugt und wie man diese in einem KDE Programm integriert.''&lt;br /&gt;
&lt;br /&gt;
== Dienste: Applicationen and Plugins ==&lt;br /&gt;
;[[Development/Tutorials/Services/Introduction (de)|Einführung in das Dienst-Framework]]&lt;br /&gt;
:''Eine Einführung über das Dienst-Framework in KDE und was es dem Applikationsentwickler zur Verfügung stellen kann. Beschäftigt sich mit dem system configuration cache (SyCoCa), den benötigten Dateien und wie indizierte Informationen benutzt werden.&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Traders (de)|Dienste über Trader Queries finden]]&lt;br /&gt;
:''Wie man mit der Trader Query Syntax Dienste wie Plugins oder Mimetypes findet, die im SyCoCa zwischengespeichert wurden. ''&lt;br /&gt;
&lt;br /&gt;
;[[Development/Tutorials/Services/Plugins (de)|Erstellen und Laden von Plugins mit KService]]&lt;br /&gt;
:''Zeigt, wie man eigene Plugintypen definiert, installiere Plugins findet (einschließlich denen von anderen Herstellern) und wie man diese einfach und portabel läd, indem man KService benutzt.''&lt;br /&gt;
&lt;br /&gt;
== Lokalisation ==&lt;br /&gt;
;[[Development/Tutorials/Localization/Unicode (de)|Einführung in Unicode]]&lt;br /&gt;
:''Eine Einführung was Unicode ist und wie KDE Applikationen damit umgehen.''&lt;/div&gt;</summary>
		<author><name>DrSlowDecay</name></author>	</entry>

	<entry>
		<id>http://techbase.kde.org/Development/Tutorials/Localization/Unicode_(de)</id>
		<title>Development/Tutorials/Localization/Unicode (de)</title>
		<link rel="alternate" type="text/html" href="http://techbase.kde.org/Development/Tutorials/Localization/Unicode_(de)"/>
				<updated>2007-12-21T10:03:15Z</updated>
		
		<summary type="html">&lt;p&gt;DrSlowDecay: Translated the rest&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{Template:I18n/Language Navigation Bar|Development/Tutorials/Localization/Unicode}}&lt;br /&gt;
&lt;br /&gt;
{{TutorialBrowser (de)|&lt;br /&gt;
&lt;br /&gt;
series=Lokalisation|&lt;br /&gt;
&lt;br /&gt;
name=Einführung in Unicode|&lt;br /&gt;
&lt;br /&gt;
next=[[../i18n|Beim Applikationen schreiben an die Lokalisation denken]]|&lt;br /&gt;
&lt;br /&gt;
reading=[http://www.unicode.org/ The Unicode website]&amp;lt;br&amp;gt;[http://en.wikipedia.org/wiki/Unicode Unicode article at Wikipedia]&amp;lt;br&amp;gt;[http://www.cl.cam.ac.uk/~mgk25/unicode.html Unicode for Unix/Linux FAQ]&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
== Zusammenfassung ==&lt;br /&gt;
Unicode ist ein Standard der für jedes Zeichen und Symbol in verschiedenen Schreibsystemen rund um die Welt eine eindeutige Nummer zur Verfügung stellt.&lt;br /&gt;
Dadurch wird die Übersetzung von Software und Texten vereinfacht. Diese Anleitung bietet eine kurze Ei