def calibration_pdf(self, image):
    printer = QPrinter()
    printer.setPaperSize(QSizeF(210, 297), QPrinter.Millimeter)
    printer.setResolution(600)
    printer.setOutputFormat(QPrinter.PdfFormat)
    printer.setOutputFileName(self.get_path_to_calibration_file())
    printer.setPageMargins(0, 0, 0, 0, 6)
    painter = QPainter()
    painter.begin(printer)
    painter.drawImage(553, 533, image)
    font = QFont('Source Sans Pro', 10, QFont.Bold)
    painter.setFont(font)
    painter.drawText(254, 277, _('Calibration sheet'))
    font = QFont('Source Sans Pro', 7, QFont.Bold)
    painter.setFont(font)
    painter.drawText(600, 2077, _('Instructions:'))
    font = QFont('Source Sans Pro', 7, QFont.Normal)
    painter.setFont(font)
    painter.drawText(700, 2177, _('1. Place this paper on a flat and well iluminated surface.'))
    painter.drawText(700, 2277, _('2. Align your Revealer borderlines to the dashed lines on the top and left.'))
    painter.drawText(700, 2377, _('3. Press slightly the Revealer against the paper and read the numbers that best match on the opposite sides. '))
    painter.drawText(700, 2477, _('4. Type the numbers in the software'))
    painter.end()
def calibration_pdf(self, image):
    printer = QPrinter()
    printer.setPaperSize(QSizeF(210, 297), QPrinter.Millimeter)
    printer.setResolution(600)
    printer.setOutputFormat(QPrinter.PdfFormat)
    printer.setOutputFileName(self.get_path_to_calibration_file())
    printer.setPageMargins(0, 0, 0, 0, 6)
    painter = QPainter()
    painter.begin(printer)
    painter.drawImage(553, 533, image)
    font = QFont('Source Sans Pro', 10, QFont.Bold)
    painter.setFont(font)
    painter.drawText(254, 277, _('Calibration sheet'))
    font = QFont('Source Sans Pro', 7, QFont.Bold)
    painter.setFont(font)
    painter.drawText(600, 2077, _('Instructions:'))
    font = QFont('Source Sans Pro', 7, QFont.Normal)
    painter.setFont(font)
    painter.drawText(700, 2177, _('1. Place this paper on a flat and well iluminated surface.'))
    painter.drawText(700, 2277, _('2. Align your Revealer borderlines to the dashed lines on the top and left.'))
    painter.drawText(700, 2377, _('3. Press slightly the Revealer against the paper and read the numbers that best match on the opposite sides. '))
    painter.drawText(700, 2477, _('4. Type the numbers in the software'))
    painter.end()