kmdi/kmdi Library: mainwindow.h Source File (kmdi/kmdi Library)

| # kmdi/kmdi Library API Documentation
Overview | Class Hierarchy | Classes | Classes (annotated) | Members | Namespaces | Source Files

# mainwindow.h

    00001 /* This file is part of the KDE libraries
    00002    Copyright (C) 2004 Christoph Cullmann <cullmann@kde.org>
    00003    Copyright (C) 2002,2003 Joseph Wenninger <jowenn@kde.org>
    00004
    00005    This library is free software; you can redistribute it and/or
    00006    modify it under the terms of the GNU Library General Public
    00007    License as published by the Free Software Foundation; either
    00008    version 2 of the License, or (at your option) any later version.
    00009
    00010    This library is distributed in the hope that it will be useful,
    00011    but WITHOUT ANY WARRANTY; without even the implied warranty of
    00012    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    00013    Library General Public License for more details.
    00014
    00015    You should have received a copy of the GNU Library General Public License
    00016    along with this library; see the file COPYING.LIB.  If not, write to
    00017    the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    00018    Boston, MA 02111-1307, USA.
    00019
    00020    Based on:
    00021
    00022    //----------------------------------------------------------------------------
    00023    //    Project              : KDE MDI extension
    00024    //
    00025    //    begin                : 07/1999       by Szymon Stefanek as part of kvirc
    00026    //                                         (an IRC application)
    00027    //    changes              : 09/1999       by Falk Brettschneider to create an
    00028    //                           - 06/2000     stand-alone Qt extension set of
    00029    //                                         classes and a Qt-based library
    00030    //                         : 02/2000       by Massimo Morin (mmorin@schedsys.com)
    00031    //                           2000-2003     maintained by the KDevelop project
    00032    //    patches              : -/2000        by Lars Beikirch (Lars.Beikirch@gmx.net)
    00033    //                         : 01/2003       by Jens Zurheide (jens.zurheide@gmx.de)
    00034    //
    00035    //    copyright            : (C) 1999-2003 by Falk Brettschneider
    00036    //                                         and
    00037    //                                         Szymon Stefanek (stefanek@tin.it)
    00038    //    email                :  falkbr@kdevelop.org (Falk Brettschneider)
    00039    //----------------------------------------------------------------------------
    00040 */
    00041
    00042 #ifndef _KMDI_MAINWINDOW_H_
    00043 #define _KMDI_MAINWINDOW_H_
    00044
    00045 #include <kparts/dockmainwindow.h>
    00046 #include <kmenubar.h>
    00047 #include <kpopupmenu.h>
    00048
    00049 #include <qptrlist.h>
    00050 #include <qrect.h>
    00051 #include <qapplication.h>
    00052 #include <qguardedptr.h>
    00053
    00054 #include <kmdi/global.h>
    00055
    00056 class QPopupMenu;
    00057 class QMenuBar;
    00058
    00059 #include <kmdi/toolviewaccessor.h>
    00060
    00061 namespace KMDIPrivate {
    00062   class MainWindowPrivate;
    00063   class GUIClient;
    00064 }
    00065
    00066 namespace KMDI
    00067 {
    00068
    00069 class DockContainer;
    00070 class TabWidget;
    00071
    00072 class KMDI_EXPORT MainWindow : public KParts::DockMainWindow
    00073 {
    00074   Q_OBJECT
    00075
    00076   friend class KMDI::ToolViewAccessor;
    00077
    00078   public:
    00082     MainWindow ( QWidget* parentWidget, const char* name = "");
    00083
    00087     virtual ~MainWindow ();
    00088
    00089   public:
    00096     TabWidget *tabWidget ();
    00097
    00103     KMDI::ToolViewAccessor *createToolWindow();
    00104
    00112     KMDI::ToolViewAccessor *addToolWindow( QWidget* pWnd, KDockWidget::DockPosition pos = KDockWidget::DockNone, QWidget* pTargetWnd = 0L, int percent = 50, const QString& tabToolTip = 0, const QString& tabCaption = 0);
    00113
    00118     void deleteToolWindow( KMDI::ToolViewAccessor *accessor);
    00119
    00124     void deleteToolWindow( QWidget* pWnd);
    00125
    00130     void setToolViewStyle(int flags);
    00131
    00132   public slots:
    00133     void prevToolViewInDock();
    00134     void nextToolViewInDock();
    00135
    00136   signals:
    00137     void collapseOverlapContainers();
    00138
    00139   protected:
    00140     void findToolViewsDockedToMain(QPtrList<KDockWidget>* list,KDockWidget::DockPosition dprtmw);
    00141     void dockToolViewsIntoContainers(QPtrList<KDockWidget>& widgetsToReparent,KDockWidget *container);
    00142
    00143   private:
    00147     void setupMainDock ();
    00148
    00153     void setupToolViews ();
    00154
    00159     void setupGUIClient ();
    00160
    00161   private slots:
    00162     void setActiveToolDock(DockContainer*);
    00163     void removeFromActiveDockList(DockContainer*);
    00164
    00165   #define protected public
    00166   signals:
    00167   #undef protected
    00168     void toggleTop();
    00169     void toggleLeft();
    00170     void toggleRight();
    00171     void toggleBottom();
    00172
    00173   protected:
    00174     KMDIPrivate::GUIClient *m_guiClient;
    00175     QMap <QWidget*, KMDI::ToolViewAccessor*> *m_toolViews;
    00176
    00177     KDockWidget *m_leftContainer;
    00178     KDockWidget *m_rightContainer;
    00179     KDockWidget *m_topContainer;
    00180     KDockWidget *m_bottomContainer;
    00181
    00182     KMDI::TabWidget *m_tabWidget;
    00183
    00184   private:
    00188     KMDIPrivate::MainWindowPrivate *d;
    00189 };
    00190
    00191 }
    00192
    00193 #endif //_MainWindow_H_
    00194
    00195 // kate: space-indent on; indent-width 2; replace-tabs on;

This file is part of the documentation for kmdi/kmdi Library Version 3.4.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sat Jun 11 20:32:30 2005 by doxygen 1.4.1 written by Dimitri van Heesch, © 1997-2003