27#include "kptwbsdefinition.h"
28#include "kptxmlloaderobject.h"
30#include <KoDocument.h>
31#include <KoTextZoomHandler.h>
34class KoCommandHistory;
47class Part : public KoDocument, public KoTextZoomHandler {
52 Part(TQWidget *parentWidget = 0, const char *widgetName = 0,
53 TQObject* parent = 0, const char* name = 0,
54 bool singleViewMode = false);
57 virtual void paintContent(TQPainter& painter, const TQRect& rect,
58 bool transparent = false,
59 double zoomX = 1.0, double zoomY = 1.0);
61 virtual bool initDoc(InitDocFlags flags, TQWidget* parentWidget=0);
68 Project &getProject() { return *m_project; }
69 const Project &getProject() const { return *m_project; }
72 virtual bool loadXML(TQIODevice *, const TQDomDocument &document);
73 virtual TQDomDocument saveXML();
75 bool saveOasis(KoStore*, KoXmlWriter*) { return false; }
76 bool loadOasis( const TQDomDocument &, KoOasisStyles &, const TQDomDocument&, KoStore *) { return false; }
78 void addCommand(KCommand * cmd, bool execute= true);
80 void setCommandType( int type);
82 Config &config() { return m_config; }
85 WBSDefinition &wbsDefinition() { return m_wbsDefinition; }
87 const XMLLoaderObject &xmlLoader() const { return m_xmlLoader; }
89 virtual KoView* createViewInstance(TQWidget* parent, const char* name);
92 void slotDocumentRestored();
93 void slotCommandExecuted();
94 void slotCopyContextFromView();
95 void slotViewDestroyed();
99 ProjectDialog *m_projectDialog;
100 TQWidget* m_parentWidget;
107 GanttView* m_embeddedGanttView;
108 Context* m_embeddedContext;
109 bool m_embeddedContextInitialized;
111 KoCommandHistory *m_commandHistory;
112 bool m_update, m_calculate, m_baseline;
117 WBSDefinition m_wbsDefinition;
119 XMLLoaderObject m_xmlLoader;
|