QtPrintSupport: set QPrinter margins also to QPagedPaintDevice
authorTeemu Katajisto <teemu.katajisto@digia.com>
Tue, 12 Jun 2012 11:54:46 +0000 (14:54 +0300)
committerQt by Nokia <qt-info@nokia.com>
Tue, 11 Sep 2012 10:09:47 +0000 (12:09 +0200)
commit5d1d313ca7771f20e5359f2a0bfe4082043787e9
treef38a54feea3c3bddf0e127c374d8b3fb9ad5e203
parentce0c3c49b1dc5812c4e84d7a037695a53d764b7e
QtPrintSupport: set QPrinter margins also to QPagedPaintDevice

QPagedPaintDevice::setMargins() is virtual method and reimplemented in
QPrinter but super class margins were not set in reimplemented method.

This fixes problem where QTextDocument::print() checked the margins
using QPagedPaintDevice::margins() and overrided the margins set
in QPrinter::setMargins().

Change-Id: I3bdcc33b8f6b5a9cbcb04a21484fdd1612dd7d58
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
src/printsupport/kernel/qprinter.cpp