From a5cb72fe9eadfaf8cb0aefccb106a7eaad9266c9 Mon Sep 17 00:00:00 2001 From: Gerald Combs Date: Tue, 11 Feb 2014 16:07:10 -0800 Subject: Add a Qt I/O Graph dialog. For each graph you can set: - Its visibility - A name - A display filter - Color, from a fixed list - Plot style: Line, Impulse, Bar, Stacked Bar, Dot, Square, Diamond - Basic Y Axes (packets/s, bytes/s, bits/s) - Computed Y Axes (SUM, MIN, AVG, MAX) - Smoothing You can pan and zoom using the mouse and keyboard. Clicking on a graph selects the last packet for that interval. If all graphs have the same Y axis a single label is shown, otherwise a legend is shown. The time scale (X axis) can be toggled between relative seconds and the time of day. Graphs can be saved as PDF, PNG, BMP, and JPEG. Settings are "sticky" via the io_graphs UAT. To do: - Minimize graph drawing delays. - Figure out why smoothing differs from GTK+ - Everything else at the top of io_graph_dialog.cpp - Fix empty resets. A fair amount of code was copied from TCPStreamDialog. We might want to subclass QCustomPlot and place the shared code there. Move common syntax checking to SyntaxLineEdit. Move some common code from ui/gtk/io_stat.c to ui/io_graph_item.[ch] and use it in both GTK+ and Qt. Make the io_graph_item_t array allocation in io_stat.c static. The behavior should be identical and this gives us additional compile-time checks. Change-Id: I9a3d544469b7048f0761fdbf7bcf20f44ae76577 Reviewed-on: https://code.wireshark.org/review/435 Reviewed-by: Gerald Combs Tested-by: Gerald Combs --- ui/qt/io_graph_dialog.ui | 506 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 506 insertions(+) create mode 100644 ui/qt/io_graph_dialog.ui (limited to 'ui/qt/io_graph_dialog.ui') diff --git a/ui/qt/io_graph_dialog.ui b/ui/qt/io_graph_dialog.ui new file mode 100644 index 0000000000..c2b43846ad --- /dev/null +++ b/ui/qt/io_graph_dialog.ui @@ -0,0 +1,506 @@ + + + IOGraphDialog + + + + 0 + 0 + 850 + 640 + + + + Dialog + + + + + + + 0 + 4 + + + + + + + + <html><head/><body> + +<h3>Valuable and amazing time-saving keyboard shortcuts</h3> +<table><tbody> + +<tr><th>+</th><td>Zoom in</td></th> +<tr><th>-</th><td>Zoom out</td></th> +<tr><th>0</th><td>Reset graph to its initial state</td></th> + +<tr><th>→</th><td>Move right 10 pixels</td></th> +<tr><th>←</th><td>Move left 10 pixels</td></th> +<tr><th>↑</th><td>Move up 10 pixels</td></th> +<tr><th>↓</th><td>Move down 10 pixels</td></th> +<tr><th><i>Shift+</i>→</th><td>Move right 1 pixel</td></th> +<tr><th><i>Shift+</i>←</th><td>Move left 1 pixel</td></th> +<tr><th><i>Shift+</i>↑</th><td>Move up 1 pixel</td></th> +<tr><th><i>Shift+</i>↓</th><td>Move down 1 pixel</td></th> + +<tr><th>g</th><td>Go to packet under cursor</td></th> + +<tr><th>z</th><td>Toggle mouse drag / zoom</td></th> +<tr><th>t</th><td>Toggle capture / session time origin</td></th> +<tr><th>Space</th><td>Toggle crosshairs</td></th> + +</tbody></table> +</body></html> + + + + + + + + + + + 0 + 1 + + + + + Name + + + + + Display filter + + + + + Color + + + + + Style + + + + + Y Axis + + + + + Y Field + + + + + Smoothing + + + + + + + + + + Change the dissection behavior for a protocol. + + + + + + + :/stock/plus-8.png:/stock/plus-8.png + + + + + + + Remove this dissection behavior. + + + + :/stock/minus-8.png:/stock/minus-8.png + + + + + + + Copy this dissection behavior. + + + + + + + :/stock/copy-8.png:/stock/copy-8.png + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Mouse + + + + + + + Drag using the mouse button. + + + drags + + + true + + + + + + + Select using the mouse button. + + + zooms + + + true + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Interval + + + + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Time of day + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Log scale + + + + + + + Qt::Horizontal + + + + 40 + 20 + + + + + + + + Reset + + + + + + + + + Qt::Horizontal + + + QDialogButtonBox::Close|QDialogButtonBox::Help|QDialogButtonBox::Save + + + + + + + Reset Graph + + + Reset the graph to its initial state. + + + 0 + + + + + Zoom In + + + Zoom in + + + + + + + + + Zoom Out + + + Zoom out + + + - + + + + + Move Up 10 Pixels + + + Move up 10 pixels + + + Up + + + + + Move Left 10 Pixels + + + Move left 10 pixels + + + Left + + + + + Move Right 10 Pixels + + + Move right 10 pixels + + + Right + + + + + Move Down 10 Pixels + + + Move down 10 pixels + + + Down + + + + + Move Up 1 Pixel + + + Move up 1 pixel + + + Shift+Up + + + + + Move Left 1 Pixel + + + Move left 1 pixel + + + Shift+Left + + + + + Move Right 1 Pixel + + + Move right 1 pixel + + + Shift+Right + + + + + Move Down 1 Pixel + + + Move down 1 pixel + + + Shift+Down + + + + + Go To Packet Under Cursor + + + Go to packet currently under the cursor + + + G + + + + + Drag / Zoom + + + Toggle mouse drag / zoom behavior + + + Z + + + + + Capture / Session Time Origin + + + Toggle capture / session time origin + + + T + + + + + Crosshairs + + + Toggle crosshairs + + + Space + + + + + + QCustomPlot + QWidget +
qcustomplot.h
+ 1 +
+ + ElidedLabel + QLabel +
elided_label.h
+
+
+ + + + + + buttonBox + accepted() + IOGraphDialog + accept() + + + 248 + 254 + + + 157 + 274 + + + + + buttonBox + rejected() + IOGraphDialog + reject() + + + 316 + 260 + + + 286 + 274 + + + + +
-- cgit v1.2.3