Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
qpdfpageselector.h
Go to the documentation of this file.
1// Copyright (C) 2023 The Qt Company Ltd.
2// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
3
4#ifndef QPDFPAGESELECTOR_H
5#define QPDFPAGESELECTOR_H
6
7#include <QtPdfWidgets/qtpdfwidgetsglobal.h>
8
9#include <QtWidgets/qwidget.h>
10
11#include <memory>
12
14
15class QPdfDocument;
17
19{
21
22 Q_PROPERTY(QPdfDocument* document READ document WRITE setDocument NOTIFY documentChanged)
23 Q_PROPERTY(int currentPage READ currentPage WRITE setCurrentPage NOTIFY currentPageChanged USER true)
24 Q_PROPERTY(QString currentPageLabel READ currentPageLabel NOTIFY currentPageLabelChanged)
25public:
27 explicit QPdfPageSelector(QWidget *parent);
29
30 void setDocument(QPdfDocument *document);
31 QPdfDocument *document() const;
32
33 int currentPage() const;
34 QString currentPageLabel() const;
35
36public Q_SLOTS:
37 void setCurrentPage(int index);
38
43
44private:
45 Q_DECLARE_PRIVATE(QPdfPageSelector)
46 const std::unique_ptr<QPdfPageSelectorPrivate> d_ptr;
47};
48
50
51#endif // QPDFPAGESELECTOR_H
QScopedPointer< QObjectData > d_ptr
Definition qobject.h:373
The QPdfDocument class loads a PDF document and renders pages from it.
\inmodule QtPdf
void currentPageLabelChanged(const QString &label)
void currentPageChanged(int index)
~QPdfPageSelector() override
Destroys the page selector.
void documentChanged(QPdfDocument *document)
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition qstring.h:129
The QWidget class is the base class of all user interface objects.
Definition qwidget.h:99
Combined button and popup list for selecting options.
GLuint index
[2]
GLuint GLsizei const GLchar * label
[43]
#define Q_PROPERTY(...)
#define Q_OBJECT
#define Q_SLOTS
#define Q_SIGNALS
#define Q_PDF_WIDGETS_EXPORT