daily pastebin goal
89%
SHARE
TWEET

qtcagraph.hpp

a guest Jun 24th, 2011 62 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #ifndef GRAPHWIDGET
  2. #define GRAPHWIDGET
  3.  
  4. #include <QWidget>
  5.  
  6. #include <qwt/qwt_plot.h>
  7. #include <qwt/qwt_plot_curve.h>
  8. #include <qwt/qwt_plot_zoomer.h>
  9. #include <qwt/qwt_plot_magnifier.h>
  10.  
  11. class QLineEdit;
  12. class QLabel;
  13. class QPushButton;
  14. class QProcess;
  15. class QHBoxLayout;
  16. class QVBoxLayout;
  17.  
  18. class QtCAgraph : public QWidget {
  19.     Q_OBJECT
  20.  
  21. public:
  22.     QtCAgraph(QWidget* parent = 0);
  23.     ~QtCAgraph();
  24.  
  25. signals:
  26.  
  27. private slots:
  28.     void updateClicked();
  29.     void readFromStdout();
  30.     void resetAutoscaleX();
  31.     void resetAutoscaleY();
  32.  
  33. private:
  34.     QHBoxLayout* layout1;
  35.     QVBoxLayout* layout2;
  36.  
  37.     QString program;
  38.     QPushButton* updateButton;
  39.     QPushButton* autoscaleXButton;
  40.     QPushButton* autoscaleYButton;
  41.     QLabel* autoscale;
  42.     QLineEdit* pv_name;
  43.     QProcess* proc;
  44.  
  45.     QwtPlot* graph;
  46.     QwtPlotCurve* dataCurve;
  47.     QwtPlotZoomer* zoomer;
  48.     QwtPlotMagnifier* mag;
  49.     double* datax;
  50.     double* datay;
  51.     int datasize;
  52.     int i;
  53.  
  54.     void expandData();
  55. };
  56.  
  57. #endif //GRAPHWIDGET
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top