Fix plaintext printing >2 pages
This commit is contained in:
parent
5799985c92
commit
6e2ded84e2
1 changed files with 2 additions and 0 deletions
|
@ -454,6 +454,7 @@ try {
|
||||||
|
|
||||||
while(true)
|
while(true)
|
||||||
{
|
{
|
||||||
|
painter.save();
|
||||||
painter.translate(body.left(), body.top() - p*body.height());
|
painter.translate(body.left(), body.top() - p*body.height());
|
||||||
QRectF view(0, p*body.height(), body.width(), body.height());
|
QRectF view(0, p*body.height(), body.width(), body.height());
|
||||||
painter.setClipRect(view);
|
painter.setClipRect(view);
|
||||||
|
@ -462,6 +463,7 @@ try {
|
||||||
context.clip = view;
|
context.clip = view;
|
||||||
context.palette.setColor(QPalette::Text, Qt::black);
|
context.palette.setColor(QPalette::Text, Qt::black);
|
||||||
doc.documentLayout()->draw(&painter, context);
|
doc.documentLayout()->draw(&painter, context);
|
||||||
|
painter.restore();
|
||||||
|
|
||||||
p++;
|
p++;
|
||||||
pageCount++;
|
pageCount++;
|
||||||
|
|
Loading…
Reference in a new issue