Exemplo n.º 1
0
    def printdoc(self):
        """
        Prints the document in the view
        """
        printer = QPrinter()

        setup = QPageSetupDialog(printer)
        setup.setWindowTitle("Print - Page Settings")

        if setup.exec_() == QDialog.Accepted:
            dialog = QPrintDialog(printer, self)
            dialog.setWindowTitle("Print Document")

            if dialog.exec_() == QDialog.Accepted:
                self.ui.webviewResult.print_(printer)
Exemplo n.º 2
0
 def on_actionPageSetup_triggered(self):
     dlg = QPageSetupDialog(self.printer, self)
     dlg.exec_()