77
88
99from PyQt6 import QtCore , QtGui , QtWidgets
10+ import app
1011
1112
1213class Ui_MainWindow (object ):
@@ -17,7 +18,7 @@ def setupUi(self, MainWindow):
1718 MainWindow .setMinimumSize (QtCore .QSize (920 , 600 ))
1819 MainWindow .setBaseSize (QtCore .QSize (920 , 623 ))
1920 icon = QtGui .QIcon ()
20- icon .addPixmap (QtGui .QPixmap ("ui\\ assets/ icon.png" ), QtGui .QIcon .Mode .Normal , QtGui .QIcon .State .Off )
21+ icon .addPixmap (QtGui .QPixmap (app . resource_path ( "ui\\ assets\\ icon.png" ) ), QtGui .QIcon .Mode .Normal , QtGui .QIcon .State .Off )
2122 MainWindow .setWindowIcon (icon )
2223 self .centralwidget = QtWidgets .QWidget (parent = MainWindow )
2324 self .centralwidget .setObjectName ("centralwidget" )
@@ -590,7 +591,7 @@ def setupUi(self, MainWindow):
590591 self .toolButtonRefreshTitle = QtWidgets .QToolButton (parent = self .tab2 )
591592 self .toolButtonRefreshTitle .setText ("" )
592593 icon1 = QtGui .QIcon ()
593- icon1 .addPixmap (QtGui .QPixmap ("ui\\ assets/ refresh.png" ), QtGui .QIcon .Mode .Normal , QtGui .QIcon .State .Off )
594+ icon1 .addPixmap (QtGui .QPixmap (app . resource_path ( "ui\\ assets\\ refresh.png" ) ), QtGui .QIcon .Mode .Normal , QtGui .QIcon .State .Off )
594595 self .toolButtonRefreshTitle .setIcon (icon1 )
595596 self .toolButtonRefreshTitle .setIconSize (QtCore .QSize (18 , 18 ))
596597 self .toolButtonRefreshTitle .setObjectName ("toolButtonRefreshTitle" )
0 commit comments