KclockModule::KclockModule(QWidget *parent, const char *name, const QStringList &) : KCModule(KlockModuleFactory::instance(), parent, name) { KAboutData *about = new KAboutData(I18N_NOOP("kcmclock"), I18N_NOOP("KDE Clock Control Module"), 0, 0, KAboutData::License_GPL, "(c) 1996 - 2001 Luca Montecchiani"); about->addAuthor("Luca Montecchiani", I18N_NOOP("Original author"), "*****@*****.**"); about->addAuthor("Paul Campbell", I18N_NOOP("Current Maintainer"), "*****@*****.**"); about->addAuthor("Benjamin Meyer", I18N_NOOP("Added NTP support"), "*****@*****.**"); setAboutData(about); setQuickHelp( i18n("<h1>Date & Time</h1> This control module can be used to set the system date and" " time. As these settings do not only affect you as a user, but rather the whole system, you" " can only change these settings when you start the Control Center as root. If you do not have" " the root password, but feel the system time should be corrected, please contact your system" " administrator.")); KGlobal::locale()->insertCatalogue("timezones"); // For time zone translations QVBoxLayout *layout = new QVBoxLayout(this, 0, KDialog::spacingHint()); dtime = new Dtime(this); layout->addWidget(dtime); connect(dtime, SIGNAL(timeChanged(bool)), this, SIGNAL(changed(bool))); tzone = new Tzone(this); layout->addWidget(tzone); connect(tzone, SIGNAL(zoneChanged(bool)), this, SIGNAL(changed(bool))); layout->addStretch(); if(getuid() == 0) setButtons(Help | Apply); else setButtons(Help); }
KCMKOrgSummary::KCMKOrgSummary(QWidget *parent, const char *name) : KCModule(parent, name) { initGUI(); customDaysChanged(1); connect(mCalendarGroup, SIGNAL(clicked(int)), SLOT(modified())); connect(mCalendarGroup, SIGNAL(clicked(int)), SLOT(buttonClicked(int))); connect(mTodoGroup, SIGNAL(clicked(int)), SLOT(modified())); connect(mCustomDays, SIGNAL(valueChanged(int)), SLOT(modified())); connect(mCustomDays, SIGNAL(valueChanged(int)), SLOT(customDaysChanged(int))); KAcceleratorManager::manage(this); load(); KAboutData *about = new KAboutData(I18N_NOOP("kcmkorgsummary"), I18N_NOOP("Schedule Configuration Dialog"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2003 - 2004 Tobias Koenig")); about->addAuthor("Tobias Koenig", 0, "*****@*****.**"); setAboutData(about); }
KcmKRfb::KcmKRfb(QWidget *p, const char *name, const QStringList &) : KCModule(KcmKRfbFactory::instance(), p, name), m_configuration(KRFB_CONFIGURATION_MODE) { m_confWidget = new ConfigurationWidget(this); QVBoxLayout *l = new QVBoxLayout(this, 0, KDialog::spacingHint()); l->add(m_confWidget); setButtons(Default|Apply|Reset); KAboutData* about = new KAboutData( "kcm_krfb", I18N_NOOP("Desktop Sharing Control Module"), VERSION, I18N_NOOP("Configure desktop sharing"), KAboutData::License_GPL, "(c) 2002, Tim Jansen\n", 0, "http://www.tjansen.de/krfb", "*****@*****.**"); about->addAuthor("Tim Jansen", 0, "*****@*****.**"); setAboutData( about ); load(); connect(m_confWidget->passwordInput, SIGNAL(textChanged(const QString&)), SLOT(configChanged()) ); connect(m_confWidget->allowUninvitedCB, SIGNAL(clicked()), SLOT(configChanged()) ); connect(m_confWidget->enableSLPCB, SIGNAL(clicked()), SLOT(configChanged()) ); connect(m_confWidget->confirmConnectionsCB, SIGNAL(clicked()), SLOT(configChanged()) ); connect(m_confWidget->allowDesktopControlCB, SIGNAL(clicked()), SLOT(configChanged()) ); connect(m_confWidget->autoPortCB, SIGNAL(clicked()), SLOT(configChanged()) ); connect(m_confWidget->portInput, SIGNAL(valueChanged(int)), SLOT(configChanged()) ); connect((QObject*)m_confWidget->manageInvitations, SIGNAL(clicked()), &m_configuration, SLOT(showManageInvitationsDialog()) ); connect(&m_configuration, SIGNAL(invitationNumChanged(int)), this, SLOT(setInvitationNum(int))); setInvitationNum(m_configuration.invitations().size()); connect(m_confWidget->disableBackgroundCB, SIGNAL(clicked()), SLOT(configChanged()) ); }
KCMCgi::KCMCgi(QWidget *parent, const char *name) : KCModule(parent, name) { setButtons(Default|Apply); QVBoxLayout *topLayout = new QVBoxLayout(this, 0, KDialog::spacingHint()); QGroupBox *topBox = new QGroupBox( 1, Horizontal, i18n("Paths to Local CGI Programs"), this ); topLayout->addWidget( topBox ); mListBox = new QListBox( topBox ); QHBox *buttonBox = new QHBox( topBox ); buttonBox->setSpacing( KDialog::spacingHint() ); mAddButton = new QPushButton( i18n("Add..."), buttonBox ); connect( mAddButton, SIGNAL( clicked() ), SLOT( addPath() ) ); mRemoveButton = new QPushButton( i18n("Remove"), buttonBox ); connect( mRemoveButton, SIGNAL( clicked() ), SLOT( removePath() ) ); connect( mListBox, SIGNAL( clicked ( QListBoxItem * )),this, SLOT( slotItemSelected( QListBoxItem *))); mConfig = new KConfig("kcmcgirc"); load(); updateButton(); KAboutData *about = new KAboutData( I18N_NOOP("kcmcgi"), I18N_NOOP("CGI KIO Slave Control Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2002 Cornelius Schumacher") ); about->addAuthor( "Cornelius Schumacher", 0, "*****@*****.**" ); setAboutData(about); }
KPlatoWork_Application::KPlatoWork_Application(int argc, char **argv) : QApplication(argc, argv), m_mainwindow( 0 ) { KAboutData *aboutData = KPlatoWork::newAboutData(); KAboutData::setApplicationData( *aboutData ); setWindowIcon(QIcon::fromTheme(QStringLiteral("calligraplanwork"))); aboutData->setupCommandLine(&m_commandLineParser); m_commandLineParser.addHelpOption(); m_commandLineParser.addVersionOption(); m_commandLineParser.addPositionalArgument(QStringLiteral("[file]"), i18n("File to open")); m_commandLineParser.process(*this); aboutData->processCommandLine(&m_commandLineParser); // Tell the iconloader about share/apps/calligra/icons /* KIconLoader::global()->addAppDir("calligra"); // Initialize all Calligra directories etc. KoGlobal::initialize(); new KoApplicationAdaptor(this); QDBusConnection::sessionBus().registerObject("/application", this);*/ delete aboutData; }
int main(int argc, char **argv) { QApplication app(argc, argv); KAboutData about = newBrainDumpAboutData(); KAboutData::setApplicationData(about); QCommandLineParser parser; parser.addVersionOption(); parser.addHelpOption(); parser.process(app); about.setupCommandLine(&parser); about.processCommandLine(&parser); KIconLoader::global()->addAppDir("calligra"); KoGlobal::initialize(); RootSection* doc = new RootSection; MainWindow* window = new MainWindow(doc); window->setVisible(true); app.exec(); // Ensure the root section is saved doc->sectionsIO()->save(); delete doc; app.exit(0); }
TaskbarConfig::TaskbarConfig(QWidget *parent, const char *name, const QStringList &) : KCModule(TaskBarFactory::instance(), parent, name) { QVBoxLayout *layout = new QVBoxLayout(this, 0, KDialog::spacingHint()); m_widget = new TaskbarConfigUI(this); layout->addWidget(m_widget); // TODO: Load these from .desktop files? m_appearances.append(TaskbarAppearance(i18n("Elegant"), false, false, true)); m_appearances.append(TaskbarAppearance(i18n("Classic"), true, false, true)); m_appearances.append(TaskbarAppearance(i18n("For Transparency"), false, true, true)); for(TaskbarAppearance::List::const_iterator it = m_appearances.constBegin(); it != m_appearances.constEnd(); ++it) { m_widget->appearance->insertItem((*it).name()); } connect(m_widget->appearance, SIGNAL(activated(int)), this, SLOT(appearanceChanged(int))); addConfig(TaskBarSettings::self(), m_widget); setQuickHelp( i18n("<h1>Taskbar</h1> You can configure the taskbar here." " This includes options such as whether or not the taskbar should show all" " windows at once or only those on the current desktop." " You can also configure whether or not the Window List button will be displayed.")); QStringList list = i18nActionList(); m_widget->kcfg_LeftButtonAction->insertStringList(list); m_widget->kcfg_MiddleButtonAction->insertStringList(list); m_widget->kcfg_RightButtonAction->insertStringList(list); m_widget->kcfg_GroupTasks->insertStringList(i18nGroupModeList()); connect(m_widget->kcfg_GroupTasks, SIGNAL(activated(int)), this, SLOT(slotUpdateComboBox())); connect(m_widget->kcfg_UseCustomColors, SIGNAL(stateChanged(int)), this, SLOT(slotUpdateCustomColors())); slotUpdateCustomColors(); updateAppearanceCombo(); if(KWin::numberOfDesktops() < 2) { m_widget->kcfg_ShowAllWindows->hide(); m_widget->kcfg_SortByDesktop->hide(); m_widget->spacer2->changeSize(0, 0); } if(!QApplication::desktop()->isVirtualDesktop() || QApplication::desktop()->numScreens() == 1) // No Ximerama { m_widget->showAllScreens->hide(); } connect(m_widget->showAllScreens, SIGNAL(stateChanged(int)), SLOT(changed())); KAboutData *about = new KAboutData(I18N_NOOP("kcmtaskbar"), I18N_NOOP("KDE Taskbar Control Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2000 - 2001 Matthias Elter")); about->addAuthor("Matthias Elter", 0, "*****@*****.**"); about->addCredit("Stefan Nikolaus", I18N_NOOP("KConfigXT conversion"), "*****@*****.**"); setAboutData(about); load(); QTimer::singleShot(0, this, SLOT(notChanged())); }
KCMKontactSummary::KCMKontactSummary( const KComponentData &inst, QWidget *parent ) : KCModule( inst, parent ) { setButtons( NoAdditionalButton ); QVBoxLayout *layout = new QVBoxLayout( this ); layout->setSpacing( KDialog::spacingHint() ); layout->setMargin( 0 ); QLabel *label = new QLabel( i18n( "Select the plugin summaries to show on the summary page." ), this ); layout->addWidget( label ); mPluginView = new PluginView( this ); layout->addWidget( mPluginView ); layout->setStretchFactor( mPluginView, 1 ); load(); connect( mPluginView, SIGNAL(itemChanged(QTreeWidgetItem*,int)), this, SLOT(changed()) ); KAboutData *about = new KAboutData( I18N_NOOP( "kontactsummary" ), 0, ki18n( "KDE Kontact Summary" ), 0, KLocalizedString(), KAboutData::License_GPL, ki18n( "(c), 2004 Tobias Koenig" ) ); about->addAuthor( ki18n( "Tobias Koenig" ), KLocalizedString(), "*****@*****.**" ); setAboutData( about ); }
KCMNic::KCMNic(QWidget *parent, const char *name, const QStringList &) : KCModule(KCMNicFactory::instance(), parent, name) { QVBoxLayout *box = new QVBoxLayout(this, 0, KDialog::spacingHint()); m_list = new QListView(this); box->addWidget(m_list); m_list->addColumn(i18n("Name")); m_list->addColumn(i18n("IP Address")); m_list->addColumn(i18n("Network Mask")); m_list->addColumn(i18n("Type")); m_list->addColumn(i18n("State")); m_list->addColumn(i18n("HWaddr")); m_list->setAllColumnsShowFocus(true); QHBoxLayout *hbox = new QHBoxLayout(box); m_updateButton = new QPushButton(i18n("&Update"), this); hbox->addWidget(m_updateButton); hbox->addStretch(1); QTimer *timer = new QTimer(this); timer->start(60000); connect(m_updateButton, SIGNAL(clicked()), this, SLOT(update())); connect(timer, SIGNAL(timeout()), this, SLOT(update())); update(); KAboutData *about = new KAboutData(I18N_NOOP("kcminfo"), I18N_NOOP("KDE Panel System Information Control Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2001 - 2002 Alexander Neundorf")); about->addAuthor("Alexander Neundorf", 0, "*****@*****.**"); setAboutData(about); }
KAboutData *KopeteRichTextEditPart::createAboutData() { KAboutData *aboutData = new KAboutData("kopeterichtexteditpart", I18N_NOOP("KopeteRichTextEditPart"), "0.1", I18N_NOOP("A simple rich text editor part for Kopete"), KAboutData::License_LGPL ); aboutData->addAuthor("Richard J. Moore", 0, "*****@*****.**", "http://xmelegance.org/" ); aboutData->addAuthor("Jason Keirstead", 0, "*****@*****.**", "http://www.keirstead.org/" ); return aboutData; }
KAboutData *NoteeditFactory::aboutData() { KAboutData *about = new KAboutData ("noteedit", I18N_NOOP("NoteEdit"), VERSION, "a KDE3/Qt3 based note editor.\nFor help subscribe to one of the\nmailing lists, or post a message\nin one of the public forums. See", KAboutData::License_GPL, 0, 0, //"http://rnvs.informatik.tu-chemnitz.de/~jan/noteedit/noteedit.html", "http://developer.berlios.de/projects/noteedit", ADDRESS); about->addAuthor ("Joerg Anders", I18N_NOOP("Main author"), ADDRESS); about->addAuthor ("Christian Fasshauer", I18N_NOOP("programmer"), "*****@*****.**"); #ifdef WITH_TSE3 about->addAuthor ("Pete Goodliffe", I18N_NOOP("TSE3 sequencer library"), "*****@*****.**"); #endif about->addAuthor("Erik Sigra", I18N_NOOP("developer"), "*****@*****.**"); about->addAuthor ("David Faure", I18N_NOOP("KDE User Interface"), "*****@*****.**"); about->addAuthor("Matt Gerassimoff", 0, "*****@*****.**"); about->addAuthor ("Leon Vinken", I18N_NOOP("MusicXML interface"), "*****@*****.**"); about->addAuthor("Georg Rudolph", I18N_NOOP("lilypond interface"), "*****@*****.**"); return about; }
PcmciaConfig::PcmciaConfig (QWidget * parent, const char *name) : KCModule(parent, name) { KAboutData *about = new KAboutData(I18N_NOOP("kcmlaptop"), I18N_NOOP("KDE Panel System Information Control Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 1999 - 2002 Paul Campbell")); about->addAuthor("Paul Campbell", 0, "*****@*****.**"); setAboutData( about ); KGlobal::locale()->insertCatalogue("klaptopdaemon"); // For translation of klaptopdaemon messages label0 = laptop_portable::pcmcia_info(0, this); label0_text = laptop_portable::pcmcia_info(1, this); label1 = laptop_portable::pcmcia_info(2, this); label1_text = laptop_portable::pcmcia_info(3, this); QVBoxLayout *top_layout = new QVBoxLayout(this, 15, 5); QGridLayout *top_grid = new QGridLayout(2, 2); top_layout->addLayout(top_grid); top_grid->setColStretch(0, 0); top_grid->setColStretch(1, 1); top_grid->addRowSpacing(0, 40); top_grid->addRowSpacing(1, 40); label0->setFixedSize(80, 24); top_grid->addWidget(label0, 0, 0); label0_text->adjustSize(); top_grid->addWidget(label0_text, 0, 1); label1->setFixedSize(80, 24); top_grid->addWidget(label1, 1, 0); label1_text->adjustSize(); top_grid->addWidget(label1_text, 1, 1); top_layout->addStretch(1); QHBoxLayout *v1 = new QHBoxLayout; top_layout->addLayout(v1, 0); v1->addStretch(1); QString s1 = LAPTOP_VERSION; QString s2 = i18n("Version: ")+s1; QLabel* vers = new QLabel(s2, this); vers->setMinimumSize(vers->sizeHint()); v1->addWidget(vers, 0); top_layout->activate(); load(); setButtons(Help); }
Module::Module(QWidget *parent, const QVariantList &args) : KCModule(parent, args) , ui(new Ui::Module) , m_manager(new DriverManager(this)) { KAboutData *aboutData = new KAboutData("kcm-driver-manager", i18n("Driver Manager"), global_s_versionStringFull, QStringLiteral(""), KAboutLicense::LicenseKey::GPL_V3, i18n("Copyright 2013 Rohan Garg")); aboutData->addAuthor(i18n("Rohan Garg"), i18n("Author"), QStringLiteral("*****@*****.**")); aboutData->addAuthor(i18n("Harald Sitter"), i18n("Qt 5 port"), QStringLiteral("*****@*****.**")); setAboutData(aboutData); // We have no help so remove the button from the buttons. setButtons(buttons() ^ KCModule::Help); ui->setupUi(this); ui->progressBar->setVisible(false); connect(ui->reloadButton, SIGNAL(clicked(bool)), SLOT(load())); m_overlay = new KPixmapSequenceOverlayPainter(this); m_overlay->setWidget(this); #warning variable name QString label = xi18nc("@title/rich", "<title>Your computer requires no proprietary drivers</title>"); m_label = new QLabel(label, this); m_label->hide(); ui->driverOptionsVLayout->addWidget(m_label); //Debconf handling QString uuid = QUuid::createUuid().toString(); uuid.remove('{').remove('}').remove('-'); m_pipe = QDir::tempPath() % QLatin1String("/qapt-sock-") % uuid; m_debconfGui = new DebconfKde::DebconfGui(m_pipe, this); m_debconfGui->connect(m_debconfGui, SIGNAL(activated()), this, SLOT(showDebconf())); m_debconfGui->connect(m_debconfGui, SIGNAL(deactivated()), this, SLOT(hideDebconf())); m_debconfGui->hide(); connect(m_manager, SIGNAL(refreshFailed()), this, SLOT(onRefreshFailed())); connect(m_manager, SIGNAL(devicesReady(DeviceList)), this, SLOT(onDevicesReady(DeviceList))); connect(m_manager, SIGNAL(changeProgressChanged(int)), this, SLOT(progressChanged(int))); connect(m_manager, SIGNAL(changeFinished()), this, SLOT(finished())); connect(m_manager, SIGNAL(changeFailed(QString)), this, SLOT(failed(QString))); }
NotesAgentSettingsDialog::NotesAgentSettingsDialog(QWidget *parent) : QDialog(parent) { setWindowTitle(i18n("Configure Notes Agent")); setWindowIcon(QIcon::fromTheme(QStringLiteral("knotes"))); QDialogButtonBox *buttonBox = new QDialogButtonBox(QDialogButtonBox::Ok | QDialogButtonBox::Cancel | QDialogButtonBox::Help, this); QVBoxLayout *mainLayout = new QVBoxLayout; setLayout(mainLayout); QPushButton *okButton = buttonBox->button(QDialogButtonBox::Ok); okButton->setDefault(true); okButton->setShortcut(Qt::CTRL | Qt::Key_Return); connect(buttonBox, &QDialogButtonBox::rejected, this, &NotesAgentSettingsDialog::reject); connect(okButton, &QPushButton::clicked, this, &NotesAgentSettingsDialog::slotOkClicked); setModal(true); QWidget *mainWidget = new QWidget(this); QHBoxLayout *lay = new QHBoxLayout(mainWidget); QTabWidget *tab = new QTabWidget; lay->addWidget(tab); mNotify = new KNotifyConfigWidget(this); mNotify->setApplication(QStringLiteral("akonadi_notes_agent")); tab->addTab(mNotify, i18n("Notify")); mNetworkConfig = new NoteShared::NoteNetworkConfigWidget(this); tab->addTab(mNetworkConfig, i18n("Network")); mNetworkConfig->load(); mainLayout->addWidget(mainWidget); mainLayout->addWidget(buttonBox); readConfig(); KAboutData aboutData = KAboutData( QStringLiteral("notesagent"), i18n("Notes Agent"), QStringLiteral(KNOTES_VERSION), i18n("Notes Agent."), KAboutLicense::GPL_V2, i18n("Copyright (C) 2013-2016 Laurent Montel")); aboutData.addAuthor(i18n("Laurent Montel"), i18n("Maintainer"), QStringLiteral("*****@*****.**")); QApplication::setWindowIcon(QIcon::fromTheme(QStringLiteral("knotes"))); aboutData.setTranslator(i18nc("NAME OF TRANSLATORS", "Your names"), i18nc("EMAIL OF TRANSLATORS", "Your emails")); KHelpMenu *helpMenu = new KHelpMenu(this, aboutData, true); //Initialize menu QMenu *menu = helpMenu->menu(); helpMenu->action(KHelpMenu::menuAboutApp)->setIcon(QIcon::fromTheme(QStringLiteral("knotes"))); buttonBox->button(QDialogButtonBox::Help)->setMenu(menu); }
KCMRules::KCMRules(QWidget *parent, const char *name) : KCModule(parent, name), config("kwinrulesrc") { QVBoxLayout *layout = new QVBoxLayout(this); widget = new KCMRulesList(this); layout->addWidget(widget); connect(widget, SIGNAL(changed(bool)), SLOT(moduleChanged(bool))); KAboutData *about = new KAboutData(I18N_NOOP("kcmkwinrules"), I18N_NOOP("Window-Specific Settings Configuration Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2004 KWin and KControl Authors")); about->addAuthor("Lubos Lunak", 0, "*****@*****.**"); setAboutData(about); }
const KAboutData * PrefsModule::aboutData() const { KAboutData *about = new KAboutData(I18N_NOOP("komposerconfig"), I18N_NOOP("KDE Komposer"), 0, 0, KAboutData::License_LGPL, I18N_NOOP("(c), 2003-2004 Zack Rusin")); about->addAuthor("Zack Rusin", 0, "*****@*****.**");; return about; }
const KAboutData* KcmKontact::aboutData() const { KAboutData *about = new KAboutData( I18N_NOOP( "kontactconfig" ), I18N_NOOP( "KDE Kontact" ), 0, 0, KAboutData::License_GPL, I18N_NOOP( "(c), 2003 Cornelius Schumacher" ) ); about->addAuthor( "Cornelius Schumacher", 0, "*****@*****.**" ); about->addAuthor( "Tobias Koenig", 0, "*****@*****.**" ); return about; }
int main ( int argc, char **argv ) { KAboutData about ( "kmilion", 0, ki18n ( "KMilion" ), version, ki18n ( description ), KAboutData::License_GPL, ki18n ( "(C) 2010 Mikołaj Sochacki" ), KLocalizedString(), 0, "*****@*****.**" ); about.addAuthor ( ki18n ( "Mikołaj Sochacki" ), KLocalizedString(), "*****@*****.**" ); KCmdLineArgs::init ( argc, argv, &about ); KCmdLineOptions options; options.add ( "+[URL]", ki18n ( "Document to open" ) ); KCmdLineArgs::addCmdLineOptions ( options ); KApplication app; KMilion *widget = new KMilion; const QRect r = app.desktop()->frameGeometry(); widget->setScreenSize ( r.width(), r.height() ); KCmdLineArgs *args; if ( app.isSessionRestored() ) { RESTORE ( KMilion ); } else { args = KCmdLineArgs::parsedArgs(); widget->show(); } args->clear(); // Tak jest w orginale nie mam pojęcia dlaczego? Szczególnie po co kilka razy show! //see if we are starting with session management // if (app.isSessionRestored()) // { // RESTORE(KMilion); // } // else // { // // no session.. just start up normally // KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); // if (args->count() == 0) // { // //kmilion *widget = new kmilion; // widget->show(); // } // else // { // int i = 0; // for (; i < args->count(); i++) // { // //kmilion *widget = new kmilion; // widget->show(); // } // } // args->clear(); // } return app.exec(); }
const KAboutData *KCMSDSummary::aboutData() const { KAboutData *about = new KAboutData(I18N_NOOP("kcmsdsummary"), I18N_NOOP("Special Dates Configuration Dialog"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2004 Tobias Koenig")); about->addAuthor("Tobias Koenig", 0, "*****@*****.**"); about->addAuthor("Allen Winter", 0, "*****@*****.**"); return about; }
KWinOptions::KWinOptions(QWidget *parent, const char *name) : KCModule(parent, name) { mConfig = new KConfig("kwinrc", false, true); QVBoxLayout *layout = new QVBoxLayout(this); tab = new QTabWidget(this); layout->addWidget(tab); mFocus = new KFocusConfig(false, mConfig, this, "KWin Focus Config"); mFocus->layout()->setMargin(KDialog::marginHint()); tab->addTab(mFocus, i18n("&Focus")); connect(mFocus, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); mTitleBarActions = new KTitleBarActionsConfig(false, mConfig, this, "KWin TitleBar Actions"); mTitleBarActions->layout()->setMargin(KDialog::marginHint()); tab->addTab(mTitleBarActions, i18n("&Titlebar Actions")); connect(mTitleBarActions, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); mWindowActions = new KWindowActionsConfig(false, mConfig, this, "KWin Window Actions"); mWindowActions->layout()->setMargin(KDialog::marginHint()); tab->addTab(mWindowActions, i18n("Window Actio&ns")); connect(mWindowActions, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); mMoving = new KMovingConfig(false, mConfig, this, "KWin Moving"); mMoving->layout()->setMargin(KDialog::marginHint()); tab->addTab(mMoving, i18n("&Moving")); connect(mMoving, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); mAdvanced = new KAdvancedConfig(false, mConfig, this, "KWin Advanced"); mAdvanced->layout()->setMargin(KDialog::marginHint()); tab->addTab(mAdvanced, i18n("Ad&vanced")); connect(mAdvanced, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); mTranslucency = new KTranslucencyConfig(false, mConfig, this, "KWin Translucency"); mTranslucency->layout()->setMargin(KDialog::marginHint()); tab->addTab(mTranslucency, i18n("&Translucency")); connect(mTranslucency, SIGNAL(changed(bool)), this, SLOT(moduleChanged(bool))); KAboutData *about = new KAboutData(I18N_NOOP("kcmkwinoptions"), I18N_NOOP("Window Behavior Configuration Module"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 1997 - 2002 KWin and KControl Authors")); about->addAuthor("Matthias Ettrich", 0, "*****@*****.**"); about->addAuthor("Waldo Bastian", 0, "*****@*****.**"); about->addAuthor("Cristian Tibirna", 0, "*****@*****.**"); about->addAuthor("Matthias Kalle Dalheimer", 0, "*****@*****.**"); about->addAuthor("Daniel Molkentin", 0, "*****@*****.**"); about->addAuthor("Wynn Wilkes", 0, "*****@*****.**"); about->addAuthor("Pat Dowler", 0, "*****@*****.**"); about->addAuthor("Bernd Wuebben", 0, "*****@*****.**"); about->addAuthor("Matthias Hoelzer-Kluepfel", 0, "*****@*****.**"); setAboutData(about); }
const KAboutData * ModuleView::aboutData() const { KCModuleProxy * activeModule = d->mPages.value( d->mPageWidget->currentPage() ); KAboutData * aboutData = 0; if( activeModule ) { aboutData = const_cast<KAboutData*>( activeModule->aboutData() ); } if ( aboutData ) { aboutData->setProgramIconName( activeModule->moduleInfo().service()->icon() ); return aboutData; } return 0; }
extern "C" KDE_EXPORT int kdemain (int argc, char *argv[]) { setsid (); KAboutData aboutData ("kmplayer", 0, ki18n("KMPlayer"), KMPLAYER_VERSION_STRING, ki18n ("Media player."), KAboutData::License_GPL, ki18n ("(c) 2002-2009, Koos Vriezen"), KLocalizedString(), I18N_NOOP ("http://kmplayer.kde.org")); aboutData.addAuthor(ki18n("Koos Vriezen"), ki18n("Maintainer"),"*****@*****.**"); KCmdLineArgs::init (argc, argv, &aboutData); KCmdLineOptions options; options.add ("+[File]", ki18n ("file to open")); KCmdLineArgs::addCmdLineOptions (options); KMPlayer::Ids::init(); KApplication app; QPointer <KMPlayerApp> kmplayer; if (app.isSessionRestored ()) { RESTORE (KMPlayerApp); } else { kmplayer = new KMPlayerApp (); kmplayer->show(); KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); KUrl url; if (args->count () == 1) url = args->url (0); if (args->count () > 1) for (int i = 0; i < args->count (); i++) { KUrl url = args->url (i); if (url.url ().indexOf ("://") < 0) url = KUrl (QFileInfo (url.url ()).absoluteFilePath ()); if (url.isValid ()) kmplayer->addUrl (url); } kmplayer->openDocumentFile (url); args->clear (); } int retvalue = app.exec (); delete kmplayer; KMPlayer::Ids::reset(); return retvalue; }
USBViewer::USBViewer(QWidget *parent, const char *name, const QStringList &) : KCModule(USBFactory::instance(), parent, name) { setButtons(Help); setQuickHelp( i18n("<h1>USB Devices</h1> This module allows you to see" " the devices attached to your USB bus(es).")); QVBoxLayout *vbox = new QVBoxLayout(this, 0, KDialog::spacingHint()); QGroupBox *gbox = new QGroupBox(i18n("USB Devices"), this); gbox->setColumnLayout(0, Qt::Horizontal); vbox->addWidget(gbox); QVBoxLayout *vvbox = new QVBoxLayout(gbox->layout(), KDialog::spacingHint()); QSplitter *splitter = new QSplitter(gbox); vvbox->addWidget(splitter); _devices = new QListView(splitter); _devices->addColumn(i18n("Device")); _devices->setRootIsDecorated(true); _devices->header()->hide(); _devices->setMinimumWidth(200); _devices->setColumnWidthMode(0, QListView::Maximum); QValueList< int > sizes; sizes.append(200); splitter->setSizes(sizes); _details = new QTextView(splitter); splitter->setResizeMode(_devices, QSplitter::KeepSize); QTimer *refreshTimer = new QTimer(this); // 1 sec seems to be a good compromise between latency and polling load. refreshTimer->start(1000); connect(refreshTimer, SIGNAL(timeout()), SLOT(refresh())); connect(_devices, SIGNAL(selectionChanged(QListViewItem *)), this, SLOT(selectionChanged(QListViewItem *))); KAboutData *about = new KAboutData(I18N_NOOP("kcmusb"), I18N_NOOP("KDE USB Viewer"), 0, 0, KAboutData::License_GPL, I18N_NOOP("(c) 2001 Matthias Hoelzer-Kluepfel")); about->addAuthor("Matthias Hoelzer-Kluepfel", 0, "*****@*****.**"); about->addCredit("Leo Savernik", "Live Monitoring of USB Bus", "*****@*****.**"); setAboutData(about); load(); }
KAboutData* createAboutData(const QByteArray& appName, const QByteArray& catalogName, const KLocalizedString& programName) { KAboutData* data = new KAboutData(appName, catalogName, programName, KDE_VERSION_STRING); data->setLicense(KAboutData::License_GPL); data->setCopyrightStatement(ki18n("Copyright 2000-2013 Gwenview authors")); data->addAuthor( ki18n("Aurélien Gâteau"), ki18n("Main developer"), "*****@*****.**"); data->addAuthor( ki18n("Benjamin Löwe"), ki18n("Developer"), "*****@*****.**"); return data; }
const KAboutData *KCMTodoSummary::aboutData() const { KAboutData *about = new KAboutData( I18N_NOOP( "kcmtodosummary" ), 0, ki18n( "Pending To-dos Configuration Dialog" ), 0, KLocalizedString(), KAboutData::License_GPL, ki18n( "(c) 2003 - 2004 Tobias Koenig" ) ); about->addAuthor( ki18n( "Tobias Koenig" ), KLocalizedString(), "*****@*****.**" ); about->addAuthor( ki18n( "Allen Winter" ), KLocalizedString(), "*****@*****.**" ); return about; }
KCMHotkeys::KCMHotkeys( QWidget *parent, const QVariantList & /* args */ ) : KCModule( KCMModuleFactory::componentData(), parent ) ,d( new KCMHotkeysPrivate(this) ) { // Inform KCModule of the buttons we support KCModule::setButtons(KCModule::Buttons(KCModule::Default | KCModule::Apply | KCModule::Help)); // Add the about data KAboutData *about = new KAboutData( "khotkeys", 0, ki18n("KDE Hotkeys Configuration Module"), KDE_VERSION_STRING, KLocalizedString(), KAboutData::License_GPL, ki18n("Copyright 2008 (c) Michael Jansen") ); about->addAuthor( ki18n("Michael Jansen"), ki18n("Maintainer"), "*****@*****.**" ); setAboutData(about); // Tell KCModule we were changed. connect( d->action_group, SIGNAL(changed(bool)), this, SIGNAL(changed(bool)) ); connect( d->simple_action, SIGNAL(changed(bool)), this, SIGNAL(changed(bool)) ); connect( d->global_settings, SIGNAL(changed(bool)), this, SIGNAL(changed(bool)) ); // Update TreeView if hotkeys was changed connect( d->simple_action, SIGNAL(changed(KHotKeys::ActionDataBase*)), this, SLOT(_k_hotkeyChanged(KHotKeys::ActionDataBase*))); connect( d->action_group, SIGNAL(changed(KHotKeys::ActionDataBase*)), this, SLOT(_k_hotkeyChanged(KHotKeys::ActionDataBase*))); // Show the context menu d->menu_button->setMenu(new HotkeysTreeViewContextMenu(d->tree_view)); // Switch to the global settings dialog connect(d->settings_button, SIGNAL(clicked(bool)), SLOT(showGlobalSettings())); }
void MousePluginWidget::showAbout() { KAboutData *aboutData = new KAboutData(m_plugin.name().toUtf8(), m_plugin.name().toUtf8(), ki18n(m_plugin.name().toUtf8()), m_plugin.version().toUtf8(), ki18n(m_plugin.comment().toUtf8()), m_plugin.fullLicense().key(), ki18n(QByteArray()), ki18n(QByteArray()), m_plugin.website().toLatin1(), m_plugin.email().toLatin1()); aboutData->setProgramIconName(m_plugin.icon()); aboutData->addAuthor(ki18n(m_plugin.author().toUtf8()), ki18n(QByteArray()), m_plugin.email().toLatin1()); KAboutApplicationDialog *aboutDialog = new KAboutApplicationDialog2(aboutData, qobject_cast<QWidget*>(parent())); aboutDialog->show(); }
void KBugReportPrivate::_k_appChanged(int i) { QString appName = appcombo->itemText(i); int index = appName.indexOf( '/' ); if ( index > 0 ) appName = appName.left( index ); kDebug() << "appName " << appName; QString strDisplayVersion; //Version string to show in the UI if (appname == appName && m_aboutData) { m_strVersion = m_aboutData->version(); strDisplayVersion = m_strVersion; } else { m_strVersion = QLatin1String("unknown"); //English string to put in the bug report strDisplayVersion = i18nc("unknown program name", "unknown"); } if ( !submitBugWeb ) { m_strVersion += ' ' + kde_version; strDisplayVersion += ' ' + kde_version; } m_version->setText(strDisplayVersion); if ( submitBugWeb ) _k_updateUrl(); }
int main ( int argc, char *argv[] ) { KAboutData aboutData ( "SUSEgreeter", 0, ki18n ( "SUSEgreeter" ), "0.1", ki18n ( "SUSEgreeter" ), KAboutData::License_GPL, ki18n ( "(c) 2001, Adrian Schroeter" ) ); aboutData.addAuthor ( ki18n ( "Adrian Schroeter" ), KLocalizedString(), "*****@*****.**" ); KCmdLineArgs::init ( argc, argv, &aboutData ); KLocale::setMainCatalog ( "SUSEgreeter" ); KApplication a; KGlobal::locale()->insertCatalog ( QString::fromLatin1 ( "kpersonalizer" ) ); // first, reset the startup from true (see desktop file in share/autostart) to false KConfig SUSEgreeterrc ( "SUSEgreeterrc" ); KConfigGroup grp = SUSEgreeterrc.group ( "General" ); bool ktip = ( grp.readEntry ( "FirstLogin113", true ) ); grp.writeEntry ( "FirstLogin113", false ); grp.sync(); SUSEgreetings greeter; a.setTopWidget ( &greeter ); greeter.adjustSize(); QDesktopWidget *dsk = kapp->desktop(); QRect scr = dsk->screenGeometry ( dsk->screenNumber ( QPoint ( 0, 0 ) ) ); QRect grt ( 0, 0, greeter.width(), greeter.height() ); grt.moveCenter ( scr.center() ); greeter.setGeometry ( grt ); greeter.show(); int ret = a.exec(); if ( ktip ) { // only run if we set this to true in the constructor. then SUSEgreeter didn't run before // set the ktiprc file entry to true. The global one is set to false for starting SUSEgreeter #if 0 KConfig ktiprc ( "ktiprc" ); KConfigGroup group = ktiprc.group ( "TipOfDay" ); group.writeEntry ( "RunOnStart", true ); ktiprc.sync(); #endif // kapp->dcopClient()->send("kicker", "kicker", "showKMenu()", ""); } return ret; }
KCMKResources::KCMKResources( QWidget *parent, const char *name, const QStringList& ) : KCModule( ResourcesFactory::instance(), parent, name ) { QVBoxLayout *layout = new QVBoxLayout( this ); mConfigPage = new KRES::ConfigPage( this ); layout->addWidget( mConfigPage ); connect( mConfigPage, SIGNAL( changed( bool ) ), SIGNAL( changed( bool ) ) ); setButtons( Help | Apply ); KAboutData *about = new KAboutData( I18N_NOOP( "kcmkresources" ), I18N_NOOP( "KDE Resources configuration module" ), 0, 0, KAboutData::License_GPL, I18N_NOOP( "(c) 2003 Tobias Koenig" ) ); about->addAuthor( "Tobias Koenig", 0, "*****@*****.**" ); setAboutData(about); }