- fixed error that did not allowed printing from the TextEditor

- added an error message when the File -> Print to PDF functionality is not working due of missing a root element in the SVG step
This commit is contained in:
Marius Stanciu
2021-10-28 20:11:06 +03:00
committed by Marius Stanciu
parent 9ff8f15b67
commit de4c51b480
4 changed files with 28 additions and 8 deletions

View File

@@ -176,7 +176,7 @@ class AppTextEditor(QtWidgets.QWidget):
def handlePrint(self):
dialog = QtPrintSupport.QPrintDialog()
if dialog.exec() == QtWidgets.QDialog.DialogCode.Accepted:
self.code_editor.document().print_(dialog.printer())
self.code_editor.document().print(dialog.printer())
def handlePreview(self):
dialog = QtPrintSupport.QPrintPreviewDialog()