|
|
// -*- c++ -*- #ifndef XMELEGANCE_H #define XMELEGANCE_H #include#include "utils/trimainwindow.h" class KRecentFilesAction; class KToggleAction; class Document; class DocType; class DocTypeViewManager; class DocTypeManager; class Document; class DOMTreePart; namespace KJSEmbed { class JSConsolePart; class MessageLogWidget; }; /** * Main window for XMElegance. * * @author Richard Moore, rich@kde.org * @version $Id: xmelegance_h.html,v 1.1.1.1 2001/11/29 18:18:35 rich Exp $ */ class XMElegance : public TriMainWindow { Q_OBJECT public: XMElegance(); virtual ~XMElegance(); /** Returns the current document. */ Document *document() const { return doc; } /** Returns the message log widget. */ KJSEmbed::MessageLogWidget *messageLog() const { return msgView; } /** Returns the javascript console part. */ KJSEmbed::JSConsolePart *jsPart() const { return jsConsole; } public slots: /** Opens the document at the url. */ void openURL( const KURL &url ); /** Shows a file dialog then calls @ref openURL */ void open(); protected: /** Creates the sidebar. */ void setupSidebar(); /** Creates the document pane. */ void setupDocViews(); /** Creates the message pane. */ void setupMessageViews(); /** Creates the KActions for the main window. */ void setupActions(); /** Creatings bindings to the JS interpreter. */ void setupBindings(); /** Install the specified DocType. */ void installDocType( DocType *doctype ); protected slots: /** Activates the part for the specified widget (if there is one). */ void activeViewChanged( QWidget *w ); private: // Actions KRecentFilesAction *recent_files; KToggleAction *show_sidebar; KToggleAction *show_messages; // View Management KParts::PartManager *partManager; DocTypeViewManager *docViewMng; Document *doc; // Built in views DOMTreePart *domTree; KJSEmbed::MessageLogWidget *msgView; KJSEmbed::JSConsolePart *jsConsole; }; #endif // XMELEGANCE_H // Local Variables: // c-basic-offset: 4 // End:
Generated by: rich on pegasus on Fri Nov 9 01:30:42 2001, using kdoc 2.0a53. |