Qt
6.x
The Qt SDK
Loading...
Searching...
No Matches
qpagesetupdialog_unix_p.h
Go to the documentation of this file.
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
#ifndef QPAGESETUPDIALOG_UNIX_P_H
4
#define QPAGESETUPDIALOG_UNIX_P_H
5
6
//
7
// W A R N I N G
8
// -------------
9
//
10
// This file is not part of the Qt API. It exists purely as an
11
// implementation detail. This header file may change from version to
12
// to version without notice, or even be removed.
13
//
14
// We mean it.
15
//
16
//
17
18
#include <QtPrintSupport/private/qtprintsupportglobal_p.h>
19
20
#include "
qprinter.h
"
21
#include "
kernel/qprint_p.h
"
22
23
#include <QtGui/qpagelayout.h>
24
25
#include <ui_qpagesetupwidget.h>
26
27
QT_REQUIRE_CONFIG
(printdialog);
28
29
QT_BEGIN_NAMESPACE
30
31
class
QPrinter
;
32
class
QPrintDevice
;
33
class
QPagePreview
;
34
35
class
QPageSetupWidget
:
public
QWidget
{
36
Q_OBJECT
37
public
:
38
explicit
QPageSetupWidget
(
QWidget
*
parent
=
nullptr
);
39
40
void
setPrinter
(
QPrinter
*printer,
QPrintDevice
*printDevice,
41
QPrinter::OutputFormat
outputFormat,
const
QString
&printerName);
42
void
setupPrinter
()
const
;
43
void
updateSavedValues
();
44
void
revertToSavedValues
();
45
46
#if QT_CONFIG(cups)
47
bool
hasPpdConflict()
const
;
48
49
signals
:
50
void
ppdOptionChanged();
51
#endif
52
53
private
slots
:
54
void
pageSizeChanged();
55
void
pageOrientationChanged();
56
void
pagesPerSheetChanged();
57
void
unitChanged();
58
void
topMarginChanged(
double
newValue);
59
void
bottomMarginChanged(
double
newValue);
60
void
leftMarginChanged(
double
newValue);
61
void
rightMarginChanged(
double
newValue);
62
63
private
:
64
friend
class
QUnixPrintWidgetPrivate
;
// Needed by checkFields()
65
66
void
updateWidget();
67
void
initUnits();
68
void
initPagesPerSheet();
69
void
initPageSizes();
70
71
Ui::QPageSetupWidget m_ui;
72
QPagePreview
*m_pagePreview;
73
QPrinter
*m_printer;
74
QPrintDevice
*m_printDevice;
75
#if QT_CONFIG(cups)
76
ppd_option_t *m_pageSizePpdOption;
77
#endif
78
QPrinter::OutputFormat
m_outputFormat;
79
QString
m_printerName;
80
QPageLayout
m_pageLayout;
81
QPageLayout
m_savedPageLayout;
82
QPageLayout::Unit
m_units;
83
QPageLayout::Unit
m_savedUnits;
84
int
m_savedPagesPerSheet;
85
int
m_savedPagesPerSheetLayout;
86
bool
m_blockSignals;
87
int
m_realCustomPageSizeIndex;
88
};
89
90
QT_END_NAMESPACE
91
92
#endif
QObject::parent
QObject * parent() const
Returns a pointer to the parent object.
Definition
qobject.h:311
QPageLayout
\inmodule QtGui
Definition
qpagelayout.h:20
QPageLayout::Unit
Unit
This enum type is used to specify the measurement unit for page layout and margins.
Definition
qpagelayout.h:24
QPagePreview
Definition
qpagesetupdialog_unix.cpp:67
QPageSetupWidget
Definition
qpagesetupdialog_unix_p.h:35
QPageSetupWidget::revertToSavedValues
void revertToSavedValues()
Definition
qpagesetupdialog_unix.cpp:519
QPageSetupWidget::setPrinter
void setPrinter(QPrinter *printer, QPrintDevice *printDevice, QPrinter::OutputFormat outputFormat, const QString &printerName)
Definition
qpagesetupdialog_unix.cpp:363
QPageSetupWidget::setupPrinter
void setupPrinter() const
Definition
qpagesetupdialog_unix.cpp:495
QPageSetupWidget::updateSavedValues
void updateSavedValues()
Definition
qpagesetupdialog_unix.cpp:511
QPrintDevice
Definition
qprintdevice_p.h:34
QPrinter
\reentrant
Definition
qprinter.h:28
QPrinter::OutputFormat
OutputFormat
The OutputFormat enum is used to describe the format QPrinter should use for printing.
Definition
qprinter.h:69
QString
\macro QT_RESTRICTED_CAST_FROM_ASCII
Definition
qstring.h:127
QUnixPrintWidgetPrivate
Definition
qprintdialog_unix.cpp:160
QWidget
The QWidget class is the base class of all user interface objects.
Definition
qwidget.h:99
QT_BEGIN_NAMESPACE
Combined button and popup list for selecting options.
Definition
qstandardpaths_haiku.cpp:21
QT_END_NAMESPACE
Definition
qsharedpointer.cpp:1545
qprint_p.h
qprinter.h
QT_REQUIRE_CONFIG
#define QT_REQUIRE_CONFIG(feature)
Definition
qtconfigmacros.h:66
Q_OBJECT
#define Q_OBJECT
Definition
qtmetamacros.h:117
slots
#define slots
Definition
qtmetamacros.h:40
signals
#define signals
Definition
qtmetamacros.h:41
qtbase
src
printsupport
dialogs
qpagesetupdialog_unix_p.h
Generated by
1.9.7