Initial commit
This commit is contained in:
commit
872bb95acf
20 changed files with 1369 additions and 0 deletions
38
tagview.h
Normal file
38
tagview.h
Normal file
|
|
@ -0,0 +1,38 @@
|
|||
#ifndef TAGVIEW_H
|
||||
#define TAGVIEW_H
|
||||
|
||||
#include "sqlitebackend.h"
|
||||
#include "tagscene.h"
|
||||
|
||||
#include <QGraphicsView>
|
||||
#include <QTimer>
|
||||
|
||||
|
||||
class TagView : public QGraphicsView
|
||||
{
|
||||
public:
|
||||
TagView(SQLiteSaveFile &proj);
|
||||
|
||||
public slots:
|
||||
void zoomToFit();
|
||||
void setZoom(qreal zoom);
|
||||
void zoomIn(qreal delta);
|
||||
void rotate(int angle);
|
||||
|
||||
protected:
|
||||
void wheelEvent(QWheelEvent *evt) override;
|
||||
|
||||
private slots:
|
||||
void saveCenter();
|
||||
|
||||
private:
|
||||
void restoreViewport();
|
||||
|
||||
TagScene scene;
|
||||
SQLiteSaveFile &proj;
|
||||
QTimer saveCenterTimer;
|
||||
int rotation;
|
||||
double zoom;
|
||||
};
|
||||
|
||||
#endif // TAGVIEW_H
|
||||
Loading…
Add table
Add a link
Reference in a new issue