64enum UatColumnsIOG {colEnabled = 0, colName, colDFilter, colColor, colStyle, colYAxis, colYField, colSMAPeriod, colYAxisFactor, colAOT, colMaxNum};
95 void initialize(QWidget& parent,
uat_field_t* io_graph_fields, QString displayFilter = QString(),
96 io_graph_item_unit_t value_units = IOG_ITEM_UNIT_PACKETS,
97 QString yfield = QString(),
98 bool is_sibling_dialog =
false,
99 const QVector<QString> convFilters = QVector<QString>());
101 void addGraph(
bool checked,
bool asAOT, QString name, QString dfilter, QRgb color_idx, IOGraph::PlotStyles style,
102 io_graph_item_unit_t value_units, QString yfield,
int moving_average,
double yaxisfactor);
103 void addGraph(
bool checked,
bool asAOT, QString dfilter, io_graph_item_unit_t value_units, QString yfield);
104 void addGraph(
bool copy_from_current =
false);
105 virtual void addDefaultGraph(
bool enabled,
int idx = 0);
106 void syncGraphSettings(
int row);
107 qsizetype graphCount()
const;
110 void scheduleReplot(
bool now =
false);
111 void scheduleRecalc(
bool now =
false);
112 void scheduleRetap(
bool now =
false);
117 void keyPressEvent(QKeyEvent *event);
119 virtual QString getFilteredName()
const;
120 virtual QString getXAxisName()
const;
121 virtual const char* getYAxisName(io_graph_item_unit_t value_units)
const;
122 virtual QString getYFieldName(io_graph_item_unit_t value_units,
const QString& yfield)
const;
123 virtual int getYAxisValue(
const QString& data);
124 virtual QString getNoDataHint()
const;
125 virtual QString getHintText(
unsigned num_items)
const;
128 void modelDataChanged(
const QModelIndex &topLeft,
const QModelIndex &bottomRight,
const QVector<int> &roles);
129 void modelRowsReset();
130 void modelRowsInserted(
const QModelIndex &parent,
int first,
int last);
131 void modelRowsRemoved(
const QModelIndex &parent,
int first,
int last);
132 void modelRowsMoved(
const QModelIndex &sourceParent,
int sourceStart,
int sourceEnd,
const QModelIndex &destinationParent,
int destinationRow);
135 void goToPacket(
int packet_num);
137 void intervalChanged(
int interval);
138 void reloadValueUnitFields();
141 static const int DEFAULT_MOVING_AVERAGE = 0;
142 static const int DEFAULT_Y_AXIS_FACTOR = 1;
145 Ui::IOGraphDialog *ui;
150 QPointer<UatModel> uat_model_;
154 QVector<IOGraph*> ioGraphs_;
157 QCPGraph *base_graph_;
158 QCPItemTracer *tracer_;
159 uint32_t packet_num_;
162 QRubberBand *rubber_band_;
171 const char* type_unit_name_;
173 QSharedPointer<QCPAxisTicker> number_ticker_;
174 QSharedPointer<QCPAxisTickerDateTime> datetime_ticker_;
178 void zoomAxes(
bool in);
179 void zoomXAxis(
bool in);
180 void zoomYAxis(
bool in);
181 void panAxes(
int x_pixels,
int y_pixels);
182 void toggleTracerStyle(
bool force_default =
false);
186 QRectF getZoomRanges(QRect zoom_rect);
187 void createIOGraph(
int currentRow);
188 void loadProfileGraphs(
uat_field_t* io_graph_fields);
189 void makeCsv(QTextStream &
stream)
const;
190 bool saveCsv(
const QString &file_name)
const;
191 IOGraph *currentActiveGraph()
const;
192 bool graphIsEnabled(
int row)
const;
193 bool graphAsAOT(
int row)
const;
196 static void applyChanges();
198 void copyFromProfile(QString filename);
199 void updateWidgets();
200 void showContextMenu(
const QPoint &pos);
201 void graphClicked(QMouseEvent *event);
202 void mouseMoved(QMouseEvent *event);
203 void mouseReleased(QMouseEvent *event);
204 void selectedFrameChanged(QList<int> frames);
208 void updateStatistics(
void);
209 void copyAsCsvClicked();
211 void graphUatSelectionChanged(
const QItemSelection &selected,
const QItemSelection &deselected);
212 void on_intervalComboBox_currentIndexChanged(
int index);
213 void on_graphUat_currentItemChanged(
const QModelIndex ¤t,
const QModelIndex &previous);
215 void on_automaticUpdateCheckBox_toggled(
bool checked);
216 void on_newToolButton_clicked();
217 void on_deleteToolButton_clicked();
218 void on_copyToolButton_clicked();
219 void on_clearToolButton_clicked();
220 void on_moveUpwardsToolButton_clicked();
221 void on_moveDownwardsToolButton_clicked();
222 void on_dragRadioButton_toggled(
bool checked);
223 void on_zoomRadioButton_toggled(
bool checked);
224 void on_actionReset_triggered();
225 void on_actionZoomIn_triggered();
226 void on_actionZoomInX_triggered();
227 void on_actionZoomInY_triggered();
228 void on_actionZoomOut_triggered();
229 void on_actionZoomOutX_triggered();
230 void on_actionZoomOutY_triggered();
231 void on_actionMoveUp10_triggered();
232 void on_actionMoveLeft10_triggered();
233 void on_actionMoveRight10_triggered();
234 void on_actionMoveDown10_triggered();
235 void on_actionMoveUp1_triggered();
236 void on_actionMoveLeft1_triggered();
237 void on_actionMoveRight1_triggered();
238 void on_actionMoveDown1_triggered();
239 void on_actionGoToPacket_triggered();
240 void on_actionDragZoom_triggered();
241 void on_actionToggleTimeOrigin_triggered();
242 void on_actionCrosshairs_triggered();
243 void on_buttonBox_helpRequested();
244 void on_buttonBox_accepted();
245 void buttonBoxClicked(QAbstractButton *button);
246 void actionLegendTriggered(
bool checked);
247 void actionTimeOfDayTriggered(
bool checked);
248 void actionLogScaleTriggered(
bool checked);