lib

KoDocumentInfoDlg.h
1/* This file is part of the KDE project
2 Copyright (c) 2000 Simon Hausmann <hausmann@kde.org>
3
4 $Id: KoDocumentInfoDlg.h 508787 2006-02-12 18:28:12Z ingwa $
5
6 This library is free software; you can redistribute it and/or
7 modify it under the terms of the GNU Library General Public
8 License as published by the Free Software Foundation; either
9 version 2 of the License, or (at your option) any later version.
10
11 This library is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 Library General Public License for more details.
15
16 You should have received a copy of the GNU Library General Public License
17 along with this library; see the file COPYING.LIB. If not, write to
18 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
19 * Boston, MA 02110-1301, USA.
20*/
21
22#ifndef __koDocumentInfoDlg_h__
23#define __koDocumentInfoDlg_h__
24
25#include <kpropertiesdialog.h>
26#include <koffice_export.h>
27
28class KDialogBase;
29class KoDocumentInfo;
30class KoDocumentInfoAuthor;
31class KoDocumentInfoAbout;
32class KoDocumentInfoUserMetadata;
33class KArchiveEntry;
34
35class KOFFICECORE_EXPORT KoDocumentInfoDlg : public TQObject
36{
37 TQ_OBJECT
38
39public:
40 KoDocumentInfoDlg( KoDocumentInfo *docInfo, TQWidget *parent = 0, const char *name = 0,
41 KDialogBase *dialog = 0 );
42 virtual ~KoDocumentInfoDlg();
43
44 int exec();
45 KDialogBase *dialog() const;
46
47 void save();
48
49signals:
50 void changed();
51
52private slots:
53 void loadFromKABC();
54 void deleteInfo();
55 void resetMetaData();
56
57private:
58 void addAuthorPage( KoDocumentInfoAuthor *authorInfo );
59 void addAboutPage( KoDocumentInfoAbout *aboutInfo );
60 void addUserMetadataPage( KoDocumentInfoUserMetadata *userMetadataInfo );
61
62 void save( KoDocumentInfoAuthor *authorInfo );
63 void save( KoDocumentInfoAbout *aboutInfo );
64 void save( KoDocumentInfoUserMetadata *userMetadataInfo );
65
66 class KoDocumentInfoDlgPrivate;
67 KoDocumentInfoDlgPrivate *d;
68};
69
70class KOFFICECORE_EXPORT KoDocumentInfoPropsPage : public KPropsDlgPlugin
71{
72 TQ_OBJECT
73
74public:
75 KoDocumentInfoPropsPage( KPropertiesDialog *props, const char *name = 0,
76 const TQStringList & = TQStringList() );
77 virtual ~KoDocumentInfoPropsPage();
78
79 virtual void applyChanges();
80
81private:
82 void copy( const TQString &path, const KArchiveEntry *entry );
83 class KoDocumentInfoPropsPagePrivate;
84 KoDocumentInfoPropsPagePrivate *d;
85};
86
87#endif
TDEAction * save(const TQObject *recvr, const char *slot, TDEActionCollection *parent, const char *name=0)
TDEAction * copy(const TQObject *recvr, const char *slot, TDEActionCollection *parent, const char *name=0)