src/eric7/Graphics/UMLGraphicsView.py

branch
eric7
changeset 9413
80c06d472826
parent 9221
bf71ee032bb4
child 9473
3f23dbf37dbe
--- a/src/eric7/Graphics/UMLGraphicsView.py	Tue Oct 18 16:05:20 2022 +0200
+++ b/src/eric7/Graphics/UMLGraphicsView.py	Tue Oct 18 16:06:21 2022 +0200
@@ -14,17 +14,17 @@
 from PyQt6.QtWidgets import QGraphicsView, QToolBar, QDialog
 from PyQt6.QtPrintSupport import QPrinter, QPrintDialog
 
-from EricGraphics.EricGraphicsView import EricGraphicsView
+from eric7.EricGraphics.EricGraphicsView import EricGraphicsView
 
-from EricWidgets import EricMessageBox, EricFileDialog
-from EricWidgets.EricZoomWidget import EricZoomWidget
+from eric7.EricWidgets import EricMessageBox, EricFileDialog
+from eric7.EricWidgets.EricZoomWidget import EricZoomWidget
 
 from .UMLItem import UMLItem
 
-import UI.Config
-import UI.PixmapCache
+from eric7.EricGui import EricPixmapCache
+from eric7.UI import Config
 
-import Preferences
+from eric7 import Preferences
 
 
 class UMLGraphicsView(EricGraphicsView):
@@ -57,9 +57,9 @@
         self.deltaSize = 100.0
 
         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,
         )
         parent.statusBar().addPermanentWidget(self.__zoomWidget)
@@ -87,61 +87,61 @@
             self.alignMapper.mapped[int].connect(self.__alignShapes)
 
         self.deleteShapeAct = QAction(
-            UI.PixmapCache.getIcon("deleteShape"), self.tr("Delete shapes"), self
+            EricPixmapCache.getIcon("deleteShape"), self.tr("Delete shapes"), self
         )
         self.deleteShapeAct.triggered.connect(self.__deleteShape)
 
         self.incWidthAct = QAction(
-            UI.PixmapCache.getIcon("sceneWidthInc"),
+            EricPixmapCache.getIcon("sceneWidthInc"),
             self.tr("Increase width by {0} points").format(self.deltaSize),
             self,
         )
         self.incWidthAct.triggered.connect(self.__incWidth)
 
         self.incHeightAct = QAction(
-            UI.PixmapCache.getIcon("sceneHeightInc"),
+            EricPixmapCache.getIcon("sceneHeightInc"),
             self.tr("Increase height by {0} points").format(self.deltaSize),
             self,
         )
         self.incHeightAct.triggered.connect(self.__incHeight)
 
         self.decWidthAct = QAction(
-            UI.PixmapCache.getIcon("sceneWidthDec"),
+            EricPixmapCache.getIcon("sceneWidthDec"),
             self.tr("Decrease width by {0} points").format(self.deltaSize),
             self,
         )
         self.decWidthAct.triggered.connect(self.__decWidth)
 
         self.decHeightAct = QAction(
-            UI.PixmapCache.getIcon("sceneHeightDec"),
+            EricPixmapCache.getIcon("sceneHeightDec"),
             self.tr("Decrease height by {0} points").format(self.deltaSize),
             self,
         )
         self.decHeightAct.triggered.connect(self.__decHeight)
 
         self.setSizeAct = QAction(
-            UI.PixmapCache.getIcon("sceneSize"), self.tr("Set size"), self
+            EricPixmapCache.getIcon("sceneSize"), self.tr("Set size"), self
         )
         self.setSizeAct.triggered.connect(self.__setSize)
 
         self.rescanAct = QAction(
-            UI.PixmapCache.getIcon("rescan"), self.tr("Re-Scan"), self
+            EricPixmapCache.getIcon("rescan"), self.tr("Re-Scan"), self
         )
         self.rescanAct.triggered.connect(self.__rescan)
 
         self.relayoutAct = QAction(
-            UI.PixmapCache.getIcon("relayout"), self.tr("Re-Layout"), self
+            EricPixmapCache.getIcon("relayout"), self.tr("Re-Layout"), self
         )
         self.relayoutAct.triggered.connect(self.__relayout)
 
         self.alignLeftAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignLeft"), self.tr("Align Left"), self
+            EricPixmapCache.getIcon("shapesAlignLeft"), self.tr("Align Left"), self
         )
         self.alignMapper.setMapping(self.alignLeftAct, Qt.AlignmentFlag.AlignLeft)
         self.alignLeftAct.triggered.connect(self.alignMapper.map)
 
         self.alignHCenterAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignHCenter"),
+            EricPixmapCache.getIcon("shapesAlignHCenter"),
             self.tr("Align Center Horizontal"),
             self,
         )
@@ -149,19 +149,19 @@
         self.alignHCenterAct.triggered.connect(self.alignMapper.map)
 
         self.alignRightAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignRight"), self.tr("Align Right"), self
+            EricPixmapCache.getIcon("shapesAlignRight"), self.tr("Align Right"), self
         )
         self.alignMapper.setMapping(self.alignRightAct, Qt.AlignmentFlag.AlignRight)
         self.alignRightAct.triggered.connect(self.alignMapper.map)
 
         self.alignTopAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignTop"), self.tr("Align Top"), self
+            EricPixmapCache.getIcon("shapesAlignTop"), self.tr("Align Top"), self
         )
         self.alignMapper.setMapping(self.alignTopAct, Qt.AlignmentFlag.AlignTop)
         self.alignTopAct.triggered.connect(self.alignMapper.map)
 
         self.alignVCenterAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignVCenter"),
+            EricPixmapCache.getIcon("shapesAlignVCenter"),
             self.tr("Align Center Vertical"),
             self,
         )
@@ -169,7 +169,7 @@
         self.alignVCenterAct.triggered.connect(self.alignMapper.map)
 
         self.alignBottomAct = QAction(
-            UI.PixmapCache.getIcon("shapesAlignBottom"), self.tr("Align Bottom"), self
+            EricPixmapCache.getIcon("shapesAlignBottom"), self.tr("Align Bottom"), self
         )
         self.alignMapper.setMapping(self.alignBottomAct, Qt.AlignmentFlag.AlignBottom)
         self.alignBottomAct.triggered.connect(self.alignMapper.map)
@@ -233,7 +233,7 @@
         @rtype QToolBar
         """
         toolBar = QToolBar(self.tr("Graphics"), self)
-        toolBar.setIconSize(UI.Config.ToolBarIconSize)
+        toolBar.setIconSize(Config.ToolBarIconSize)
         toolBar.addAction(self.deleteShapeAct)
         toolBar.addSeparator()
         toolBar.addAction(self.alignLeftAct)

eric ide

mercurial