QElectroTech 0.200.1-dev
Loading...
Searching...
No Matches
pdfpagesdialog.h
Go to the documentation of this file.
1/*
2 Copyright 2006-2026 The QElectroTech Team
3 This file is part of QElectroTech.
4
5 QElectroTech is free software: you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation, either version 2 of the License, or
8 (at your option) any later version.
9
10 QElectroTech is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
14
15 You should have received a copy of the GNU General Public License
16 along with QElectroTech. If not, see <http://www.gnu.org/licenses/>.
17*/
18#ifndef PDFPAGESDIALOG_H
19#define PDFPAGESDIALOG_H
20
21// Needs the QtPdf module (QET_HAS_QTPDF, set by CMake only when QtPdf
22// is present AND Qt >= 6.4, for QPdfDocument::pagePointSize()).
23#ifdef QET_HAS_QTPDF
24
25#include <QDialog>
26
27class QSpinBox;
28class QComboBox;
29class QLabel;
30class QPdfDocument;
31
38class PdfPagesDialog : public QDialog
39{
40 Q_OBJECT
41
42 public:
43 explicit PdfPagesDialog(QPdfDocument &document, QWidget *parent = nullptr);
44 int selectedPage() const;
45 int selectedDpi() const;
46
47 private slots:
48 void updatePreview();
49
50 private:
51 QPdfDocument &m_document;
52 QLabel *m_info_label;
53 QLabel *m_preview_label;
54 QSpinBox *m_page_spinbox;
55 QComboBox *m_dpi_combo;
56};
57
58#endif // QET_HAS_QTPDF
59
60#endif // PDFPAGESDIALOG_H