Wireshark 4.5.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
print_dialog.h
Go to the documentation of this file.
1
10#ifndef PRINT_DIALOG_H
11#define PRINT_DIALOG_H
12
13#include <config.h>
14
15#include "file.h"
16
17#include <QDialog>
18#include <QPrinter>
19#include <QPrintPreviewWidget>
20#include <QPushButton>
21
22namespace Ui {
23 class PrintDialog;
24}
25
26class PrintDialog : public QDialog
27{
28 Q_OBJECT
29
30public:
31 explicit PrintDialog(QWidget *parent = 0, capture_file *cf = NULL, QString selRange = QString());
33
34 bool printHeader();
35 bool printLine(int indent, const char *line);
36
37protected:
38 virtual void keyPressEvent(QKeyEvent *event) override;
39
40private:
41 Ui::PrintDialog *pd_ui_;
42
43 QPrinter printer_;
44 QPrinter *cur_printer_;
45 QPainter *cur_painter_;
46 QPrintPreviewWidget *preview_;
47 QPushButton *print_bt_;
48 QFont header_font_;
49 QFont packet_font_;
50public:
51 capture_file *cap_file_;
52private:
53 print_args_t print_args_;
54 print_stream_ops_t stream_ops_;
55 print_stream_t stream_;
56 int page_pos_;
57 bool in_preview_;
58
59 void printPackets(QPrinter *printer = NULL, bool in_preview = false);
60
61private slots:
62 void paintPreview(QPrinter *printer);
63 void checkValidity();
64 void on_buttonBox_helpRequested();
65 void on_buttonBox_clicked(QAbstractButton *button);
66};
67
68
69#endif // PRINT_DIALOG_H
Definition print_dialog.h:27
Definition cfile.h:67
Definition file.h:438
Definition print_stream.h:31
Definition print_stream.h:43