Mercurial > hg > svgui
diff view/Pane.h @ 1216:dc2af6616c83
Merge from branch 3.0-integration
author | Chris Cannam |
---|---|
date | Fri, 13 Jan 2017 10:29:50 +0000 |
parents | 67f437277069 |
children | a34a2a25907c |
line wrap: on
line diff
--- a/view/Pane.h Fri Mar 04 12:23:31 2016 +0000 +++ b/view/Pane.h Fri Jan 13 10:29:50 2017 +0000 @@ -37,28 +37,35 @@ public: Pane(QWidget *parent = 0); - virtual QString getPropertyContainerIconName() const { return "pane"; } + virtual QString getPropertyContainerIconName() const override { return "pane"; } virtual bool shouldIlluminateLocalFeatures(const Layer *layer, - QPoint &pos) const; + QPoint &pos) const override; virtual bool shouldIlluminateLocalSelection(QPoint &pos, bool &closeToLeft, - bool &closeToRight) const; + bool &closeToRight) const override; void setCentreLineVisible(bool visible); bool getCentreLineVisible() const { return m_centreLineVisible; } - virtual sv_frame_t getFirstVisibleFrame() const; + virtual sv_frame_t getFirstVisibleFrame() const override; - virtual int getVerticalScaleWidth() const; + int getVerticalScaleWidth() const; - virtual QImage *toNewImage(sv_frame_t f0, sv_frame_t f1); - virtual QImage *toNewImage() { return View::toNewImage(); } - virtual QSize getImageSize(sv_frame_t f0, sv_frame_t f1); - virtual QSize getImageSize() { return View::getImageSize(); } + virtual QImage *renderToNewImage() override { + return View::renderToNewImage(); + } + + virtual QImage *renderPartToNewImage(sv_frame_t f0, sv_frame_t f1) override; + + virtual QSize getRenderedImageSize() override { + return View::getRenderedImageSize(); + } + + virtual QSize getRenderedPartImageSize(sv_frame_t f0, sv_frame_t f1) override; virtual void toXml(QTextStream &stream, QString indent = "", - QString extraAttributes = "") const; + QString extraAttributes = "") const override; static void registerShortcuts(KeyReference &kr); @@ -77,20 +84,22 @@ void regionOutlined(QRect rect); public slots: - virtual void toolModeChanged(); - virtual void zoomWheelsEnabledChanged(); - virtual void viewZoomLevelChanged(View *v, int z, bool locked); - virtual void modelAlignmentCompletionChanged(); + // view slots + virtual void toolModeChanged() override; + virtual void zoomWheelsEnabledChanged() override; + virtual void viewZoomLevelChanged(View *v, int z, bool locked) override; + virtual void modelAlignmentCompletionChanged() override; + // local slots, not overrides virtual void horizontalThumbwheelMoved(int value); virtual void verticalThumbwheelMoved(int value); virtual void verticalZoomChanged(); virtual void verticalPannerMoved(float x, float y, float w, float h); virtual void editVerticalPannerExtents(); - virtual void layerParametersChanged(); + virtual void layerParametersChanged() override; - virtual void propertyContainerSelected(View *, PropertyContainer *pc); + virtual void propertyContainerSelected(View *, PropertyContainer *pc) override; void zoomToRegion(QRect r); @@ -101,17 +110,17 @@ void playbackScheduleTimerElapsed(); protected: - virtual void paintEvent(QPaintEvent *e); - virtual void mousePressEvent(QMouseEvent *e); - virtual void mouseReleaseEvent(QMouseEvent *e); - virtual void mouseMoveEvent(QMouseEvent *e); - virtual void mouseDoubleClickEvent(QMouseEvent *e); - virtual void enterEvent(QEvent *e); - virtual void leaveEvent(QEvent *e); - virtual void wheelEvent(QWheelEvent *e); - virtual void resizeEvent(QResizeEvent *e); - virtual void dragEnterEvent(QDragEnterEvent *e); - virtual void dropEvent(QDropEvent *e); + virtual void paintEvent(QPaintEvent *e) override; + virtual void mousePressEvent(QMouseEvent *e) override; + virtual void mouseReleaseEvent(QMouseEvent *e) override; + virtual void mouseMoveEvent(QMouseEvent *e) override; + virtual void mouseDoubleClickEvent(QMouseEvent *e) override; + virtual void enterEvent(QEvent *e) override; + virtual void leaveEvent(QEvent *e) override; + virtual void wheelEvent(QWheelEvent *e) override; + virtual void resizeEvent(QResizeEvent *e) override; + virtual void dragEnterEvent(QDragEnterEvent *e) override; + virtual void dropEvent(QDropEvent *e) override; void wheelVertical(int sign, Qt::KeyboardModifiers); void wheelHorizontal(int sign, Qt::KeyboardModifiers); @@ -127,7 +136,7 @@ void drawEditingSelection(QPainter &); void drawAlignmentStatus(QRect, QPainter &, const Model *, bool down); - virtual bool render(QPainter &paint, int x0, sv_frame_t f0, sv_frame_t f1); + virtual bool render(QPainter &paint, int x0, sv_frame_t f0, sv_frame_t f1) override; Selection getSelectionAt(int x, bool &closeToLeft, bool &closeToRight) const;