Commit 49c47377 authored by Samuel GAIST's avatar Samuel GAIST
Browse files

[utils] Add helper method to check Qt version

parent 95cf4bf4
......@@ -38,6 +38,8 @@ import pkg_resources
import jinja2
from functools import wraps
from packaging import version
from PyQt5 import QtCore
logger = logging.getLogger(__name__)
......@@ -262,3 +264,7 @@ def dataformat_basetypes():
common_data = pkg_resources.resource_string("beat.core", "schema/common/1.json")
common_data = json.loads(common_data)
return common_data["definitions"]["basetype"]["enum"]
def is_Qt_equal_or_higher(version_string):
return version.parse(QtCore.QT_VERSION_STR) >= version.parse(version_string)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment