1 #ifndef __FONT_VIEW_PART_H__
2 #define __FONT_VIEW_PART_H__
5 * KFontInst - KDE Font Installer
7 * Copyright 2003-2007 Craig Drummond <craig@kde.org>
11 * This program is free software; you can redistribute it and/or modify
12 * it under the terms of the GNU General Public License as published by
13 * the Free Software Foundation; either version 2 of the License, or
14 * (at your option) any later version.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program; see the file COPYING. If not, write to
23 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
24 * Boston, MA 02110-1301, USA.
27 #include <KDE/KParts/ReadOnlyPart>
28 #include <KDE/KParts/BrowserExtension>
30 #include <QtGui/QFrame>
31 #include <QtCore/QMap>
32 #include "KfiConstants.h"
33 #include "FontPreview.h"
45 class BrowserExtension
;
47 class CFontViewPart
: public KParts::ReadOnlyPart
53 CFontViewPart(QWidget
*parentWidget
, QObject
*parent
, const QList
<QVariant
> &args
);
54 virtual ~CFontViewPart();
56 bool openUrl(const KUrl
&url
);
64 void previewStatus(bool st
);
67 void installlStatus();
70 void displayType(const QList
<CFcEngine::TRange
> &range
);
71 void statResult(KJob
*job
);
72 void showFace(int face
);
76 void stat(const QString
&path
=QString());
77 // void getMetaInfo(int face);
81 // QMap<int, QString> itsMetaInfo;
82 CFontPreview
*itsPreview
;
83 QPushButton
*itsInstallButton
;
84 QWidget
*itsFaceWidget
;
88 KIntNumInput
*itsFaceSelector
;
89 QAction
*itsChangeTextAction
;
91 KSharedConfigPtr itsConfig
;
92 BrowserExtension
*itsExtension
;
99 class BrowserExtension
: public KParts::BrowserExtension
105 BrowserExtension(CFontViewPart
*parent
);
107 void enablePrint(bool enable
);