diff options
author | Remco Burema <r.burema@ultimaker.com> | 2021-12-28 16:46:02 +0300 |
---|---|---|
committer | Remco Burema <r.burema@ultimaker.com> | 2021-12-28 16:46:02 +0300 |
commit | abe7c1bf7f969562d63702e412e671b1e631c178 (patch) | |
tree | 86deda78b9b5de973c5a7ec03d6a1a3cebda9887 /cura | |
parent | f97f7ca6af8e9e718722d8d308b28c26ea20c290 (diff) |
Search/replace Qt5->Qt6.
part of upgrading Qt to v6.2: CURA-8591
Diffstat (limited to 'cura')
79 files changed, 108 insertions, 108 deletions
diff --git a/cura/API/Account.py b/cura/API/Account.py index 9f1184a0a0..ca4bfe1c32 100644 --- a/cura/API/Account.py +++ b/cura/API/Account.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from datetime import datetime -from PyQt5.QtCore import QObject, pyqtSignal, pyqtSlot, pyqtProperty, QTimer, Q_ENUMS +from PyQt6.QtCore import QObject, pyqtSignal, pyqtSlot, pyqtProperty, QTimer, Q_ENUMS from typing import Any, Optional, Dict, TYPE_CHECKING, Callable from UM.Logger import Logger diff --git a/cura/API/ConnectionStatus.py b/cura/API/ConnectionStatus.py index 36f804e3cf..bcdddb717a 100644 --- a/cura/API/ConnectionStatus.py +++ b/cura/API/ConnectionStatus.py @@ -1,6 +1,6 @@ from typing import Optional -from PyQt5.QtCore import QObject, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QObject, pyqtSignal, pyqtProperty from UM.TaskManagement.HttpRequestManager import HttpRequestManager diff --git a/cura/API/__init__.py b/cura/API/__init__.py index 447be98e4b..3fca8e9c39 100644 --- a/cura/API/__init__.py +++ b/cura/API/__init__.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Optional, TYPE_CHECKING -from PyQt5.QtCore import QObject, pyqtProperty +from PyQt6.QtCore import QObject, pyqtProperty from cura.API.Backups import Backups from cura.API.ConnectionStatus import ConnectionStatus diff --git a/cura/AutoSave.py b/cura/AutoSave.py index 3205f48af1..c8ea9b756f 100644 --- a/cura/AutoSave.py +++ b/cura/AutoSave.py @@ -1,7 +1,7 @@ # Copyright (c) 2021 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QTimer +from PyQt6.QtCore import QTimer from typing import Any, TYPE_CHECKING from UM.Logger import Logger diff --git a/cura/BuildVolume.py b/cura/BuildVolume.py index fc5691f034..372d6152fc 100755 --- a/cura/BuildVolume.py +++ b/cura/BuildVolume.py @@ -31,7 +31,7 @@ from cura.Settings.GlobalStack import GlobalStack from cura.Scene.CuraSceneNode import CuraSceneNode from cura.Settings.ExtruderManager import ExtruderManager -from PyQt5.QtCore import QTimer +from PyQt6.QtCore import QTimer if TYPE_CHECKING: diff --git a/cura/CameraAnimation.py b/cura/CameraAnimation.py index 37f230a30d..32086c8ba2 100644 --- a/cura/CameraAnimation.py +++ b/cura/CameraAnimation.py @@ -2,8 +2,8 @@ # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QVariantAnimation, QEasingCurve -from PyQt5.QtGui import QVector3D +from PyQt6.QtCore import QVariantAnimation, QEasingCurve +from PyQt6.QtGui import QVector3D from UM.Math.Vector import Vector diff --git a/cura/CrashHandler.py b/cura/CrashHandler.py index db44daa77c..4f3fb34f7f 100644 --- a/cura/CrashHandler.py +++ b/cura/CrashHandler.py @@ -20,9 +20,9 @@ try: except ImportError: with_sentry_sdk = False -from PyQt5.QtCore import QT_VERSION_STR, PYQT_VERSION_STR, QUrl -from PyQt5.QtWidgets import QDialog, QDialogButtonBox, QVBoxLayout, QLabel, QTextEdit, QGroupBox, QCheckBox, QPushButton -from PyQt5.QtGui import QDesktopServices +from PyQt6.QtCore import QT_VERSION_STR, PYQT_VERSION_STR, QUrl +from PyQt6.QtWidgets import QDialog, QDialogButtonBox, QVBoxLayout, QLabel, QTextEdit, QGroupBox, QCheckBox, QPushButton +from PyQt6.QtGui import QDesktopServices from UM.Application import Application from UM.Logger import Logger diff --git a/cura/CuraActions.py b/cura/CuraActions.py index 8b232ad1bf..193803325f 100644 --- a/cura/CuraActions.py +++ b/cura/CuraActions.py @@ -1,8 +1,8 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QObject, QUrl -from PyQt5.QtGui import QDesktopServices +from PyQt6.QtCore import QObject, QUrl +from PyQt6.QtGui import QDesktopServices from typing import List, cast from UM.Event import CallFunctionEvent diff --git a/cura/CuraApplication.py b/cura/CuraApplication.py index ebd1708bf5..76db5bfe04 100755 --- a/cura/CuraApplication.py +++ b/cura/CuraApplication.py @@ -8,10 +8,10 @@ import time from typing import cast, TYPE_CHECKING, Optional, Callable, List, Any, Dict import numpy -from PyQt5.QtCore import QObject, QTimer, QUrl, pyqtSignal, pyqtProperty, QEvent, Q_ENUMS -from PyQt5.QtGui import QColor, QIcon -from PyQt5.QtQml import qmlRegisterUncreatableType, qmlRegisterSingletonType, qmlRegisterType -from PyQt5.QtWidgets import QMessageBox +from PyQt6.QtCore import QObject, QTimer, QUrl, pyqtSignal, pyqtProperty, QEvent, Q_ENUMS +from PyQt6.QtGui import QColor, QIcon +from PyQt6.QtQml import qmlRegisterUncreatableType, qmlRegisterSingletonType, qmlRegisterType +from PyQt6.QtWidgets import QMessageBox import UM.Util import cura.Settings.cura_empty_instance_containers diff --git a/cura/CuraPackageManager.py b/cura/CuraPackageManager.py index 26d6591099..212993e19b 100644 --- a/cura/CuraPackageManager.py +++ b/cura/CuraPackageManager.py @@ -11,7 +11,7 @@ from UM.Resources import Resources #To find storage paths for some resource type if TYPE_CHECKING: from UM.Qt.QtApplication import QtApplication - from PyQt5.QtCore import QObject + from PyQt6.QtCore import QObject class CuraPackageManager(PackageManager): diff --git a/cura/CuraView.py b/cura/CuraView.py index 86d4254a7d..6b20cf18d3 100644 --- a/cura/CuraView.py +++ b/cura/CuraView.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtProperty, QUrl +from PyQt6.QtCore import pyqtProperty, QUrl from UM.Resources import Resources from UM.View.View import View diff --git a/cura/MachineAction.py b/cura/MachineAction.py index 74b742ef4d..15d9ab1ca1 100644 --- a/cura/MachineAction.py +++ b/cura/MachineAction.py @@ -4,7 +4,7 @@ import os from typing import Optional -from PyQt5.QtCore import QObject, QUrl, pyqtSlot, pyqtProperty, pyqtSignal +from PyQt6.QtCore import QObject, QUrl, pyqtSlot, pyqtProperty, pyqtSignal from UM.Logger import Logger from UM.PluginObject import PluginObject diff --git a/cura/Machines/MachineErrorChecker.py b/cura/Machines/MachineErrorChecker.py index 8213734348..bfefe80fa5 100644 --- a/cura/Machines/MachineErrorChecker.py +++ b/cura/Machines/MachineErrorChecker.py @@ -5,7 +5,7 @@ import time from collections import deque -from PyQt5.QtCore import QObject, QTimer, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QObject, QTimer, pyqtSignal, pyqtProperty from typing import Optional, Any, Set from UM.Logger import Logger diff --git a/cura/Machines/Models/BaseMaterialsModel.py b/cura/Machines/Models/BaseMaterialsModel.py index 776d540867..a32af77094 100644 --- a/cura/Machines/Models/BaseMaterialsModel.py +++ b/cura/Machines/Models/BaseMaterialsModel.py @@ -3,7 +3,7 @@ from typing import Dict, Set -from PyQt5.QtCore import Qt, QTimer, pyqtSignal, pyqtProperty +from PyQt6.QtCore import Qt, QTimer, pyqtSignal, pyqtProperty from UM.Qt.ListModel import ListModel from UM.Logger import Logger diff --git a/cura/Machines/Models/BuildPlateModel.py b/cura/Machines/Models/BuildPlateModel.py index 3697dd2762..ecceb73f0c 100644 --- a/cura/Machines/Models/BuildPlateModel.py +++ b/cura/Machines/Models/BuildPlateModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt +from PyQt6.QtCore import Qt from UM.Logger import Logger from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/CustomQualityProfilesDropDownMenuModel.py b/cura/Machines/Models/CustomQualityProfilesDropDownMenuModel.py index ce4b87da2b..54f0e44a2a 100644 --- a/cura/Machines/Models/CustomQualityProfilesDropDownMenuModel.py +++ b/cura/Machines/Models/CustomQualityProfilesDropDownMenuModel.py @@ -10,7 +10,7 @@ from cura.Machines.ContainerTree import ContainerTree from cura.Machines.Models.QualityProfilesDropDownMenuModel import QualityProfilesDropDownMenuModel if TYPE_CHECKING: - from PyQt5.QtCore import QObject + from PyQt6.QtCore import QObject from UM.Settings.Interfaces import ContainerInterface diff --git a/cura/Machines/Models/DiscoveredCloudPrintersModel.py b/cura/Machines/Models/DiscoveredCloudPrintersModel.py index 692ed49593..b9071c9053 100644 --- a/cura/Machines/Models/DiscoveredCloudPrintersModel.py +++ b/cura/Machines/Models/DiscoveredCloudPrintersModel.py @@ -1,6 +1,6 @@ from typing import Optional, TYPE_CHECKING, List, Dict -from PyQt5.QtCore import QObject, pyqtSlot, Qt, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QObject, pyqtSlot, Qt, pyqtSignal, pyqtProperty from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/DiscoveredPrintersModel.py b/cura/Machines/Models/DiscoveredPrintersModel.py index 459ec4d795..4c245a927a 100644 --- a/cura/Machines/Models/DiscoveredPrintersModel.py +++ b/cura/Machines/Models/DiscoveredPrintersModel.py @@ -3,7 +3,7 @@ from typing import Callable, Dict, List, Optional, TYPE_CHECKING -from PyQt5.QtCore import pyqtSlot, pyqtProperty, pyqtSignal, QObject, QTimer +from PyQt6.QtCore import pyqtSlot, pyqtProperty, pyqtSignal, QObject, QTimer from UM.i18n import i18nCatalog from UM.Logger import Logger diff --git a/cura/Machines/Models/ExtrudersModel.py b/cura/Machines/Models/ExtrudersModel.py index 5ae3c19874..4f86b139d1 100644 --- a/cura/Machines/Models/ExtrudersModel.py +++ b/cura/Machines/Models/ExtrudersModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt, pyqtSignal, pyqtProperty, QTimer +from PyQt6.QtCore import Qt, pyqtSignal, pyqtProperty, QTimer from typing import Iterable, TYPE_CHECKING from UM.i18n import i18nCatalog diff --git a/cura/Machines/Models/FirstStartMachineActionsModel.py b/cura/Machines/Models/FirstStartMachineActionsModel.py index 7d83f0bff2..2b14a74317 100644 --- a/cura/Machines/Models/FirstStartMachineActionsModel.py +++ b/cura/Machines/Models/FirstStartMachineActionsModel.py @@ -3,7 +3,7 @@ from typing import Optional, Dict, Any, TYPE_CHECKING -from PyQt5.QtCore import QObject, Qt, pyqtProperty, pyqtSignal, pyqtSlot +from PyQt6.QtCore import QObject, Qt, pyqtProperty, pyqtSignal, pyqtSlot from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/GlobalStacksModel.py b/cura/Machines/Models/GlobalStacksModel.py index f27a1ec00b..bd1aa50da1 100644 --- a/cura/Machines/Models/GlobalStacksModel.py +++ b/cura/Machines/Models/GlobalStacksModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2021 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt, QTimer, pyqtProperty, pyqtSignal +from PyQt6.QtCore import Qt, QTimer, pyqtProperty, pyqtSignal from typing import List, Optional from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/IntentCategoryModel.py b/cura/Machines/Models/IntentCategoryModel.py index aeb1f878ca..c2ae9a0426 100644 --- a/cura/Machines/Models/IntentCategoryModel.py +++ b/cura/Machines/Models/IntentCategoryModel.py @@ -2,14 +2,14 @@ #Cura is released under the terms of the LGPLv3 or higher. import collections -from PyQt5.QtCore import Qt, QTimer +from PyQt6.QtCore import Qt, QTimer from typing import TYPE_CHECKING, Optional, Dict from cura.Machines.Models.IntentModel import IntentModel from cura.Settings.IntentManager import IntentManager from UM.Qt.ListModel import ListModel from UM.Settings.ContainerRegistry import ContainerRegistry #To update the list if anything changes. -from PyQt5.QtCore import pyqtSignal +from PyQt6.QtCore import pyqtSignal import cura.CuraApplication if TYPE_CHECKING: from UM.Settings.ContainerRegistry import ContainerInterface diff --git a/cura/Machines/Models/IntentModel.py b/cura/Machines/Models/IntentModel.py index 0ec7e268f0..6d58cfe3ce 100644 --- a/cura/Machines/Models/IntentModel.py +++ b/cura/Machines/Models/IntentModel.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Optional, Dict, Any, Set, List -from PyQt5.QtCore import Qt, QObject, pyqtProperty, pyqtSignal, QTimer +from PyQt6.QtCore import Qt, QObject, pyqtProperty, pyqtSignal, QTimer import cura.CuraApplication from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/MaterialBrandsModel.py b/cura/Machines/Models/MaterialBrandsModel.py index b0594cb286..8da1dd653c 100644 --- a/cura/Machines/Models/MaterialBrandsModel.py +++ b/cura/Machines/Models/MaterialBrandsModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt, pyqtSignal +from PyQt6.QtCore import Qt, pyqtSignal from UM.Qt.ListModel import ListModel from cura.Machines.Models.BaseMaterialsModel import BaseMaterialsModel diff --git a/cura/Machines/Models/MaterialManagementModel.py b/cura/Machines/Models/MaterialManagementModel.py index 76b2c5b444..ab904573c2 100644 --- a/cura/Machines/Models/MaterialManagementModel.py +++ b/cura/Machines/Models/MaterialManagementModel.py @@ -2,8 +2,8 @@ # Cura is released under the terms of the LGPLv3 or higher. import copy # To duplicate materials. -from PyQt5.QtCore import pyqtSignal, pyqtSlot, QObject, QUrl -from PyQt5.QtGui import QDesktopServices +from PyQt6.QtCore import pyqtSignal, pyqtSlot, QObject, QUrl +from PyQt6.QtGui import QDesktopServices from typing import Any, Dict, Optional, TYPE_CHECKING import uuid # To generate new GUIDs for new materials. diff --git a/cura/Machines/Models/MultiBuildPlateModel.py b/cura/Machines/Models/MultiBuildPlateModel.py index 8e2f086e3b..300c35754b 100644 --- a/cura/Machines/Models/MultiBuildPlateModel.py +++ b/cura/Machines/Models/MultiBuildPlateModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QTimer, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QTimer, pyqtSignal, pyqtProperty from UM.Application import Application from UM.Scene.Camera import Camera diff --git a/cura/Machines/Models/NozzleModel.py b/cura/Machines/Models/NozzleModel.py index 5f7f8b02f5..4351f2568d 100644 --- a/cura/Machines/Models/NozzleModel.py +++ b/cura/Machines/Models/NozzleModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt +from PyQt6.QtCore import Qt from UM.Logger import Logger from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/QualityManagementModel.py b/cura/Machines/Models/QualityManagementModel.py index 63c1ead29d..666afad307 100644 --- a/cura/Machines/Models/QualityManagementModel.py +++ b/cura/Machines/Models/QualityManagementModel.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Any, cast, Dict, Optional, TYPE_CHECKING -from PyQt5.QtCore import pyqtSlot, QObject, Qt, QTimer +from PyQt6.QtCore import pyqtSlot, QObject, Qt, QTimer from UM.Logger import Logger from UM.Qt.ListModel import ListModel diff --git a/cura/Machines/Models/QualityProfilesDropDownMenuModel.py b/cura/Machines/Models/QualityProfilesDropDownMenuModel.py index f7316e9c09..6b74ac5175 100644 --- a/cura/Machines/Models/QualityProfilesDropDownMenuModel.py +++ b/cura/Machines/Models/QualityProfilesDropDownMenuModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt, QTimer +from PyQt6.QtCore import Qt, QTimer import cura.CuraApplication # Imported this way to prevent circular dependencies. from UM.Logger import Logger diff --git a/cura/Machines/Models/QualitySettingsModel.py b/cura/Machines/Models/QualitySettingsModel.py index 89a996fba1..dc1da7b309 100644 --- a/cura/Machines/Models/QualitySettingsModel.py +++ b/cura/Machines/Models/QualitySettingsModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2020 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtProperty, pyqtSignal, Qt +from PyQt6.QtCore import pyqtProperty, pyqtSignal, Qt from typing import Set import cura.CuraApplication diff --git a/cura/Machines/Models/SettingVisibilityPresetsModel.py b/cura/Machines/Models/SettingVisibilityPresetsModel.py index 2ca0960de4..d4c590dc74 100644 --- a/cura/Machines/Models/SettingVisibilityPresetsModel.py +++ b/cura/Machines/Models/SettingVisibilityPresetsModel.py @@ -3,7 +3,7 @@ from typing import Optional, List -from PyQt5.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject +from PyQt6.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject from UM.Logger import Logger from UM.Preferences import Preferences diff --git a/cura/Machines/Models/UserChangesModel.py b/cura/Machines/Models/UserChangesModel.py index 43bbe8a663..95b1e84cf7 100644 --- a/cura/Machines/Models/UserChangesModel.py +++ b/cura/Machines/Models/UserChangesModel.py @@ -4,7 +4,7 @@ import os from collections import OrderedDict -from PyQt5.QtCore import pyqtSlot, Qt +from PyQt6.QtCore import pyqtSlot, Qt from UM.Application import Application from UM.Logger import Logger diff --git a/cura/Machines/QualityChangesGroup.py b/cura/Machines/QualityChangesGroup.py index 668fff785a..f30d04b8a8 100644 --- a/cura/Machines/QualityChangesGroup.py +++ b/cura/Machines/QualityChangesGroup.py @@ -3,7 +3,7 @@ from typing import Any, Dict, Optional -from PyQt5.QtCore import QObject, pyqtProperty, pyqtSignal +from PyQt6.QtCore import QObject, pyqtProperty, pyqtSignal class QualityChangesGroup(QObject): diff --git a/cura/OAuth2/AuthorizationHelpers.py b/cura/OAuth2/AuthorizationHelpers.py index 77e3c66c11..a654ee4bdb 100644 --- a/cura/OAuth2/AuthorizationHelpers.py +++ b/cura/OAuth2/AuthorizationHelpers.py @@ -4,7 +4,7 @@ from base64 import b64encode from datetime import datetime from hashlib import sha512 -from PyQt5.QtNetwork import QNetworkReply +from PyQt6.QtNetwork import QNetworkReply import secrets from typing import Callable, Optional import urllib.parse diff --git a/cura/OAuth2/AuthorizationService.py b/cura/OAuth2/AuthorizationService.py index 0343af68a8..f2e6cd27ec 100644 --- a/cura/OAuth2/AuthorizationService.py +++ b/cura/OAuth2/AuthorizationService.py @@ -6,8 +6,8 @@ from datetime import datetime, timedelta from typing import Callable, Dict, Optional, TYPE_CHECKING, Union from urllib.parse import urlencode, quote_plus -from PyQt5.QtCore import QUrl -from PyQt5.QtGui import QDesktopServices +from PyQt6.QtCore import QUrl +from PyQt6.QtGui import QDesktopServices from UM.Logger import Logger from UM.Message import Message diff --git a/cura/PlatformPhysics.py b/cura/PlatformPhysics.py index 5fd2e70a1c..1cd5c1844c 100755 --- a/cura/PlatformPhysics.py +++ b/cura/PlatformPhysics.py @@ -1,7 +1,7 @@ # Copyright (c) 2020 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QTimer +from PyQt6.QtCore import QTimer from shapely.errors import TopologicalError # To capture errors if Shapely messes up. from UM.Application import Application diff --git a/cura/PrintJobPreviewImageProvider.py b/cura/PrintJobPreviewImageProvider.py index 321164adeb..528f42fb4d 100644 --- a/cura/PrintJobPreviewImageProvider.py +++ b/cura/PrintJobPreviewImageProvider.py @@ -1,6 +1,6 @@ -from PyQt5.QtGui import QImage -from PyQt5.QtQuick import QQuickImageProvider -from PyQt5.QtCore import QSize +from PyQt6.QtGui import QImage +from PyQt6.QtQuick import QQuickImageProvider +from PyQt6.QtCore import QSize from UM.Application import Application from typing import Tuple diff --git a/cura/PrinterOutput/FirmwareUpdater.py b/cura/PrinterOutput/FirmwareUpdater.py index cfcfb2204f..0c1c427ff2 100644 --- a/cura/PrinterOutput/FirmwareUpdater.py +++ b/cura/PrinterOutput/FirmwareUpdater.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QObject, QUrl, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QObject, QUrl, pyqtSignal, pyqtProperty from enum import IntEnum from threading import Thread diff --git a/cura/PrinterOutput/GenericOutputController.py b/cura/PrinterOutput/GenericOutputController.py index c160459776..9531a1ab89 100644 --- a/cura/PrinterOutput/GenericOutputController.py +++ b/cura/PrinterOutput/GenericOutputController.py @@ -3,7 +3,7 @@ from typing import TYPE_CHECKING, Set, Union, Optional -from PyQt5.QtCore import QTimer +from PyQt6.QtCore import QTimer from .PrinterOutputController import PrinterOutputController diff --git a/cura/PrinterOutput/Models/ExtruderConfigurationModel.py b/cura/PrinterOutput/Models/ExtruderConfigurationModel.py index 4fbf951f45..4cc3e81f56 100644 --- a/cura/PrinterOutput/Models/ExtruderConfigurationModel.py +++ b/cura/PrinterOutput/Models/ExtruderConfigurationModel.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Optional -from PyQt5.QtCore import pyqtProperty, QObject, pyqtSignal +from PyQt6.QtCore import pyqtProperty, QObject, pyqtSignal from .MaterialOutputModel import MaterialOutputModel diff --git a/cura/PrinterOutput/Models/ExtruderOutputModel.py b/cura/PrinterOutput/Models/ExtruderOutputModel.py index bcd0f579c2..ae1b175f3f 100644 --- a/cura/PrinterOutput/Models/ExtruderOutputModel.py +++ b/cura/PrinterOutput/Models/ExtruderOutputModel.py @@ -3,7 +3,7 @@ from typing import Optional, TYPE_CHECKING -from PyQt5.QtCore import pyqtSignal, pyqtProperty, QObject, pyqtSlot +from PyQt6.QtCore import pyqtSignal, pyqtProperty, QObject, pyqtSlot from .ExtruderConfigurationModel import ExtruderConfigurationModel diff --git a/cura/PrinterOutput/Models/MaterialOutputModel.py b/cura/PrinterOutput/Models/MaterialOutputModel.py index 3714824a89..89509ace72 100644 --- a/cura/PrinterOutput/Models/MaterialOutputModel.py +++ b/cura/PrinterOutput/Models/MaterialOutputModel.py @@ -3,7 +3,7 @@ from typing import Optional -from PyQt5.QtCore import pyqtProperty, QObject +from PyQt6.QtCore import pyqtProperty, QObject class MaterialOutputModel(QObject): diff --git a/cura/PrinterOutput/Models/PrintJobOutputModel.py b/cura/PrinterOutput/Models/PrintJobOutputModel.py index f7404f71ed..deb7947614 100644 --- a/cura/PrinterOutput/Models/PrintJobOutputModel.py +++ b/cura/PrinterOutput/Models/PrintJobOutputModel.py @@ -3,8 +3,8 @@ from typing import Optional, TYPE_CHECKING, List -from PyQt5.QtCore import pyqtSignal, pyqtProperty, QObject, pyqtSlot, QUrl -from PyQt5.QtGui import QImage +from PyQt6.QtCore import pyqtSignal, pyqtProperty, QObject, pyqtSlot, QUrl +from PyQt6.QtGui import QImage if TYPE_CHECKING: from cura.PrinterOutput.PrinterOutputController import PrinterOutputController diff --git a/cura/PrinterOutput/Models/PrinterConfigurationModel.py b/cura/PrinterOutput/Models/PrinterConfigurationModel.py index 54f52134b2..85c69abcd3 100644 --- a/cura/PrinterOutput/Models/PrinterConfigurationModel.py +++ b/cura/PrinterOutput/Models/PrinterConfigurationModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtProperty, QObject, pyqtSignal +from PyQt6.QtCore import pyqtProperty, QObject, pyqtSignal from typing import List MYPY = False diff --git a/cura/PrinterOutput/Models/PrinterOutputModel.py b/cura/PrinterOutput/Models/PrinterOutputModel.py index 37464b0b7d..2f7091e014 100644 --- a/cura/PrinterOutput/Models/PrinterOutputModel.py +++ b/cura/PrinterOutput/Models/PrinterOutputModel.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtSignal, pyqtProperty, QObject, QVariant, pyqtSlot, QUrl +from PyQt6.QtCore import pyqtSignal, pyqtProperty, QObject, QVariant, pyqtSlot, QUrl from typing import List, Dict, Optional, TYPE_CHECKING from UM.Math.Vector import Vector from cura.PrinterOutput.Peripheral import Peripheral diff --git a/cura/PrinterOutput/NetworkMJPGImage.py b/cura/PrinterOutput/NetworkMJPGImage.py index 0bfcfab764..a482b40ad8 100644 --- a/cura/PrinterOutput/NetworkMJPGImage.py +++ b/cura/PrinterOutput/NetworkMJPGImage.py @@ -1,10 +1,10 @@ # Copyright (c) 2018 Aldo Hoeben / fieldOfView # NetworkMJPGImage is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QUrl, pyqtProperty, pyqtSignal, pyqtSlot, QRect, QByteArray -from PyQt5.QtGui import QImage, QPainter -from PyQt5.QtQuick import QQuickPaintedItem -from PyQt5.QtNetwork import QNetworkRequest, QNetworkReply, QNetworkAccessManager +from PyQt6.QtCore import QUrl, pyqtProperty, pyqtSignal, pyqtSlot, QRect, QByteArray +from PyQt6.QtGui import QImage, QPainter +from PyQt6.QtQuick import QQuickPaintedItem +from PyQt6.QtNetwork import QNetworkRequest, QNetworkReply, QNetworkAccessManager from UM.Logger import Logger diff --git a/cura/PrinterOutput/NetworkedPrinterOutputDevice.py b/cura/PrinterOutput/NetworkedPrinterOutputDevice.py index 42c1cd78aa..3325a18d78 100644 --- a/cura/PrinterOutput/NetworkedPrinterOutputDevice.py +++ b/cura/PrinterOutput/NetworkedPrinterOutputDevice.py @@ -9,8 +9,8 @@ from cura.CuraApplication import CuraApplication from cura.PrinterOutput.PrinterOutputDevice import PrinterOutputDevice, ConnectionState, ConnectionType -from PyQt5.QtNetwork import QHttpMultiPart, QHttpPart, QNetworkRequest, QNetworkAccessManager, QNetworkReply, QAuthenticator -from PyQt5.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject, QUrl, QCoreApplication +from PyQt6.QtNetwork import QHttpMultiPart, QHttpPart, QNetworkRequest, QNetworkAccessManager, QNetworkReply, QAuthenticator +from PyQt6.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject, QUrl, QCoreApplication from time import time from typing import Callable, Dict, List, Optional, Union from enum import IntEnum diff --git a/cura/PrinterOutput/PrinterOutputDevice.py b/cura/PrinterOutput/PrinterOutputDevice.py index 2939076a9a..675921f0b1 100644 --- a/cura/PrinterOutput/PrinterOutputDevice.py +++ b/cura/PrinterOutput/PrinterOutputDevice.py @@ -4,8 +4,8 @@ from enum import IntEnum from typing import Callable, List, Optional, Union -from PyQt5.QtCore import pyqtProperty, pyqtSignal, QObject, QTimer, QUrl -from PyQt5.QtWidgets import QMessageBox +from PyQt6.QtCore import pyqtProperty, pyqtSignal, QObject, QTimer, QUrl +from PyQt6.QtWidgets import QMessageBox import cura.CuraApplication # Imported like this to prevent circular imports. from UM.Logger import Logger diff --git a/cura/PrinterOutput/UploadMaterialsJob.py b/cura/PrinterOutput/UploadMaterialsJob.py index 7a08a198c1..b6fbafeb24 100644 --- a/cura/PrinterOutput/UploadMaterialsJob.py +++ b/cura/PrinterOutput/UploadMaterialsJob.py @@ -5,7 +5,7 @@ import enum import functools # For partial methods to use as callbacks with information pre-filled. import json # To serialise metadata for API calls. import os # To delete the archive when we're done. -from PyQt5.QtCore import QUrl +from PyQt6.QtCore import QUrl import tempfile # To create an archive before we upload it. import cura.CuraApplication # Imported like this to prevent circular imports. @@ -21,7 +21,7 @@ from UM.TaskManagement.HttpRequestScope import JsonDecoratorScope from typing import Any, cast, Dict, List, Optional, TYPE_CHECKING if TYPE_CHECKING: - from PyQt5.QtNetwork import QNetworkReply + from PyQt6.QtNetwork import QNetworkReply from cura.UltimakerCloud.CloudMaterialSync import CloudMaterialSync catalog = i18nCatalog("cura") diff --git a/cura/Scene/ConvexHullDecorator.py b/cura/Scene/ConvexHullDecorator.py index 36697b7c57..bc4ba3ffd5 100644 --- a/cura/Scene/ConvexHullDecorator.py +++ b/cura/Scene/ConvexHullDecorator.py @@ -1,7 +1,7 @@ # Copyright (c) 2020 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QTimer +from PyQt6.QtCore import QTimer from UM.Application import Application from UM.Math.Polygon import Polygon diff --git a/cura/Scene/CuraSceneController.py b/cura/Scene/CuraSceneController.py index 99a6eee0e2..c3aa3d0a7e 100644 --- a/cura/Scene/CuraSceneController.py +++ b/cura/Scene/CuraSceneController.py @@ -1,7 +1,7 @@ from UM.Logger import Logger -from PyQt5.QtCore import Qt, pyqtSlot, QObject, QTimer -from PyQt5.QtWidgets import QApplication +from PyQt6.QtCore import Qt, pyqtSlot, QObject, QTimer +from PyQt6.QtWidgets import QApplication from UM.Scene.Camera import Camera from cura.UI.ObjectsModel import ObjectsModel diff --git a/cura/Settings/ContainerManager.py b/cura/Settings/ContainerManager.py index 518eaaa8fa..fbb857ef78 100644 --- a/cura/Settings/ContainerManager.py +++ b/cura/Settings/ContainerManager.py @@ -6,8 +6,8 @@ import urllib.parse import uuid from typing import Any, cast, Dict, List, TYPE_CHECKING, Union -from PyQt5.QtCore import QObject, QUrl -from PyQt5.QtWidgets import QMessageBox +from PyQt6.QtCore import QObject, QUrl +from PyQt6.QtWidgets import QMessageBox from UM.i18n import i18nCatalog from UM.FlameProfiler import pyqtSlot diff --git a/cura/Settings/CuraContainerRegistry.py b/cura/Settings/CuraContainerRegistry.py index 6130019f4d..6a0b8c0cd0 100644 --- a/cura/Settings/CuraContainerRegistry.py +++ b/cura/Settings/CuraContainerRegistry.py @@ -6,7 +6,7 @@ import re import configparser from typing import Any, cast, Dict, Optional, List, Union, Tuple -from PyQt5.QtWidgets import QMessageBox +from PyQt6.QtWidgets import QMessageBox from UM.Decorators import override from UM.Settings.ContainerFormatError import ContainerFormatError diff --git a/cura/Settings/CuraContainerStack.py b/cura/Settings/CuraContainerStack.py index f594ad3d0c..061d5c6161 100755 --- a/cura/Settings/CuraContainerStack.py +++ b/cura/Settings/CuraContainerStack.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Any, cast, List, Optional, Dict -from PyQt5.QtCore import pyqtProperty, pyqtSignal, QObject +from PyQt6.QtCore import pyqtProperty, pyqtSignal, QObject from UM.Application import Application from UM.Decorators import override diff --git a/cura/Settings/ExtruderManager.py b/cura/Settings/ExtruderManager.py index 81d3f733b4..dfe0ccbcfd 100755 --- a/cura/Settings/ExtruderManager.py +++ b/cura/Settings/ExtruderManager.py @@ -1,7 +1,7 @@ # Copyright (c) 2020 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtSignal, pyqtProperty, QObject, QVariant # For communicating data and events to Qt. +from PyQt6.QtCore import pyqtSignal, pyqtProperty, QObject, QVariant # For communicating data and events to Qt. from UM.FlameProfiler import pyqtSlot import cura.CuraApplication # To get the global container stack to find the current machine. diff --git a/cura/Settings/ExtruderStack.py b/cura/Settings/ExtruderStack.py index 2a9838c671..e93193818c 100644 --- a/cura/Settings/ExtruderStack.py +++ b/cura/Settings/ExtruderStack.py @@ -3,7 +3,7 @@ from typing import Any, Dict, TYPE_CHECKING, Optional -from PyQt5.QtCore import pyqtProperty, pyqtSignal +from PyQt6.QtCore import pyqtProperty, pyqtSignal from UM.Decorators import override from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase diff --git a/cura/Settings/GlobalStack.py b/cura/Settings/GlobalStack.py index 282034c0ee..84f77d0451 100755 --- a/cura/Settings/GlobalStack.py +++ b/cura/Settings/GlobalStack.py @@ -6,7 +6,7 @@ import threading from typing import Any, Dict, Optional, Set, TYPE_CHECKING, List import uuid -from PyQt5.QtCore import pyqtProperty, pyqtSlot, pyqtSignal +from PyQt6.QtCore import pyqtProperty, pyqtSlot, pyqtSignal from UM.Decorators import deprecated, override from UM.MimeTypeDatabase import MimeType, MimeTypeDatabase diff --git a/cura/Settings/IntentManager.py b/cura/Settings/IntentManager.py index a556a86dd8..2dfec02201 100644 --- a/cura/Settings/IntentManager.py +++ b/cura/Settings/IntentManager.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QObject, pyqtProperty, pyqtSignal, pyqtSlot +from PyQt6.QtCore import QObject, pyqtProperty, pyqtSignal, pyqtSlot from typing import Any, Dict, List, Set, Tuple, TYPE_CHECKING from UM.Logger import Logger diff --git a/cura/Settings/MachineManager.py b/cura/Settings/MachineManager.py index 648b1e9cae..1c7a8f0e98 100755 --- a/cura/Settings/MachineManager.py +++ b/cura/Settings/MachineManager.py @@ -6,7 +6,7 @@ import re import unicodedata from typing import Any, List, Dict, TYPE_CHECKING, Optional, cast, Set -from PyQt5.QtCore import QObject, pyqtProperty, pyqtSignal, QTimer +from PyQt6.QtCore import QObject, pyqtProperty, pyqtSignal, QTimer from UM.ConfigurationErrorMessage import ConfigurationErrorMessage from UM.Scene.Iterator.DepthFirstIterator import DepthFirstIterator diff --git a/cura/Settings/MachineNameValidator.py b/cura/Settings/MachineNameValidator.py index 99a5c7da0a..7fc1789f13 100644 --- a/cura/Settings/MachineNameValidator.py +++ b/cura/Settings/MachineNameValidator.py @@ -1,8 +1,8 @@ # Copyright (c) 2021 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtSlot, pyqtProperty, QObject, pyqtSignal, QRegExp -from PyQt5.QtGui import QValidator +from PyQt6.QtCore import pyqtSlot, pyqtProperty, QObject, pyqtSignal, QRegExp +from PyQt6.QtGui import QValidator import os #For statvfs. import urllib #To escape machine names for how they're saved to file. diff --git a/cura/Settings/SettingInheritanceManager.py b/cura/Settings/SettingInheritanceManager.py index 34dfaeb616..5ae00ae271 100644 --- a/cura/Settings/SettingInheritanceManager.py +++ b/cura/Settings/SettingInheritanceManager.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import List, Optional, TYPE_CHECKING -from PyQt5.QtCore import QObject, QTimer, pyqtProperty, pyqtSignal +from PyQt6.QtCore import QObject, QTimer, pyqtProperty, pyqtSignal from UM.FlameProfiler import pyqtSlot from UM.Application import Application from UM.Logger import Logger diff --git a/cura/Settings/SettingVisibilityPreset.py b/cura/Settings/SettingVisibilityPreset.py index e8a4211d69..f41f38faa3 100644 --- a/cura/Settings/SettingVisibilityPreset.py +++ b/cura/Settings/SettingVisibilityPreset.py @@ -3,7 +3,7 @@ import urllib.parse from configparser import ConfigParser from typing import List -from PyQt5.QtCore import pyqtProperty, QObject, pyqtSignal +from PyQt6.QtCore import pyqtProperty, QObject, pyqtSignal from UM.Logger import Logger from UM.MimeTypeDatabase import MimeTypeDatabase diff --git a/cura/Settings/SidebarCustomMenuItemsModel.py b/cura/Settings/SidebarCustomMenuItemsModel.py index 7177d26923..f136801fe5 100644 --- a/cura/Settings/SidebarCustomMenuItemsModel.py +++ b/cura/Settings/SidebarCustomMenuItemsModel.py @@ -4,7 +4,7 @@ from typing import Any from UM.Qt.ListModel import ListModel -from PyQt5.QtCore import pyqtSlot, Qt +from PyQt6.QtCore import pyqtSlot, Qt class SidebarCustomMenuItemsModel(ListModel): diff --git a/cura/Settings/SimpleModeSettingsManager.py b/cura/Settings/SimpleModeSettingsManager.py index 6650a9b333..af8707f235 100644 --- a/cura/Settings/SimpleModeSettingsManager.py +++ b/cura/Settings/SimpleModeSettingsManager.py @@ -1,7 +1,7 @@ # Copyright (c) 2017 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QObject, pyqtSignal, pyqtProperty +from PyQt6.QtCore import QObject, pyqtSignal, pyqtProperty from UM.Application import Application diff --git a/cura/SingleInstance.py b/cura/SingleInstance.py index 597a4d5f32..af98869ad7 100644 --- a/cura/SingleInstance.py +++ b/cura/SingleInstance.py @@ -5,7 +5,7 @@ import json import os from typing import List, Optional -from PyQt5.QtNetwork import QLocalServer, QLocalSocket +from PyQt6.QtNetwork import QLocalServer, QLocalSocket from UM.Qt.QtApplication import QtApplication #For typing. from UM.Logger import Logger diff --git a/cura/Snapshot.py b/cura/Snapshot.py index a7b813610f..97306fb371 100644 --- a/cura/Snapshot.py +++ b/cura/Snapshot.py @@ -2,9 +2,9 @@ # Cura is released under the terms of the LGPLv3 or higher. import numpy -from PyQt5 import QtCore -from PyQt5.QtCore import QCoreApplication -from PyQt5.QtGui import QImage +from PyQt6 import QtCore +from PyQt6.QtCore import QCoreApplication +from PyQt6.QtGui import QImage from cura.PreviewPass import PreviewPass diff --git a/cura/Stages/CuraStage.py b/cura/Stages/CuraStage.py index 6c4d46dd72..869ed309dc 100644 --- a/cura/Stages/CuraStage.py +++ b/cura/Stages/CuraStage.py @@ -1,7 +1,7 @@ # Copyright (c) 2018 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtProperty, QUrl +from PyQt6.QtCore import pyqtProperty, QUrl from UM.Stage import Stage diff --git a/cura/UI/CuraSplashScreen.py b/cura/UI/CuraSplashScreen.py index 4fa798247d..b505cec698 100644 --- a/cura/UI/CuraSplashScreen.py +++ b/cura/UI/CuraSplashScreen.py @@ -1,9 +1,9 @@ # Copyright (c) 2020 Ultimaker B.V. # Uranium is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import Qt, QCoreApplication, QTimer -from PyQt5.QtGui import QPixmap, QColor, QFont, QPen, QPainter -from PyQt5.QtWidgets import QSplashScreen +from PyQt6.QtCore import Qt, QCoreApplication, QTimer +from PyQt6.QtGui import QPixmap, QColor, QFont, QPen, QPainter +from PyQt6.QtWidgets import QSplashScreen from UM.Resources import Resources from UM.Application import Application diff --git a/cura/UI/MachineActionManager.py b/cura/UI/MachineActionManager.py index 5e31de32c2..7a4ce92de0 100644 --- a/cura/UI/MachineActionManager.py +++ b/cura/UI/MachineActionManager.py @@ -3,7 +3,7 @@ from typing import TYPE_CHECKING, Optional, List, Set, Dict -from PyQt5.QtCore import QObject +from PyQt6.QtCore import QObject from UM.FlameProfiler import pyqtSlot from UM.Logger import Logger diff --git a/cura/UI/MachineSettingsManager.py b/cura/UI/MachineSettingsManager.py index 1d2604c3c9..077dc29f6c 100644 --- a/cura/UI/MachineSettingsManager.py +++ b/cura/UI/MachineSettingsManager.py @@ -2,7 +2,7 @@ # Cura is released under the terms of the LGPLv3 or higher. from typing import Optional, TYPE_CHECKING -from PyQt5.QtCore import QObject, pyqtSlot +from PyQt6.QtCore import QObject, pyqtSlot from UM.i18n import i18nCatalog diff --git a/cura/UI/ObjectsModel.py b/cura/UI/ObjectsModel.py index 64a6e89054..cce2a56402 100644 --- a/cura/UI/ObjectsModel.py +++ b/cura/UI/ObjectsModel.py @@ -4,7 +4,7 @@ from UM.Logger import Logger import re from typing import Dict, List, Optional, Union -from PyQt5.QtCore import QTimer, Qt +from PyQt6.QtCore import QTimer, Qt from UM.Application import Application from UM.Qt.ListModel import ListModel diff --git a/cura/UI/PrintInformation.py b/cura/UI/PrintInformation.py index 2135c6fe81..a4c1410c0e 100644 --- a/cura/UI/PrintInformation.py +++ b/cura/UI/PrintInformation.py @@ -6,7 +6,7 @@ import math import os from typing import Dict, List, Optional, TYPE_CHECKING -from PyQt5.QtCore import QObject, pyqtSignal, pyqtProperty, pyqtSlot, QTimer +from PyQt6.QtCore import QObject, pyqtSignal, pyqtProperty, pyqtSlot, QTimer from UM.Logger import Logger from UM.Qt.Duration import Duration diff --git a/cura/UI/RecommendedMode.py b/cura/UI/RecommendedMode.py index 47b617740a..20680c0ca9 100644 --- a/cura/UI/RecommendedMode.py +++ b/cura/UI/RecommendedMode.py @@ -1,7 +1,7 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import QObject, pyqtSlot +from PyQt6.QtCore import QObject, pyqtSlot from cura import CuraApplication diff --git a/cura/UI/TextManager.py b/cura/UI/TextManager.py index 77dadae809..9fb68cc2fd 100644 --- a/cura/UI/TextManager.py +++ b/cura/UI/TextManager.py @@ -4,7 +4,7 @@ import collections
from typing import Optional, Dict, List, cast
-from PyQt5.QtCore import QObject, pyqtSlot
+from PyQt6.QtCore import QObject, pyqtSlot
from UM.i18n import i18nCatalog
from UM.Resources import Resources
diff --git a/cura/UI/WelcomePagesModel.py b/cura/UI/WelcomePagesModel.py index 890e34a31e..ccbefa2709 100644 --- a/cura/UI/WelcomePagesModel.py +++ b/cura/UI/WelcomePagesModel.py @@ -6,7 +6,7 @@ import os from collections import deque from typing import TYPE_CHECKING, Optional, List, Dict, Any -from PyQt5.QtCore import QUrl, Qt, pyqtSlot, pyqtProperty, pyqtSignal +from PyQt6.QtCore import QUrl, Qt, pyqtSlot, pyqtProperty, pyqtSignal from UM.i18n import i18nCatalog from UM.Logger import Logger @@ -14,7 +14,7 @@ from UM.Qt.ListModel import ListModel from UM.Resources import Resources if TYPE_CHECKING: - from PyQt5.QtCore import QObject + from PyQt6.QtCore import QObject from cura.CuraApplication import CuraApplication diff --git a/cura/UI/WhatsNewPagesModel.py b/cura/UI/WhatsNewPagesModel.py index b99bdf30f0..4fb7802924 100644 --- a/cura/UI/WhatsNewPagesModel.py +++ b/cura/UI/WhatsNewPagesModel.py @@ -4,7 +4,7 @@ import os from typing import Optional, Dict, List, Tuple, TYPE_CHECKING -from PyQt5.QtCore import pyqtProperty, pyqtSlot +from PyQt6.QtCore import pyqtProperty, pyqtSlot from UM.Logger import Logger from UM.Resources import Resources @@ -12,7 +12,7 @@ from UM.Resources import Resources from cura.UI.WelcomePagesModel import WelcomePagesModel if TYPE_CHECKING: - from PyQt5.QtCore import QObject + from PyQt6.QtCore import QObject from cura.CuraApplication import CuraApplication diff --git a/cura/UltimakerCloud/CloudMaterialSync.py b/cura/UltimakerCloud/CloudMaterialSync.py index 8bf8962eaf..9b3af4a1b3 100644 --- a/cura/UltimakerCloud/CloudMaterialSync.py +++ b/cura/UltimakerCloud/CloudMaterialSync.py @@ -1,8 +1,8 @@ # Copyright (c) 2021 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject, QUrl -from PyQt5.QtGui import QDesktopServices +from PyQt6.QtCore import pyqtProperty, pyqtSignal, pyqtSlot, QObject, QUrl +from PyQt6.QtGui import QDesktopServices from typing import Dict, Optional, TYPE_CHECKING import zipfile # To export all materials in a .zip archive. diff --git a/cura/UltimakerCloud/UltimakerCloudScope.py b/cura/UltimakerCloud/UltimakerCloudScope.py index bbcc8e2aa9..a173c5c758 100644 --- a/cura/UltimakerCloud/UltimakerCloudScope.py +++ b/cura/UltimakerCloud/UltimakerCloudScope.py @@ -1,7 +1,7 @@ # Copyright (c) 2021 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from PyQt5.QtNetwork import QNetworkRequest +from PyQt6.QtNetwork import QNetworkRequest from UM.Logger import Logger from UM.TaskManagement.HttpRequestScope import DefaultUserAgentScope diff --git a/cura/Utils/NetworkingUtil.py b/cura/Utils/NetworkingUtil.py index b13f7903b9..5e480b28a9 100644 --- a/cura/Utils/NetworkingUtil.py +++ b/cura/Utils/NetworkingUtil.py @@ -4,7 +4,7 @@ import socket from typing import Optional -from PyQt5.QtCore import QObject, pyqtSlot +from PyQt6.QtCore import QObject, pyqtSlot # |