src/eric7/Graphics/PixmapDiagram.py

branch
eric7
changeset 9413
80c06d472826
parent 9221
bf71ee032bb4
child 9473
3f23dbf37dbe
--- a/src/eric7/Graphics/PixmapDiagram.py	Tue Oct 18 16:05:20 2022 +0200
+++ b/src/eric7/Graphics/PixmapDiagram.py	Tue Oct 18 16:06:21 2022 +0200
@@ -21,13 +21,14 @@
 from PyQt6.QtWidgets import QLabel, QSizePolicy, QScrollArea, QMenu, QToolBar
 from PyQt6.QtPrintSupport import QPrinter, QPrintDialog
 
-from EricWidgets import EricMessageBox
-from EricWidgets.EricMainWindow import EricMainWindow
-from EricWidgets.EricZoomWidget import EricZoomWidget
+from eric7.EricWidgets import EricMessageBox
+from eric7.EricWidgets.EricMainWindow import EricMainWindow
+from eric7.EricWidgets.EricZoomWidget import EricZoomWidget
 
-import UI.Config
+from eric7.EricGui import EricPixmapCache
+from eric7.UI import Config
 
-import Preferences
+from eric7 import Preferences
 
 
 class PixmapDiagram(EricMainWindow):
@@ -101,9 +102,9 @@
         self.setCentralWidget(self.pixmapView)
 
         self.__zoomWidget = EricZoomWidget(
-            UI.PixmapCache.getPixmap("zoomOut"),
-            UI.PixmapCache.getPixmap("zoomIn"),
-            UI.PixmapCache.getPixmap("zoomReset"),
+            EricPixmapCache.getPixmap("zoomOut"),
+            EricPixmapCache.getPixmap("zoomIn"),
+            EricPixmapCache.getPixmap("zoomReset"),
             self,
         )
         self.statusBar().addPermanentWidget(self.__zoomWidget)
@@ -128,14 +129,18 @@
         """
         Private method to initialize the view actions.
         """
-        self.closeAct = QAction(UI.PixmapCache.getIcon("close"), self.tr("Close"), self)
+        self.closeAct = QAction(
+            EricPixmapCache.getIcon("close"), self.tr("Close"), self
+        )
         self.closeAct.triggered.connect(self.close)
 
-        self.printAct = QAction(UI.PixmapCache.getIcon("print"), self.tr("Print"), self)
+        self.printAct = QAction(
+            EricPixmapCache.getIcon("print"), self.tr("Print"), self
+        )
         self.printAct.triggered.connect(self.__printDiagram)
 
         self.printPreviewAct = QAction(
-            UI.PixmapCache.getIcon("printPreview"), self.tr("Print Preview"), self
+            EricPixmapCache.getIcon("printPreview"), self.tr("Print Preview"), self
         )
         self.printPreviewAct.triggered.connect(self.__printPreviewDiagram)
 
@@ -166,11 +171,11 @@
         Private method to populate the toolbars with our actions.
         """
         self.windowToolBar = QToolBar(self.tr("Window"), self)
-        self.windowToolBar.setIconSize(UI.Config.ToolBarIconSize)
+        self.windowToolBar.setIconSize(Config.ToolBarIconSize)
         self.windowToolBar.addAction(self.closeAct)
 
         self.graphicsToolBar = QToolBar(self.tr("Graphics"), self)
-        self.graphicsToolBar.setIconSize(UI.Config.ToolBarIconSize)
+        self.graphicsToolBar.setIconSize(Config.ToolBarIconSize)
         self.graphicsToolBar.addAction(self.printPreviewAct)
         self.graphicsToolBar.addAction(self.printAct)
 

eric ide

mercurial