home *** CD-ROM | disk | FTP | other *** search
/ Personal Computer World 2009 February / PCWFEB09.iso / Software / Linux / SLAX 6.0.8 / slax-6.0.8.iso / slax / base / 006-devel.lzm / usr / include / kate / application.h next >
Encoding:
C/C++ Source or Header  |  2007-01-15  |  1.9 KB  |  80 lines

  1. /* This file is part of the KDE project
  2.    Copyright (C) 2001 Christoph Cullmann <cullmann@kde.org>
  3.  
  4.    This library is free software; you can redistribute it and/or
  5.    modify it under the terms of the GNU Library General Public
  6.    License version 2 as published by the Free Software Foundation.
  7.  
  8.    This library is distributed in the hope that it will be useful,
  9.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  10.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  11.    Library General Public License for more details.
  12.  
  13.    You should have received a copy of the GNU Library General Public License
  14.    along with this library; see the file COPYING.LIB.  If not, write to
  15.    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  16.    Boston, MA 02110-1301, USA.
  17. */
  18.  
  19. #ifndef _KATE_APPLICATION_INCLUDE_
  20. #define _KATE_APPLICATION_INCLUDE_
  21.  
  22. #include <qobject.h>
  23. #include <kurl.h>
  24.  
  25. namespace Kate
  26. {
  27.  
  28. class DocumentManager;
  29. class PluginManager;
  30. class InitPluginManager;
  31. class MainWindow;
  32.  
  33. /**
  34.  * Interface to the application, beside some global methodes to access
  35.  * other objects like document/projectmanager, ... no way goes around this
  36.  * central interface
  37.  */
  38. class KDE_EXPORT Application : public QObject
  39. {
  40.   friend class PrivateApplication;
  41.  
  42.   Q_OBJECT
  43.  
  44.   public:
  45.     /**
  46.      * Construtor, should not interest, internal usage
  47.      */
  48.     Application (void *application);
  49.  
  50.     /**
  51.      * Desctructor
  52.      */
  53.     virtual ~Application ();
  54.  
  55.   public:
  56.     /** Returns a pointer to the document manager
  57.     */
  58.     Kate::DocumentManager *documentManager ();
  59.  
  60.     Kate::PluginManager *pluginManager ();
  61.  
  62.     Kate::MainWindow *activeMainWindow ();
  63.  
  64.     uint mainWindows ();
  65.     Kate::MainWindow *mainWindow (uint n = 0);
  66.  
  67.   private:
  68.     class PrivateApplication *d;
  69. };
  70.  
  71. /**
  72.  * Returns the application object
  73.  * @return Application application object
  74.  */
  75. KDE_EXPORT Application *application ();
  76.  
  77. }
  78.  
  79. #endif
  80.