Skip to content

Commit

Permalink
Fix #15861: Printing scores prints square the number of requested copies
Browse files Browse the repository at this point in the history
On most systems, the QPrinter already prints n copies of what we feed it with, so we ourselves don't need to feed it with n copies too.
  • Loading branch information
cbjeukendrup authored and RomanPudashkin committed Jan 27, 2023
1 parent c938e80 commit 18b9e17
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/print/internal/printprovider.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,8 @@ Ret PrintProvider::printNotation(INotationPtr notation)
INotationPainting::Options opt;
opt.fromPage = printerDev.fromPage() - 1;
opt.toPage = printerDev.toPage() - 1;
opt.copyCount = printerDev.copyCount();
// See https://doc.qt.io/qt-5/qprinter.html#supportsMultipleCopies
opt.copyCount = printerDev.supportsMultipleCopies() ? 1 : printerDev.copyCount();
opt.deviceDpi = printerDev.logicalDpiX();
opt.onNewPage = [&printerDev]() { printerDev.newPage(); };

Expand Down

0 comments on commit 18b9e17

Please sign in to comment.