--- a/Project/LexerAssociationDialog.py Sat May 13 13:46:05 2017 +0200 +++ b/Project/LexerAssociationDialog.py Sat May 13 16:32:54 2017 +0200 @@ -11,11 +11,13 @@ import os -from PyQt5.QtCore import Qt, pyqtSlot, qVersion +from PyQt5.QtCore import Qt, pyqtSlot from PyQt5.QtWidgets import QHeaderView, QTreeWidgetItem, QDialog from .Ui_LexerAssociationDialog import Ui_LexerAssociationDialog +from Globals import qVersionTuple + class LexerAssociationDialog(QDialog, Ui_LexerAssociationDialog): """ @@ -34,7 +36,7 @@ self.editorLexerList.headerItem().setText( self.editorLexerList.columnCount(), "") header = self.editorLexerList.header() - if qVersion() >= "5.0.0": + if qVersionTuple() >= (5, 0, 0): header.setSectionResizeMode(QHeaderView.ResizeToContents) else: header.setResizeMode(QHeaderView.ResizeToContents)