From 5ec3015fc62439a3cf7693b25a41ed3e1bed0ffe Mon Sep 17 00:00:00 2001 From: Nils <> Date: Sun, 6 Oct 2019 13:10:04 +0200 Subject: [PATCH] remove warning message so that we can finally switch on opengl for gridview without the terminal getting spammed --- qtgui/mainwindow.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/qtgui/mainwindow.py b/qtgui/mainwindow.py index e723df6..acdfeea 100644 --- a/qtgui/mainwindow.py +++ b/qtgui/mainwindow.py @@ -141,7 +141,12 @@ class MainWindow(TemplateMainWindow): self.patternGrid = PatternGrid(parentView=self.ui.gridView) self.ui.gridView.setScene(self.patternGrid) self.ui.gridView.setRenderHints(QtGui.QPainter.TextAntialiasing) - #self.ui.gridView.setViewport(QtWidgets.QOpenGLWidget()) + self.ui.gridView.setViewport(QtWidgets.QOpenGLWidget()) #TODO: QT BUG! Review in the far future. + #ProxyWidget-Items in an openGl accel. GraphicsView create a ton of messages: Unsupported composition mode + #But everything works. Install a message handler to just get rid of the warning. + def passHandler(msg_type, msg_log_context, msg_string): + pass + QtCore.qInstallMessageHandler(passHandler) self.patternToolbar = QtWidgets.QToolBar() self.ui.patternArea.layout().insertWidget(0, self.patternToolbar)