No Description

mainwindow.h 1.8KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #ifndef MAINWINDOW_H
  2. #define MAINWINDOW_H
  3. /// \file
  4. #include <QMainWindow>
  5. #include "qcustomplot.h"
  6. using namespace std;
  7. namespace Ui {
  8. class MainWindow;
  9. }
  10. class MainWindow : public QMainWindow
  11. {
  12. Q_OBJECT
  13. public:
  14. /// \fn MainWindow::MainWindow(QWidget *parent)
  15. /// \brief Constructor
  16. explicit MainWindow(QWidget *parent = 0);
  17. /// \fn MainWindow::~MainWindow()
  18. /// \brief Destructor
  19. ///
  20. ~MainWindow();
  21. /// \fn void MainWindow::histo(string names[], double values[], int size, string xAxisLabel, string yAxisLabel)
  22. /// \~English
  23. /// \brief This function receives information about the ticks and
  24. /// values for a bar chart, then displays it using the customPlot widget
  25. /// from qcustomplot.
  26. /// \param names an array of strings for the names of the x-axis ticks
  27. /// \param values an array of doubles for the values of y-axis
  28. /// \param size the size of the names (and values) arrays
  29. /// \param xAxisLabel a string for the x-axis title
  30. /// \param yAxisLabel a string for the y-axis title
  31. /// \~Spanish
  32. /// \brief Esta funcion recibe informacion sobre las marcas en el eje y los valores
  33. /// para una gráfica de barra, entonces la despliega usando el widget de qcustomplot.
  34. /// \param names un arreglo de cadenas de caracteres para los nombres de las marcas del el axis-x
  35. /// \param values un arreglo de dobles (doubles) para los valores del axis-y.
  36. /// \param size el tamano de los arreglos con los nombres (y valores).
  37. /// \param xAxisLabel una cadena de caracteres para el titulo del axis-x.
  38. /// \param yAxisLabel una cadena de caracteres para el titulo del axis-y.
  39. void histo(string names[],
  40. double values[], int size, string xAxisLabel, string yAxisLabel);
  41. private:
  42. Ui::MainWindow *ui;
  43. QCustomPlot *myPlot;
  44. };
  45. #endif // MAINWINDOW_H