Scribus
Open source desktop publishing at your fingertips
pageitemsetterbase.h
1 /***************************************************************************
2  * Copyright (C) 2009 by Pierre Marchand *
3  * pierre@oep-h.com *
4  * *
5  * This program is free software; you can redistribute it and/or modify *
6  * it under the terms of the GNU General Public License as published by *
7  * the Free Software Foundation; either version 2 of the License, or *
8  * (at your option) any later version. *
9  * *
10  * This program is distributed in the hope that it will be useful, *
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13  * GNU General Public License for more details. *
14  * *
15  * You should have received a copy of the GNU General Public License *
16  * along with this program; if not, write to the *
17  * Free Software Foundation, Inc., *
18  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
19  ***************************************************************************/
20 
21 
22 #ifndef PAGEITEMSETTERBASE_H
23 #define PAGEITEMSETTERBASE_H
24 
25 #include <QWidget>
26 #include <QString>
27 
28 
29 //Not exactly clear what would be the best but we go for the Selection atm -pm
30 //class PageItem;
31 class Selection;
32 
43 class PageItemSetterBase : public QWidget
44 {
45 public:
49  PageItemSetterBase(QWidget * parent = 0);
50 
55  virtual void changeItem(Selection*) = 0;
56 
63 // let put this in objectName which is yet available.
64 // virtual QString name() const = 0;
65 
69  virtual PageItemSetterBase* clone() = 0;
70 
71 
72 protected:
73  QPoint startDragPoint;
74  virtual void mousePressEvent(QMouseEvent *event);
75  virtual void mouseMoveEvent(QMouseEvent *event);
76 
81  virtual void activate(const bool& act);
82 
83 };
84 #endif // PAGEITEMSETTERBASE_H
PageItemSetterBase(QWidget *parent=0)
Definition: pageitemsetterbase.cpp:29
virtual PageItemSetterBase * clone()=0
Definition: pageitemsetterbase.h:43
virtual void activate(const bool &act)
Definition: pageitemsetterbase.cpp:60
virtual void changeItem(Selection *)=0
Definition: selection.h:34