summaryrefslogtreecommitdiffstats
path: root/src/printsupport/kernel/qprinter_p.h
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2013-12-05 18:52:38 +0100
committerFrederik Gladhorn <frederik.gladhorn@digia.com>2013-12-05 18:52:38 +0100
commitf6dbdd9c16166f345fd5743886229192c97c2c4f (patch)
tree05e5e7b806dd627be4e3ba6fc9a32f115847acb0 /src/printsupport/kernel/qprinter_p.h
parentb8084618545570a8832d344a2e9586e1226cc697 (diff)
parent47efa9213d92a4366e03bd6d056837cd5bbadb1e (diff)
Merge remote-tracking branch 'origin/stable' into dev
Conflicts: src/sql/drivers/sqlite/qsql_sqlite.cpp Change-Id: Ia7cffd2c99ae3d5eea6b5740683c06e921336dcd
Diffstat (limited to 'src/printsupport/kernel/qprinter_p.h')
-rw-r--r--src/printsupport/kernel/qprinter_p.h33
1 files changed, 21 insertions, 12 deletions
diff --git a/src/printsupport/kernel/qprinter_p.h b/src/printsupport/kernel/qprinter_p.h
index 2bec44aae6..2357b9e944 100644
--- a/src/printsupport/kernel/qprinter_p.h
+++ b/src/printsupport/kernel/qprinter_p.h
@@ -59,8 +59,10 @@
#ifndef QT_NO_PRINTER
#include "QtPrintSupport/qprinter.h"
+#include "QtPrintSupport/qprinterinfo.h"
#include "QtPrintSupport/qprintengine.h"
#include "QtCore/qpointer.h"
+#include "QtCore/qset.h"
#include <limits.h>
@@ -75,14 +77,19 @@ class Q_PRINTSUPPORT_EXPORT QPrinterPrivate
Q_DECLARE_PUBLIC(QPrinter)
public:
QPrinterPrivate(QPrinter *printer)
- : printEngine(0)
- , paintEngine(0)
- , q_ptr(printer)
- , printRange(QPrinter::AllPages)
- , use_default_engine(true)
- , validPrinter(false)
- , hasCustomPageMargins(false)
- , hasUserSetPageSize(false)
+ : printEngine(0),
+ paintEngine(0),
+ realPrintEngine(0),
+ realPaintEngine(0),
+#ifndef QT_NO_PRINTPREVIEWWIDGET
+ previewEngine(0),
+#endif
+ q_ptr(printer),
+ printRange(QPrinter::AllPages),
+ use_default_engine(true),
+ validPrinter(false),
+ hasCustomPageMargins(false),
+ hasUserSetPageSize(false)
{
}
@@ -90,15 +97,17 @@ public:
}
- void init(QPrinter::PrinterMode mode);
+ void init(const QPrinterInfo &printer, QPrinter::PrinterMode mode);
- void createDefaultEngines();
+ QPrinterInfo findValidPrinter(const QPrinterInfo &printer = QPrinterInfo());
+ void initEngines(QPrinter::OutputFormat format, const QPrinterInfo &printer);
+ void changeEngines(QPrinter::OutputFormat format, const QPrinterInfo &printer);
#ifndef QT_NO_PRINTPREVIEWWIDGET
QList<const QPicture *> previewPages() const;
void setPreviewMode(bool);
#endif
- void addToManualSetList(QPrintEngine::PrintEnginePropertyKey key);
+ void setProperty(QPrintEngine::PrintEnginePropertyKey key, const QVariant &value);
QPrinter::PrinterMode printerMode;
QPrinter::OutputFormat outputFormat;
@@ -123,7 +132,7 @@ public:
uint hasUserSetPageSize : 1;
// Used to remember which properties have been manually set by the user.
- QList<QPrintEngine::PrintEnginePropertyKey> manualSetList;
+ QSet<QPrintEngine::PrintEnginePropertyKey> m_properties;
};
QT_END_NAMESPACE