You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
40 lines
938 B
40 lines
938 B
13 years ago
|
//Author: Timothy Pearson <kb9vqf@pearsoncomputing.net>, (C) 2012
|
||
|
//Copyright: See COPYING file that comes with this distribution
|
||
|
|
||
|
#include <tqwidget.h>
|
||
|
|
||
|
class TQPixmap;
|
||
|
|
||
|
class TraceWidget : public TQWidget
|
||
|
{
|
||
|
Q_OBJECT
|
||
|
|
||
|
public:
|
||
|
TraceWidget(TQWidget* = 0, const char* = 0);
|
||
|
~TraceWidget();
|
||
|
|
||
|
void setNumberOfSamples(unsigned int samples);
|
||
|
void setNumberOfHorizontalDivisions(unsigned int divisions);
|
||
|
void setNumberOfVerticalDivisions(unsigned int divisions);
|
||
|
void setDisplayLimits(double x, double y, double w, double h);
|
||
|
|
||
|
double* samples();
|
||
|
|
||
|
protected:
|
||
|
virtual void paintEvent(TQPaintEvent*);
|
||
|
virtual void resizeEvent(TQResizeEvent *);
|
||
|
|
||
|
private slots:
|
||
|
void updateGraticule();
|
||
|
|
||
|
private:
|
||
|
unsigned int m_samples;
|
||
|
unsigned int m_horizDivs;
|
||
|
unsigned int m_vertDivs;
|
||
|
double m_leftEdge;
|
||
|
double m_rightEdge;
|
||
|
double m_topEdge;
|
||
|
double m_bottomEdge;
|
||
|
double* m_sampleArray;
|
||
|
TQPixmap* m_graticulePixmap;
|
||
|
};
|