mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Print: add experimental code for printing profiles
PrintLayout::printSixDives() goes trough all dives and prints their profiles on full portrait pages. This method is based on resizing the ProfileGraphicsView widget, plotting each dive and then 'grabbing' it using QPixmap::grabWidget(). Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This commit is contained in:
parent
8ea849d0c2
commit
b241b7c06a
2 changed files with 39 additions and 7 deletions
|
@ -47,6 +47,7 @@ void PrintDialog::printClicked(void)
|
|||
// printer.setOutputFileName("print.pdf");
|
||||
// printer.setOutputFormat(QPrinter::PdfFormat);
|
||||
// temporary: use a preview dialog
|
||||
printer.setResolution(300);
|
||||
QPrintPreviewDialog previewDialog(&printer, this);
|
||||
QObject::connect(&previewDialog, SIGNAL(paintRequested(QPrinter *)), this, SLOT(onPaintRequested(QPrinter *)));
|
||||
previewDialog.exec();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue