projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Added empty unit testing framework
[pulseview.git]
/
sigview.h
diff --git
a/sigview.h
b/sigview.h
index b60ee44b1d4a10aff320e30f0c4ef57673290e6d..3630d17e572cfe074a893d7463370d0af4148a3e 100644
(file)
--- a/
sigview.h
+++ b/
sigview.h
@@
-33,10
+33,14
@@
class SigView : public QGLWidget
Q_OBJECT
private:
Q_OBJECT
private:
+ static const double MaxScale;
+ static const double MinScale;
+
static const int SignalHeight;
static const int LabelMarginWidth;
static const int RulerHeight;
static const int SignalHeight;
static const int LabelMarginWidth;
static const int RulerHeight;
+ static const int MinorTickSubdivision;
static const int ScaleUnits[3];
static const QString SIPrefixes[9];
static const int ScaleUnits[3];
static const QString SIPrefixes[9];
@@
-45,6
+49,8
@@
private:
public:
explicit SigView(SigSession &session, QWidget *parent = 0);
public:
explicit SigView(SigSession &session, QWidget *parent = 0);
+ void zoom(double steps);
+
protected:
void initializeGL();
protected:
void initializeGL();
@@
-54,23
+60,29
@@
protected:
void paintEvent(QPaintEvent *event);
private:
void paintEvent(QPaintEvent *event);
private:
- void mouseMoveEvent(QMouseEvent *event);
void mousePressEvent(QMouseEvent *event);
void mousePressEvent(QMouseEvent *event);
+ void mouseMoveEvent(QMouseEvent *event);
void mouseReleaseEvent(QMouseEvent *event);
void mouseReleaseEvent(QMouseEvent *event);
+ void wheelEvent(QWheelEvent *event);
private:
private:
- void setupViewport(int width, int height);
+ void setup_viewport(int width, int height);
+
+ void paint_ruler(QPainter &p);
- void
paintRuler(QPainter &p
);
+ void
zoom(double steps, int offset
);
private slots:
private slots:
- void data
U
pdated();
+ void data
_u
pdated();
private:
SigSession &_session;
double _scale;
double _offset;
private:
SigSession &_session;
double _scale;
double _offset;
+
+ QPoint _mouse_down_point;
+ double _mouse_down_offset;
};
#endif // SIGVIEW_H
};
#endif // SIGVIEW_H