• Skip to content
  • Skip to link menu
Trinity API Reference
  • Trinity API Reference
  • kdecore
 

kdecore

  • kdecore
kaboutdata.h
1 /*
2  * This file is part of the KDE Libraries
3  * Copyright (C) 2000 Espen Sand (espen@kde.org)
4  *
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Library General Public
7  * License as published by the Free Software Foundation; either
8  * version 2 of the License, or (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Library General Public License for more details.
14  *
15  * You should have received a copy of the GNU Library General Public License
16  * along with this library; see the file COPYING.LIB. If not, write to
17  * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
18  * Boston, MA 02110-1301, USA.
19  *
20  */
21 
22 #include <tqvaluelist.h>
23 #include <tqstring.h>
24 #include <tqimage.h>
25 #include <klocale.h>
26 
27 #ifndef _KABOUTDATA_H_
28 #define _KABOUTDATA_H_
29 
30 class KAboutPersonPrivate;
31 class KAboutDataPrivate;
32 
54 class KDECORE_EXPORT KAboutPerson
55 {
56 public:
70  KAboutPerson( const char *name, const char *task,
71  const char *emailAddress, const char *webAddress )
72  {
73  mName = name;
74  mTask = task;
75  mEmailAddress = emailAddress;
76  mWebAddress = webAddress;
77  }
82  KAboutPerson() {}
83 
89  TQString name() const;
90 
96  TQString task() const;
97 
103  TQString emailAddress() const;
104 
110  TQString webAddress() const;
111 
112 private:
113  const char *mName;
114  const char *mTask;
115  const char *mEmailAddress;
116  const char *mWebAddress;
117 
118  KAboutPersonPrivate *d;
119 };
120 
121 class KAboutTranslatorPrivate;
134 class KDECORE_EXPORT KAboutTranslator
135 {
136 public:
144  KAboutTranslator(const TQString & name=TQString::null,
145  const TQString & emailAddress=TQString::null);
146 
152  TQString name() const;
153 
159  TQString emailAddress() const;
160 
161 private:
162  TQString mName;
163  TQString mEmail;
164  KAboutTranslatorPrivate* d;
165 };
166 
167 
182 class KDECORE_EXPORT KAboutData
183 {
184  public:
188  enum LicenseKey
189  {
190  License_Custom = -2,
191  License_File = -1,
192  License_Unknown = 0,
193  License_GPL = 1,
194  License_GPL_V2 = 1,
195  License_LGPL = 2,
196  License_LGPL_V2 = 2,
197  License_BSD = 3,
198  License_Artistic = 4,
199  License_QPL = 5,
200  License_QPL_V1_0 = 5
201  };
202 
203  public:
238  KAboutData( const char *appName,
239  const char *programName,
240  const char *version,
241  const char *shortDescription = 0,
242  int licenseType = License_Unknown,
243  const char *copyrightStatement = 0,
244  const char *text = 0,
245  const char *homePageAddress = 0,
246  const char *bugsEmailAddress = 0
247  );
248 
249  ~KAboutData();
250 
270  void addAuthor( const char *name,
271  const char *task=0,
272  const char *emailAddress=0,
273  const char *webAddress=0 );
274 
294  void addCredit( const char *name,
295  const char *task=0,
296  const char *emailAddress=0,
297  const char *webAddress=0 );
298 
323  void setTranslator(const char* name, const char* emailAddress);
324 
340  void setLicenseText( const char *license );
341 
347  void setLicenseTextFile( const TQString &file );
348 
354  void setAppName( const char *appName );
355 
364  void setProgramName( const char* programName );
365 
375  void setProgramLogo(const TQImage& image);
376 
382  void setVersion( const char* version );
383 
391  void setShortDescription( const char *shortDescription );
392 
398  void setLicense( LicenseKey licenseKey);
399 
408  void setCopyrightStatement( const char *copyrightStatement );
409 
417  void setOtherText( const char *otherText );
418 
426  void setHomepage( const char *homepage );
427 
434  void setBugAddress( const char *bugAddress );
435 
444  void setProductName( const char *name );
445 
450  const char *appName() const;
451 
459  const char *productName() const;
460 
465  TQString programName() const;
466 
470  const char* internalProgramName() const;
474  void translateInternalProgramName() const;
475 
482  TQImage programLogo() const;
483 
488  TQString version() const;
489 
493  const char* internalVersion() const { return mVersion; }
494 
500  TQString shortDescription() const;
501 
507  TQString homepage() const;
508 
513  TQString bugAddress() const;
514 
518  const char* internalBugAddress() const { return mBugEmailAddress; }
519 
524  const TQValueList<KAboutPerson> authors() const;
525 
530  const TQValueList<KAboutPerson> credits() const;
531 
536  const TQValueList<KAboutTranslator> translators() const;
537 
542  static TQString aboutTranslationTeam();
543 
548  TQString otherText() const;
549 
557  TQString license() const;
558 
563  TQString copyrightStatement() const;
564 
572  TQString customAuthorPlainText() const;
573 
581  TQString customAuthorRichText() const;
582 
590  bool customAuthorTextEnabled() const;
591 
602  void setCustomAuthorText(const TQString &plainText, const TQString &richText);
603 
609  void unsetCustomAuthorText();
610 
611  private:
612  const char *mAppName;
613  const char *mProgramName;
614  const char *mVersion;
615  const char *mShortDescription;
616  int mLicenseKey;
617  const char *mCopyrightStatement;
618  const char *mOtherText;
619  const char *mHomepageAddress;
620  const char *mBugEmailAddress;
621  TQValueList<KAboutPerson> mAuthorList;
622  TQValueList<KAboutPerson> mCreditList;
623  const char *mLicenseText;
624  static const char *defaultBugTracker;
625 
626  KAboutDataPrivate *d;
627 };
628 
629 #endif
630 

kdecore

Skip menu "kdecore"
  • Main Page
  • Modules
  • Namespace List
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Namespace Members
  • Class Members
  • Related Pages

kdecore

Skip menu "kdecore"
  • arts
  • dcop
  • dnssd
  • interfaces
  •     interface
  •     library
  •   kspeech
  •   ktexteditor
  • kabc
  • kate
  • kcmshell
  • kdecore
  • kded
  • kdefx
  • kdeprint
  • kdesu
  • kdeui
  • kdoctools
  • khtml
  • kimgio
  • kinit
  • kio
  •   bookmarks
  •   httpfilter
  •   kfile
  •   kio
  •   kioexec
  •   kpasswdserver
  •   kssl
  • kioslave
  •   http
  • kjs
  • kmdi
  •   kmdi
  • knewstuff
  • kparts
  • krandr
  • kresources
  • kspell2
  • kunittest
  • kutils
  • kwallet
  • libkmid
  • libkscreensaver
Generated for kdecore by doxygen 1.8.3.1
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |