diff options
author | Miikka Heikkinen <miikka.heikkinen@digia.com> | 2012-03-21 17:17:42 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-03-23 00:41:34 +0100 |
commit | b188221fee0eaacec115b514185a0508ef655897 (patch) | |
tree | 167b09e47cc3b63dadf64527339a4248eda770b3 /src/printsupport/kernel/qprinter.h | |
parent | 82c974f753e0081f8bedc356ea07a8cfa6fae583 (diff) |
Fix QPrinter test in Windows
Fixed Q_WS_WIN flagging to Q_OS_WIN in QPrinter API and related
implementation to make API match the documentation and Qt 4.8.
Also Removed the unused internal HDC related functions from the API,
that were previously behind Q_WS_WIN flag.
Some of the properties tested are documented to be valid for native
print engine only in X11 environment, so skipped testing those in
non-xcb environments.
Copy collation is also apparently not supported in Windows native print
engine, though this seems to be undocumented, so skipped that only in
Windows.
At least one of the test blocks in tst_QPrinter::valuePreservation()
failed due to default printer not getting set properly, so fixed that,
too.
Task-number: QTBUG-24191
Task-number: QTBUG-22927
Change-Id: I44a5e3d647a1279fcc7f1e99de6881f9be330246
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Diffstat (limited to 'src/printsupport/kernel/qprinter.h')
-rw-r--r-- | src/printsupport/kernel/qprinter.h | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/src/printsupport/kernel/qprinter.h b/src/printsupport/kernel/qprinter.h index 17b125bbf8..23c7ccc40c 100644 --- a/src/printsupport/kernel/qprinter.h +++ b/src/printsupport/kernel/qprinter.h @@ -200,7 +200,7 @@ public: QList<int> supportedResolutions() const; -#ifdef Q_WS_WIN +#ifdef Q_OS_WIN QList<PaperSource> supportedPaperSources() const; #endif @@ -210,7 +210,7 @@ public: void setDoubleSidedPrinting(bool enable); bool doubleSidedPrinting() const; -#ifdef Q_WS_WIN +#ifdef Q_OS_WIN void setWinPageSize(int winPageSize); int winPageSize() const; #endif @@ -220,7 +220,7 @@ public: QRectF paperRect(Unit) const; QRectF pageRect(Unit) const; -#if !defined(Q_WS_WIN) || defined(qdoc) +#if !defined(Q_OS_WIN) || defined(qdoc) QString printerSelectionOption() const; void setPrinterSelectionOption(const QString &); #endif @@ -233,11 +233,6 @@ public: QPaintEngine *paintEngine() const; QPrintEngine *printEngine() const; -#ifdef Q_WS_WIN - HDC getDC() const; - void releaseDC(HDC hdc) const; -#endif - void setFromTo(int fromPage, int toPage); int fromPage() const; int toPage() const; |