17 #ifndef QGSCOMPOSERVIEW_H
18 #define QGSCOMPOSERVIEW_H
20 #include <QGraphicsView>
91 ActiveUntilMouseRelease
94 QgsComposerView( QWidget* parent = 0,
const char* name = 0, Qt::WindowFlags f = 0 );
103 void copyItems( ClipboardMode mode );
106 void pasteItems( PasteMode mode );
109 void deleteSelectedItems();
132 QMainWindow* composerWindow();
144 void setZoomLevel(
double zoomLevel );
151 void setPreviewModeEnabled(
bool enabled );
161 void mousePressEvent( QMouseEvent* );
162 void mouseReleaseEvent( QMouseEvent* );
163 void mouseMoveEvent( QMouseEvent* );
164 void mouseDoubleClickEvent( QMouseEvent* e );
166 void keyPressEvent( QKeyEvent * e );
167 void keyReleaseEvent( QKeyEvent * e );
169 void wheelEvent( QWheelEvent* event );
171 void paintEvent( QPaintEvent* event );
173 void hideEvent( QHideEvent* e );
174 void showEvent( QShowEvent* e );
176 void resizeEvent( QResizeEvent* event );
177 void scrollContentsBy(
int dx,
int dy );
186 QGraphicsRectItem* mRubberBandItem;
188 QGraphicsLineItem* mRubberBandLineItem;
192 QPointF mMoveContentStartPos;
194 QPointF mRubberBandStartPos;
203 bool mPaintingEnabled;
209 void addShape( Tool currentTool );
219 bool mMovingItemContent;
222 QPoint mMouseCurrentXY;
223 QPoint mMousePressStartPos;
228 QCursor defaultCursorForTool( Tool currentTool );
231 void wheelZoom( QWheelEvent * event );
233 void updateRubberBandRect( QPointF & pos,
const bool constrainSquare =
false,
const bool fromCenter =
false );
235 void updateRubberBandLine(
const QPointF & pos,
const bool constrainAngles =
false );
237 void removeRubberBand();
240 void startMarqueeSelect( QPointF & scenePoint );
242 void endMarqueeSelect( QMouseEvent* e );
244 void startMarqueeZoom( QPointF & scenePoint );
246 void endMarqueeZoom( QMouseEvent* e );
257 void actionFinished();
259 void cursorPosChanged( QPointF );
261 void zoomLevelChanged();