4 This file is part of Kleopatra, the KDE keymanager
5 Copyright (c) 2001,2002,2004 Klarälvdalens Datakonsult AB
7 Kleopatra is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License as published by
9 the Free Software Foundation; either version 2 of the License, or
10 (at your option) any later version.
12 Kleopatra is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15 General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 In addition, as a special exception, the copyright holders give
22 permission to link the code of this program with any edition of
23 the Qt library by Trolltech AS, Norway (or with modified versions
24 of Qt that use the same license as Qt), and distribute linked
25 combinations including the two. You must obey the GNU General
26 Public License in all respects for all of the code used other than
27 Qt. If you modify this file, you may extend this exception to
28 your version of the file, but you are not obligated to do so. If
29 you do not wish to do so, delete this exception statement from
33 #include <config-kleopatra.h>
34 #include <version-kleopatra.h>
36 #include "aboutdata.h"
38 #include <utils/gnupg-helper.h>
41 #include <kiconloader.h>
46 #include <QTextStream>
52 static const char kleopatra_version
[] = KLEOPATRA_VERSION_STRING
;
53 static const char description
[] = I18N_NOOP("Certificate Manager and Unified Crypto GUI");
62 static const about_data authors
[] = {
63 { "Marc Mutz", I18N_NOOP("Current Maintainer"), "mutz@kde.org", 0 },
64 { "Steffen Hansen", I18N_NOOP("Former Maintainer"), "hansen@kde.org", 0 },
65 { "Matthias Kalle Dalheimer", I18N_NOOP("Original Author"), "kalle@kde.org", 0 },
69 static const about_data credits
[] = {
70 { I18N_NOOP("David Faure"),
71 I18N_NOOP("Backend configuration framework, KIO integration"),
73 { I18N_NOOP("Michel Boyer de la Giroday"),
74 I18N_NOOP("Key-state dependent colors and fonts in the certificates list"),
75 "michel@klaralvdalens-datakonsult.se", 0 },
76 { I18N_NOOP("Thomas Moenicke"),
79 { I18N_NOOP("Frank Osterfeld"),
80 I18N_NOOP("Resident gpgme/win wrangler, UI Server commands and dialogs"),
81 "osterfeld@kde.org", 0 },
82 { I18N_NOOP("Karl-Heinz Zimmer"),
83 I18N_NOOP("DN display ordering support, infrastructure"),
88 AboutData::AboutData()
89 : KAboutData( "kleopatra", 0, ki18n("Kleopatra"),
90 kleopatra_version
, ki18n(description
), License_GPL
,
91 ki18n("(c) 2002 Steffen\xC2\xA0Hansen, Matthias\xC2\xA0Kalle\xC2\xA0" "Dalheimer, Klar\xC3\xA4lvdalens\xC2\xA0" "Datakonsult\xC2\xA0" "AB\n"
92 "(c) 2004, 2007, 2008, 2009 Marc\xC2\xA0Mutz, Klar\xC3\xA4lvdalens\xC2\xA0" "Datakonsult\xC2\xA0" "AB") )
96 for ( unsigned int i
= 0 ; i
< sizeof authors
/ sizeof *authors
; ++i
)
97 addAuthor( ki18n(authors
[i
].name
), ki18n(authors
[i
].desc
),
98 authors
[i
].email
, authors
[i
].web
);
99 for ( unsigned int i
= 0 ; i
< sizeof credits
/ sizeof *credits
; ++i
)
100 addCredit( ki18n(credits
[i
].name
), ki18n(credits
[i
].desc
),
101 credits
[i
].email
, credits
[i
].web
);
105 static const char gpg4win_description
[] = I18N_NOOP( "Gpg4win is an installer package for Windows for EMail and "
106 "file encryption using the core component GnuPG for Windows. "
107 "Both relevant cryptography standards are supported, OpenPGP "
108 "and S/MIME. Gpg4win and the software included with Gpg4win "
109 "are Free Software.");
111 static const char gpg4win_version_guessed
[] = "2.0.1";
113 static QString
gpg4win_version() {
116 p
.setReadChannelMode( QProcess::MergedChannels
);
117 p
.start( gpgConfPath(), QStringList( QLatin1String( "--version" ) ) );
118 if ( !p
.waitForFinished() )
119 return QString::fromLatin1( "%1 (%2)" ).arg( QLatin1String( gpg4win_version_guessed
),
120 i18nc("Version string is a guess","guessed") );
121 const QString output
= QTextStream( &p
).readAll() ;
122 QRegExp
rx( QLatin1String( "\\(Gpg4win\\s+([^\\s)]+)\\)" ) );
123 if ( rx
.indexIn( output
) != -1 )
126 return QString::fromLatin1( "%1 (%2)" ).arg( QLatin1String( gpg4win_version_guessed
),
127 i18nc("Version string is a guess","guessed") );
131 static QPixmap
UserIcon_nocached2( const char * name
) {
132 // KIconLoader insists on caching all pixmaps. Since the splash
133 // screen is a particularly large 'icon' and used only once,
134 // caching is unneccesary and just hurts startup performance.
135 KIconLoader
* const il
= KIconLoader::global();
137 const QString iconPath
= il
->iconPath( QLatin1String( name
), KIconLoader::User
);
138 return iconPath
.isEmpty() ? il
->unknown() : QPixmap( iconPath
) ;
142 AboutGpg4WinData::AboutGpg4WinData()
143 : KAboutData( "gpg4win", 0, ki18n("Gpg4win"),
144 gpg4win_version().toLatin1(), ki18n(gpg4win_description
),
145 License_GPL
, KLocalizedString(), KLocalizedString(), "http://www.gpg4win.de" )
147 addAuthor( ki18n("Intevation GmbH (Project Management)"), KLocalizedString(), 0, "http://www.intevation.de" );
148 addAuthor( ki18n("g\xC2\xB9\xC2\xBA" "code GmbH (Crypto Functionality, GpgOL, GpgEX, GPA)"), KLocalizedString(), 0, "http://www.g10code.de" );
149 addAuthor( ki18n("KDAB (Kleopatra)"), KLocalizedString(), 0, "http://www.kdab.com" );
150 setCustomAuthorText( ki18n("Gpg4win is being developed by the following companies:"),
151 ki18n("Gpg4win is being developed by the following companies:") );
152 setProgramLogo( UserIcon_nocached2( "gpg4win" ) );