21 #include "kdepim-version.h"
24 #include <kcmdlineargs.h>
25 #include <kaboutdata.h>
27 #include <kxerrorhandler.h>
31 #include <X11/Xatom.h>
39 int main(
int argc,
char *argv[] )
41 KAboutData aboutData(
"knotes",
46 KAboutData::License_GPL,
47 ki18n(
"Copyright © 1997–2013 KNotes authors" ) );
51 KCmdLineArgs::init( argc, argv, &aboutData );
57 KUniqueApplication::addCmdLineOptions();
63 KGlobal::locale()->insertCatalog(QLatin1String(
"libkdepim"));
75 unsigned long nitems = 0;
76 unsigned long extra = 0;
77 unsigned char *data = 0;
80 char *atom_names[ 2 ] = { (
char * )
"WM_CLIENT_LEADER",
81 (
char * )
"SM_CLIENT_ID" };
83 XInternAtoms( QX11Info::display(), atom_names, 2, False, atoms );
86 KXErrorHandler handler;
87 status = XGetWindowProperty( QX11Info::display(), w.winId(), atoms[ 0 ], 0,
88 10000,
false, XA_WINDOW, &type, &format, &nitems,
91 if ( ( status == Success ) && !handler.error(
false ) ) {
92 if ( data && ( nitems > 0 ) ) {
93 Window leader = * ( ( Window * ) data );
94 XDeleteProperty( QX11Info::display(), leader, atoms[ 1 ] );
103 KCmdLineOptions options;
105 options.add(
"skip-note",
106 ki18n(
"Suppress creation of a new note "
107 "on a non-unique instance." ) );
114 aboutData.addAuthor( ki18n(
"Guillermo Antonio Amaral Bastidas" ),
115 ki18n(
"Maintainer" ),
116 "me@guillermoamaral.com" );
117 aboutData.addAuthor( ki18n(
"Michael Brade" ),
118 ki18n(
"Previous Maintainer" ),
120 aboutData.addAuthor( ki18n(
"Bernd Johannes Wuebben" ),
121 ki18n(
"Original KNotes Author" ),
123 aboutData.addAuthor( ki18n(
"Wynn Wilkes" ),
124 ki18n(
"Ported KNotes to KDE 2" ),
125 "wynnw@calderasystems.com" );
126 aboutData.addAuthor( ki18n(
"Daniel Martin" ),
127 ki18n(
"Network Interface" ),
128 "daniel.martin@pirack.com" );
129 aboutData.addAuthor( ki18n(
"Bo Thorsen" ),
130 ki18n(
"Started KDE Resource Framework Integration" ),
133 aboutData.addCredit( ki18n(
"Bera Debajyoti" ),
134 ki18n(
"Idea and initial code for the new look & feel" ),
135 "debajyotibera@gmail.com" );
136 aboutData.addCredit( ki18n(
"Matthias Ettrich" ),
139 aboutData.addCredit( ki18n(
"David Faure" ),
142 aboutData.addCredit( ki18n(
"Matthias Kiefer" ),
145 aboutData.addCredit( ki18n(
"Luboš Luňák" ),
148 aboutData.addCredit( ki18n(
"Laurent Montel" ),
151 aboutData.addCredit( ki18n(
"Dirk A. Mueller" ),
154 aboutData.addCredit( ki18n(
"Carsten Pfeiffer" ),
156 "pfeiffer@kde.org" );
157 aboutData.addCredit( ki18n(
"Harri Porten" ),
160 aboutData.addCredit( ki18n(
"Espen Sand" ),
KCmdLineOptions knotesOptions()
void knotesAuthors(KAboutData &aboutData)
void remove_sm_from_client_leader()
int main(int argc, char *argv[])