File indexing completed on 2024-05-19 07:30:26

0001 /*
0002     This file is part of Kiten, a KDE Japanese Reference Tool
0003     SPDX-FileCopyrightText: 2011 Daniel E. Moctezuma <democtezuma@gmail.com>
0004 
0005     SPDX-License-Identifier: LGPL-2.0-or-later
0006 */
0007 
0008 #include <QApplication>
0009 
0010 #include "kanjibrowser.h"
0011 #include <KAboutData>
0012 #include <KLocalizedString>
0013 
0014 int main(int argc, char **argv)
0015 {
0016     QApplication app(argc, argv);
0017     app.setWindowIcon(QIcon::fromTheme(QStringLiteral("kiten"), app.windowIcon()));
0018     KLocalizedString::setApplicationDomain("kiten");
0019 
0020     KAboutData about(QStringLiteral("kitenkanjibrowser"),
0021                      i18n("Kanji Browser"),
0022                      QStringLiteral("1.0"),
0023                      i18n("Kiten's Kanji Browser, a KDE Japanese Reference Tool"),
0024                      KAboutLicense::GPL_V2,
0025                      i18n("(C) 2011 Daniel E. Moctezuma"),
0026                      QString(),
0027                      QStringLiteral("https://apps.kde.org/kiten"),
0028                      QStringLiteral("democtezuma@gmail.com"));
0029     about.addAuthor(i18n("Daniel E. Moctezuma"), QString(), QStringLiteral("democtezuma@gmail.com"));
0030     about.setOrganizationDomain("kde.org");
0031 
0032     KAboutData::setApplicationData(about);
0033 
0034 #ifdef Q_OS_WIN
0035     QApplication::setStyle(QStringLiteral("breeze"));
0036 #endif
0037 
0038     if (app.isSessionRestored()) {
0039         kRestoreMainWindows<KanjiBrowser>();
0040     } else {
0041         auto kanjiBrowser = new KanjiBrowser();
0042         kanjiBrowser->show();
0043     }
0044 
0045     return app.exec();
0046 }