kaddressbook Library API Documentation

kaddressbook.h

00001 #ifndef KADDRESSBOOK_H
00002 #define KADDRESSBOOK_H
00003 
00004 #include <qwidget.h>
00005 #include <qstring.h>
00006 #include <qdict.h>
00007 
00008 #include <kabc/vcardconverter.h>
00009 
00010 #include "kaddressbookiface.h"
00011 
00012 class ViewManager;
00013 class PrefsDialog;
00014 class LDAPSearchDialogImpl;
00015 class AddresseeEditorDialog;
00016 class IncSearchWidget;
00017 
00018 namespace KABC {
00019   class AddressBook;
00020   class Addressee;
00021 }
00022 
00042 class KAddressBook : public QWidget
00043 {
00044     Q_OBJECT
00045   public:
00046     KAddressBook( QWidget *parent, const char *name=0 );
00047     virtual ~KAddressBook();
00048 
00049     ViewManager *viewManager() { return mViewManager; }
00050 
00051   public slots:
00053     void addEmail( QString addr );
00054     void newContact();
00055     ASYNC showContactEditor( QString uid );
00056     QString getNameByPhone( QString phone );
00061     void save();
00062 
00065     void readConfig();
00066 
00069     void writeConfig();
00070 
00073     void undo();
00074 
00077     void redo();
00078 
00081     void importKDE2();
00082 
00085     void importCSV();
00086 
00089     void importVCard(const QString &, bool);
00090     
00092     void importVCardSimple();
00093 
00096     void exportCSV();
00097 
00100     void exportVCard30();
00101 
00104     void exportVCard( KABC::VCardConverter::Version );
00105 
00109     void editAddressee(QString uid = QString::null);
00110 
00116     void newAddressee();
00117 
00121     void configure();
00122 
00126     void print();
00127 
00130     void configureFilters();
00131 
00134     void setIncSearchWidget(IncSearchWidget*);
00135 
00136   protected:
00137     AddresseeEditorDialog *createAddresseeEditorDialog( QWidget *parent,
00138                                                         const char *name = 0 );
00139 
00140   protected slots:
00143     void addresseeSelected(const QString &uid);
00144 
00147     void addresseeExecuted(const QString &uid);
00148 
00152     void addresseeModified(const KABC::Addressee &);
00153 
00158     void viewModified();
00159 
00160     void slotOpenLDAPDialog();
00161     void slotLDAPRefresh();
00162 
00166     void configChanged();
00167 
00168     void slotEditorDestroyed( const QString &uid );
00169 
00170     void slotAddressBookChanged();
00171 
00172   signals:
00177     void addresseeSelected(bool selected);
00178 
00183     void modified(bool mod);
00184 
00185   private:
00191     void parseEmailAddress(QString rawEmail, QString &fullName, QString &email);
00192 
00193     KABC::AddressBook *mDocument;
00194     PrefsDialog *mPrefsDialog;
00195     LDAPSearchDialogImpl *mLdapSearchDialog;
00196     ViewManager *mViewManager;
00197     QDict<AddresseeEditorDialog> mEditorDict;
00198     IncSearchWidget *mIncSearchWidget;
00199 };
00200 
00201 #endif // KADDRESSBOOK_H
KDE Logo
This file is part of the documentation for kdelibs Version 3.1.5.
Documentation copyright © 1996-2002 the KDE developers.
Generated on Sun Feb 15 11:40:37 2004 by doxygen 1.3.5 written by Dimitri van Heesch, © 1997-2001