To avoid chaos and naming conflicts Trolltech recommends that you follow these naming guidelines when you create new classes based on Qt that you wish to release to the free software community.
When you are ready to release your new fantastic class(es)/application(s) for the first time, please let us know about a web page we can reference to. We will then add your class(es)/application(s) to our list of Free Programs and Libraries that use Qt.
Global Names in Your Code
All global names in your header file, i.e. class names, global enums, global functions, preprocessing symbols, etc. should start with a 'q' (uppercase or lowercase), followed by a 1, 2 or 3 character lowercase prefix, followed by a descriptive name. We recommend the following scheme, where xxx is your prefix:
Class Names, Global Types (enums included), global enum identifiers:
Global Functions:
Preprocessor Symbols:
File Names
for header files
for code files
We recommend using lowercase file names for Windows compatibility. In addition, you should put your code in a directory called
, where xxx is your prefix. You should then use
to include header files. (Note that for historical reasons, these guidelines are not followed by Qt. We had to conform to the 8.3 rule when we supported Windows 3.x. Windows 95/98 and NT do not have this limitation.)
Name Prefixes
As a service to the free software community Trolltech maintains an archive of reserved name prefixes. If you register your prefix with us you will at least have a very good answer to give when somebody complains about a name crash.
Trolltech will not act as police if someone should break these rules.
Reserved Name Prefixes
If you want to reserve a prefix, please send mail to, first come, first served.
Identifiers of the form:
QDescriptiveName, qDescriptiveName
are reserved by Trolltech.
To avoid a race to grab all the single letter prefixes, you'll have to have a working class :-) released at an ftp site somewhere (e.g. to be allocated a single letter prefix. 2 and 3 letter prefixes can be allocated by anyone.
The following prefixes have been reserved by developers of Qt based classes.
Single Letter Prefixes
a, as in QaClassName
Reserved by Alexander Kroeller <ali@fb3-s7.math.TU-Berlin.DE>
b, as in QbClassName
Reserved by Daniel Brahneborg <>
d, as in QdClassName
Reserved by Jon DeNardis <>
f, as in QfClassName
Reserved by Gabor Fleischer <>
g, as in QgClassName
Reserved by Geri House <>
k, as in QkClassName
Reserved by Pieter van Beek <>
m, as in QmClassName
Reserved by Marius Sundbakken <>
s, as in QsClassName
Reserved by Sven Mueller <>
t, as in QtClassName
Reserved by Trolltech <>
w, as in QwClassName
Reserved by Warwick Allison <>
x, as in QxClassName
Reserved by Greger Haga <>

Double Letter Prefixes
ak, as in QakClassName
Reserved by Andreas Krebs <>
aw, as in QawClassName
Reserved by Arjen Wiersma <>
ap, as in QapClassName
Reserved by Alexey Pushkin <>
ch, as in QchClassName
Reserved by Stephen Davies <>
cl, as in QclClassName
Reserved by CAD&LAN Computersysteme GmbH <>
cm, as in QcmClassName
Reserved by Christian M�nch <>
cs, as in QcsClassName
Reserved by Lionel Schaffhauser <>
cw, as in QcwClassName
Reserved by Christian Wolf <>
db, as in QdbClassName
Reserved by Wolfgang Glas <>
ex, as in QexClassName
Reserved by Hussein SHAFIE <>
fk, as in QfkClassName
Reserved by Frank Kehren <>
gn, as in QgnClassName
Reserved by Lionel Schaffhauser <>
gs, as in QgsClassName
Reserved by Gary Sherman <>
hd, as in QhdClassName
Reserved by Dirk Thamer <>
hv, as in QhvClassName
Reserved by Holger Vogelsang <>
if, as in QifClassName
Reserved by Mike Ivanov <>
ib, as in QibClassName
Reserved by Irakli Betchvaia <>
ix, as in QixClassName
Reserved by Steve Schau <>
jb, as in QjbClassName
Reserved by Jon Brumfitt <>
jf, as in QjfClassName
Reserved by J�rgen Feichtinger <>
jg, as in QjgClassName
Reserved by Joe Gilkey <>
jo, as in QjoClassName
Reserved by Johannes Overmann <>
km, as in QkmClassName
Reserved by Karsten Muehlmann <>
ks, as in QksClassName
Reserved by Mike Vivash <>
lg, as in QlgClassName
Reserved by Chris Piker <>
mc, as in QmcClassName
Reserved by Michael van der Westhuizen <>
mp, as in QmpClassName
Reserved by Martin Persson <>
mw, as in QmwClassName
Reserved by Michael Wiedmann <>
oc, as in QocClassName
Reserved by Michele Ricciardi <>
qc, as in QqcClassName
Reserved by Karl Wallner <>
rt, as in QrtClassName
Reserved by RT-SET (contact person: Ken Fuhrman) <>
sc, as in QscClassName
Reserved by Sandro Sigala <>
sk, as in QskClassName
Reserved by Stephan Kanthak <>
ts, as in QtsClassName
Reserved by Thomas Schneider <>
ut, as in QutClassName
Reserved by Udo Tremel <>
vs, as in QvsClassName
Reserved by Vladi Shabanski <>
zn, as in QznClassName
Reserved by Zdravko Nezic <>

Triple Letter Prefixes
akk, as in QakkClassName
Reserved by Ari Kautonen <>
bal, as in QbalClassName
Reserved by Paul Kramer <>
cis, as in QcisClassName
Reserved by David Alex Lamb <>
dtc, as in QdtcClassName
Reserved by Eric Liao <>
dti, as in QdtiClassName
Reserved by Davis Tool Inc. <>
eiv, as in QeivClassName
Reserved by Patrick BURNAND <>
hle, as in QhleClassName
Reserved by Ricardo Vaz Mannrich <>
isr, as in QisrClassName
Reserved by Joseph Davis <>
ics, as in QicsClassName
Reserved by Mark Hatch < mhatch at ics dot com>
jfm, as in QjfmClassName
Reserved by John F. Meinel Jr. <>
kts, as in QktsClassName
Reserved by Keith Brown <>
log, as in QlogClassName
Reserved by Kevin Fisk <>
mag, as in QmagClassName
Reserved by Magic Touch Ltd <>
mat, as in QmatClassName
Reserved by Mark Thomas <>
maj, as in QmajClassName
Reserved by Mark Jones <>
mcm, as in QmcmClassName
Reserved by Steven Clark <>
mms, as in QmmsClassName
Reserved by Max Strumia <>
mud, as in QmudClassName
Reserved by Fontani Marco <>
mvd, as in QmvdClassName
Reserved by Mark van Dijk <>
nab, as in QnabClassName
Reserved by Nick Bastin <>
ool, as in QoolClassName
Reserved by Alexey V. Samsonoff <>
pag, as in QpagClassName
Reserved by Paul Gearon <>
red, as in QredClassName
Reserved by Alex Makarenko <>
rjp, as in QrjpClassName
Reserved by Richard J. Pontefrac <>
ryk, as in QrykClassName
Reserved by Krystian Bate <>
sks, as in QsksClassName
Reserved by Sean Kendall Schneyer <>
smh, as in QsmhClassName
Reserved by Sascha M. Hagner <>
taj, as in QtajClassName
Reserved by Sirtaj Singh Kang <ssk@physics.unimelb.EDU.AU>
tam, as in QtamClassName
Reserved by Paul Gearon <>
tec, as in QtecClassName
Reserved by HEITEC Datentechnik GmbH, Stefan Hundhammer <>
ube, as in QubeClassName
Reserved by Reinhard Lackner <>
uik, as in QuikClassName
Reserved by Mike Perik <>
uiz, as in QuizClassName
Reserved by Richard D. Jackson <>
uux, as in QuuxClassName
Reserved by Paul Foley <>
wav, as in QwavClassName
Reserved by Peter Eschle <>

Header File Example
You have reserved the prefix "ute" and want to release a class called Mountain, You put the code in the directory "qute", the header file
looks like this:
** Definition of QuteMountain
** Copyright (C) 1996 Harald Acker.
** QuteMountain is free software; you can redistribute
** it and/or modify it under the terms of the GNU
** Library General Public License as published by the
** Free Software Foundation; either version 2, or (at
** your option) any later version.

#ifndef QuteMOUNTAIN_H
#define QuteMOUNTAIN_H

#include <qframe.h>

enum QuteWeather { QuteSunshine, QuteOvercast,
            QuteCloudy, QuteRain,
            QuteThunderstorm, QuteSnow };

QuteWeather qutePollWeatherStation();

class QuteMountain : public QFrame
    QuteMountain( QWidget *parent=0, const char *name=0 );
    QuteMountain( QuteWeather w,
    QWidget *parent=0, const char *name=0 );

    bool    hasNiceWeather() const;

public slots:
    void    climbIt();

    void    weatherChanged();

    void    resizeEvent( QResizeEvent * );
    void    drawContents( QPainter * );

    QuteWeather weather;

private:  // Disabled copy constructor and operator=
    QuteMountain( const QuteMountain & ) {}
    QuteMountain &operator=( const QuteMountain & )
 { return *this; }

#endif // QuteMOUNTAIN_H