PrintLayout: a whitespace fix

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: disable the QPainter scaling

This is wrong because we don't really need to scale. We already
have the estimated page dimentions in pixels, so taking the
quotient of the printer DPI and screen DPI and then scaling
(probably up) our rendered widgets via the QPainter introduces
blur (due to the oversampling), and a performance penalty.

By rendering at the exact dimensions we ensure that the widgets
are crisp at a 100% printout.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: fix the ProfilePrintModel font

Fixing the font size is required, because we don't really support
a dynamic row height, as the row height is set in the class
constructor.

7 seems optimal for all print modes.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: draw the profile to a QImage only on Linux

The QImage fix for the recently reported
"huge-vector-lines-in-PDF-printouts" bug is only needed on Linux.

For Win32 and OSx we can render to vector.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: modify the profile font size based on the #dives per page

For the profile print, the number of dives per page is:
divesPerRow * divesPerColumn

If we have more 3, 0.6 seems optimal, while for less we can
pretty much use the default scale of 1.0.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: reduce the scope of 'pic' and 'picPainter'

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
PrintLayout: vectorize the table print

Use QPicture to do that.

QPainter::drawPicture() requires offsetting the target QPoint's
Y value by two times the headingRow height.
This can be improved the hardcodding the offset when the
'pageIndexes' are calculated, but is a bit complicated.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>