add more spacing
[personal-kdebase.git] / workspace / kcontrol / kfontinst / kio / FontInst.h
blobc450c6effb2660ffac34bcf519670e016cad3160
1 #ifndef __FONTINST_H__
2 #define __FONTINST_H__
4 /*
5 * KFontInst - KDE Font Installer
7 * Copyright 2003-2008 Craig Drummond <craig@kde.org>
9 * ----
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 <QtCore/QObject>
28 #include <KDE/KComponentData>
29 #include "DisabledFonts.h"
31 class QTimer;
33 using namespace KFI;
35 class FontInst : public QObject
37 Q_OBJECT
38 Q_CLASSINFO("D-Bus Interface", "org.kde.fontinst")
40 public:
42 enum EStatus
44 CommandOk,
45 CommandFailed,
46 NotAuthorised
49 FontInst(QObject *parent);
50 virtual ~FontInst();
52 public Q_SLOTS:
54 int disableFont(uint key, const QString &family, uint style, qulonglong writingSystems,
55 uint face, const QStringList &fileData);
56 int enableFont(uint key, const QString &family, uint style);
57 int deleteDisabledFont(uint key, const QString &family, uint style);
58 int reloadDisabledList(uint key);
59 int addToFc(uint key, const QString &dir);
60 int configureX(uint key, const QString &dir);
61 int copyFont(uint key, const QString &src, const QString &dest);
62 int moveFont(uint key, const QString &src, const QString &dest, uint uid, uint gid);
63 int deleteFont(uint key, const QString &font);
64 int createDir(uint key, const QString &dir);
65 int createAfm(uint key, const QString &font);
66 int fcCache(uint key);
68 private Q_SLOTS:
70 void timeout();
72 private:
74 void refreshDirList();
75 bool pathIsOk(const QString &path);
77 private:
79 friend class CCommandThread;
81 QTimer *itsTimer;
82 CDisabledFonts itsDisabledFonts;
83 QStringList itsFcDirs;
86 #endif