don't compile ksayit (need arts)
[kdeaccessibility.git] / kmouth / main.cpp
blob71fbb48e4b22685bf52a47d3b800437be50c8029
1 /***************************************************************************
2 main.cpp - description
3 -------------------
4 begin : Mon Aug 26 15:41:23 CEST 2002
5 copyright : (C) 2002 by Gunnar Schmi Dt
6 email : kmouth@schmi-dt.de
7 ***************************************************************************/
9 /***************************************************************************
10 * *
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
15 * *
16 ***************************************************************************/
19 #include <kcmdlineargs.h>
20 #include <kaboutdata.h>
21 #include <klocale.h>
22 #include <kuniqueapplication.h>
24 #include "kmouth.h"
25 #include "version.h"
27 static const char description[] =
28 I18N_NOOP("A type-and-say front end for speech synthesizers");
29 // INSERT A DESCRIPTION FOR YOUR APPLICATION HERE
32 static KCmdLineOptions options[] =
34 { "+[File]", I18N_NOOP("History file to open"), 0 },
35 KCmdLineLastOption
36 // INSERT YOUR COMMANDLINE OPTIONS HERE
39 int main(int argc, char *argv[])
42 KAboutData aboutData( "kmouth", I18N_NOOP("KMouth"),
43 KMOUTH_VERSION, description, KAboutData::License_GPL,
44 "(c) 2002/2003, Gunnar Schmi Dt", 0, "http://www.schmi-dt.de/kmouth/index.en.html", "kmouth@schmi-dt.de");
45 aboutData.addAuthor("Gunnar Schmi Dt",0, "kmouth@schmi-dt.de");
46 KCmdLineArgs::init( argc, argv, &aboutData );
47 KCmdLineArgs::addCmdLineOptions( options ); // Add our own options.
49 aboutData.addCredit("Olaf Schmidt", I18N_NOOP("Tips, extended phrase books"), 0, 0);
50 KApplication app;
52 if (app.isSessionRestored())
54 RESTORE(KMouthApp);
56 else
58 KMouthApp *kmouth = new KMouthApp();
59 if (!kmouth->configured())
60 return 0;
62 kmouth->show();
64 KCmdLineArgs *args = KCmdLineArgs::parsedArgs();
66 if (args->count())
68 kmouth->openDocumentFile(args->url(0));
70 args->clear();
72 return app.exec();