| 1 | // Copyright (C) 2016 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 QPAGEDPAINTDEVICE_P_H |
| 5 | #define QPAGEDPAINTDEVICE_P_H |
| 6 | |
| 7 | // |
| 8 | // W A R N I N G |
| 9 | // ------------- |
| 10 | // |
| 11 | // This file is not part of the Qt API. It exists purely as an |
| 12 | // implementation detail. This header file may change from version to |
| 13 | // version without notice, or even be removed. |
| 14 | // |
| 15 | // We mean it. |
| 16 | // |
| 17 | |
| 18 | #include <QtGui/private/qtguiglobal_p.h> |
| 19 | #include <qpagedpaintdevice.h> |
| 20 | |
| 21 | QT_BEGIN_NAMESPACE |
| 22 | |
| 23 | class Q_GUI_EXPORT QPagedPaintDevicePrivate |
| 24 | { |
| 25 | public: |
| 26 | QPagedPaintDevicePrivate() |
| 27 | : pageOrderAscending(true), |
| 28 | printSelectionOnly(false) |
| 29 | { |
| 30 | } |
| 31 | |
| 32 | virtual ~QPagedPaintDevicePrivate(); |
| 33 | |
| 34 | |
| 35 | virtual bool setPageLayout(const QPageLayout &newPageLayout) = 0; |
| 36 | |
| 37 | virtual bool setPageSize(const QPageSize &pageSize) = 0; |
| 38 | |
| 39 | virtual bool setPageOrientation(QPageLayout::Orientation orientation) = 0; |
| 40 | |
| 41 | virtual bool setPageMargins(const QMarginsF &margins, QPageLayout::Unit units) = 0; |
| 42 | |
| 43 | virtual QPageLayout pageLayout() const = 0; |
| 44 | |
| 45 | static inline QPagedPaintDevicePrivate *get(QPagedPaintDevice *pd) { return pd->d; } |
| 46 | |
| 47 | // These are currently required to keep QPrinter functionality working in QTextDocument::print() |
| 48 | QPageRanges ; |
| 49 | bool pageOrderAscending; |
| 50 | bool printSelectionOnly; |
| 51 | }; |
| 52 | |
| 53 | QT_END_NAMESPACE |
| 54 | |
| 55 | #endif |
| 56 | |