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 / KoFrame.h < prev    next >
Encoding:
C/C++ Source or Header  |  2007-05-30  |  1.8 KB  |  66 lines

  1. /* This file is part of the KDE project
  2.    Copyright (C) 1998, 1999, 2000 Torben Weis <weis@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 as published by the Free Software Foundation; either
  7.    version 2 of the License, or (at your option) any later version.
  8.  
  9.    This library is distributed in the hope that it will be useful,
  10.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  11.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  12.    Library General Public License for more details.
  13.  
  14.    You should have received a copy of the GNU Library General Public License
  15.    along with this library; see the file COPYING.LIB.  If not, write to
  16.    the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
  17.  * Boston, MA 02110-1301, USA.
  18. */
  19.  
  20. #ifndef __koFrame_h__
  21. #define __koFrame_h__
  22.  
  23. #include <qwidget.h>
  24.  
  25. class KoView;
  26. class KoFramePrivate;
  27.  
  28. class KoFrame : public QWidget
  29. {
  30.   Q_OBJECT
  31. public:
  32.   enum State { Inactive, Selected, Active };
  33.  
  34.   KoFrame( QWidget *parent, const char *name = 0 );
  35.   virtual ~KoFrame();
  36.  
  37.   virtual void setView( KoView *view );
  38.   virtual KoView *view() const;
  39.  
  40.   virtual void setState( State s );
  41.   virtual State state() const;
  42.  
  43.   virtual int leftBorder() const;
  44.   virtual int rightBorder() const;
  45.   virtual int topBorder() const;
  46.   virtual int bottomBorder() const;
  47.  
  48.   virtual int border() const;
  49.  
  50. signals:
  51.   void geometryChanged();
  52.  
  53. protected:
  54.   virtual void paintEvent( QPaintEvent* );
  55.   virtual void mousePressEvent( QMouseEvent* );
  56.   virtual void mouseMoveEvent( QMouseEvent* );
  57.   virtual void mouseReleaseEvent( QMouseEvent* );
  58.   virtual void resizeEvent( QResizeEvent* );
  59.   virtual bool eventFilter( QObject*, QEvent* );
  60.  
  61. private:
  62.   KoFramePrivate *d;
  63. };
  64.  
  65. #endif
  66.