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

kdeprint

  • kdeprint
kmfactory.h
1 /*
2  * This file is part of the KDE libraries
3  * Copyright (c) 2001 Michael Goffioul <kdeprint@swing.be>
4  *
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 version 2 as published by the Free Software Foundation.
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 #ifndef KMFACTORY_H
22 #define KMFACTORY_H
23 
24 #include <tqstring.h>
25 #include <tqvaluelist.h>
26 #include <tqstringlist.h>
27 #include <tqptrlist.h>
28 #include <tqobject.h>
29 #include <tqpair.h>
30 #include <dcopobject.h>
31 
32 #include <sys/types.h>
33 
34 class KMManager;
35 class KMJobManager;
36 class KMUiManager;
37 class KMVirtualManager;
38 class KXmlCommandManager;
39 class KMSpecialManager;
40 class KPrinterImpl;
41 class KLibFactory;
42 class KConfig;
43 class KPReloadObject;
44 
45 class KDEPRINT_EXPORT KMFactory : public TQObject, public DCOPObject
46 {
47  Q_OBJECT
48  K_DCOP
49 
50 public:
51  struct PluginInfo
52  {
53  TQString name;
54  TQString comment;
55  TQStringList detectUris;
56  int detectPrecedence;
57  TQStringList mimeTypes;
58  TQString primaryMimeType;
59  };
60 
61  static KMFactory* self();
62  static bool exists();
63  static void release();
64 
65  KMFactory();
66  ~KMFactory();
67 
68  KMManager* manager();
69  KMJobManager* jobManager();
70  KMUiManager* uiManager();
71  KMVirtualManager* virtualManager();
72  KMSpecialManager* specialManager();
73  KXmlCommandManager* commandManager();
74  KPrinterImpl* printerImplementation();
75  KConfig* printConfig(const TQString& group = TQString::null);
76  TQString printSystem();
77  TQValueList<PluginInfo> pluginList();
78  PluginInfo pluginInfo(const TQString& name);
79  void saveConfig();
80 
81  void reload(const TQString& syst, bool saveSyst = true);
82  void registerObject(KPReloadObject*, bool = false);
83  void unregisterObject(KPReloadObject*);
84 
85  struct Settings
86  {
87  int application;
88  int standardDialogPages;
89  int pageSelection;
90  int orientation;
91  int pageSize;
92  };
93  Settings* settings() const { return m_settings; }
94 
95  TQPair<TQString,TQString> requestPassword( int& seqNbr, const TQString& user, const TQString& host = "localhost", int port = 0 );
96  void initPassword( const TQString& user, const TQString& password, const TQString& host = "localhsot", int port = 0 );
97 
98 k_dcop:
99  ASYNC slot_pluginChanged(pid_t);
100  ASYNC slot_configChanged();
101 
102 k_dcop_signals:
103  void pluginChanged(pid_t);
104  void configChanged();
105 
106 private:
107  void createManager();
108  void createJobManager();
109  void createUiManager();
110  void createPrinterImpl();
111  void loadFactory(const TQString& syst = TQString::null);
112  void unload();
113  TQString autoDetect();
114 
115 private:
116  static KMFactory *m_self;
117 
118  KMManager *m_manager;
119  KMJobManager *m_jobmanager;
120  KMUiManager *m_uimanager;
121  KPrinterImpl *m_implementation;
122  KLibFactory *m_factory;
123 
124  KConfig *m_printconfig;
125  Settings *m_settings;
126  TQPtrList<KPReloadObject> m_objects;
127 };
128 
129 #endif

kdeprint

Skip menu "kdeprint"
  • Main Page
  • Class Hierarchy
  • Alphabetical List
  • Class List
  • File List
  • Class Members
  • Related Pages

kdeprint

Skip menu "kdeprint"
  • 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 kdeprint by doxygen 1.8.8
This website is maintained by Timothy Pearson.
KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V. |