class Ui_SettingsWindow(object): def setupUi(self, SettingsWindow): SettingsWindow.setObjectName("SettingsWindow") SettingsWindow.setWindowModality(QtCore.Qt.NonModal) SettingsWindow.resize(800, 480) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( SettingsWindow.sizePolicy().hasHeightForWidth()) SettingsWindow.setSizePolicy(sizePolicy) SettingsWindow.setMaximumSize(QtCore.QSize(855, 661)) font = QtGui.QFont() font.setPointSize(15) SettingsWindow.setFont(font) SettingsWindow.setContextMenuPolicy(QtCore.Qt.PreventContextMenu) SettingsWindow.setProperty("dockNestingEnabled", False) SettingsWindow.setProperty("unifiedTitleAndToolBarOnMac", False) self.verticalLayout_3 = QtWidgets.QVBoxLayout(SettingsWindow) self.verticalLayout_3.setContentsMargins(0, 0, 0, 0) self.verticalLayout_3.setSpacing(0) self.verticalLayout_3.setObjectName("verticalLayout_3") self.gridLayout_5 = QtWidgets.QGridLayout() self.gridLayout_5.setContentsMargins(0, -1, 0, 0) self.gridLayout_5.setObjectName("gridLayout_5") self.horizontalLayout_2 = QtWidgets.QHBoxLayout() self.horizontalLayout_2.setContentsMargins(5, -1, 5, -1) self.horizontalLayout_2.setObjectName("horizontalLayout_2") self.backBtn = TouchButton(SettingsWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.backBtn.sizePolicy().hasHeightForWidth()) self.backBtn.setSizePolicy(sizePolicy) self.backBtn.setMinimumSize(QtCore.QSize(64, 64)) self.backBtn.setMaximumSize(QtCore.QSize(64, 64)) self.backBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.backBtn.setText("") icon = QtGui.QIcon() icon.addPixmap( QtGui.QPixmap(":/Icons/Icons/BlueBackIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.backBtn.setIcon(icon) self.backBtn.setIconSize(QtCore.QSize(64, 64)) self.backBtn.setObjectName("backBtn") self.horizontalLayout_2.addWidget(self.backBtn) spacerItem = QtWidgets.QSpacerItem(214, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_2.addItem(spacerItem) self.gridLayout_5.addLayout(self.horizontalLayout_2, 0, 0, 1, 1) self.homeBtn = TouchButton(SettingsWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.homeBtn.sizePolicy().hasHeightForWidth()) self.homeBtn.setSizePolicy(sizePolicy) self.homeBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.homeBtn.setText("") icon1 = QtGui.QIcon() icon1.addPixmap( QtGui.QPixmap(":/Icons/Icons/SSLogo_No_Background.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.homeBtn.setIcon(icon1) self.homeBtn.setIconSize(QtCore.QSize(256, 64)) self.homeBtn.setCheckable(False) self.homeBtn.setChecked(False) self.homeBtn.setObjectName("homeBtn") self.gridLayout_5.addWidget(self.homeBtn, 0, 1, 1, 1) spacerItem1 = QtWidgets.QSpacerItem(260, 63, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_5.addItem(spacerItem1, 0, 2, 1, 1) self.gridLayout_5.setColumnStretch(0, 1) self.gridLayout_5.setColumnStretch(1, 1) self.gridLayout_5.setColumnStretch(2, 1) self.verticalLayout_3.addLayout(self.gridLayout_5) self.settingsStack = QtWidgets.QStackedWidget(SettingsWindow) self.settingsStack.setObjectName("settingsStack") self.mainPage = QtWidgets.QWidget() self.mainPage.setObjectName("mainPage") self.gridLayout_2 = QtWidgets.QGridLayout(self.mainPage) self.gridLayout_2.setContentsMargins(0, 0, 0, 0) self.gridLayout_2.setObjectName("gridLayout_2") self.settingsView = QtWidgets.QListWidget(self.mainPage) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(25) self.settingsView.setFont(font) self.settingsView.setStyleSheet("QTableView::item {\n" " border: 0px;\n" " padding-left: 5px;\n" " padding-right: 5px;\n" "}") self.settingsView.setFrameShape(QtWidgets.QFrame.StyledPanel) self.settingsView.setFrameShadow(QtWidgets.QFrame.Sunken) self.settingsView.setLineWidth(3) self.settingsView.setVerticalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOn) self.settingsView.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.settingsView.setEditTriggers( QtWidgets.QAbstractItemView.NoEditTriggers) self.settingsView.setProperty("showDropIndicator", False) self.settingsView.setAlternatingRowColors(True) self.settingsView.setSelectionMode( QtWidgets.QAbstractItemView.SingleSelection) self.settingsView.setSelectionBehavior( QtWidgets.QAbstractItemView.SelectItems) self.settingsView.setIconSize(QtCore.QSize(64, 64)) self.settingsView.setVerticalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.settingsView.setHorizontalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.settingsView.setMovement(QtWidgets.QListView.Static) self.settingsView.setLayoutMode(QtWidgets.QListView.SinglePass) self.settingsView.setViewMode(QtWidgets.QListView.ListMode) self.settingsView.setModelColumn(0) self.settingsView.setUniformItemSizes(False) self.settingsView.setSelectionRectVisible(False) self.settingsView.setObjectName("settingsView") item = QtWidgets.QListWidgetItem() item.setTextAlignment(QtCore.Qt.AlignLeading | QtCore.Qt.AlignVCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(35) item.setFont(font) icon2 = QtGui.QIcon() icon2.addPixmap( QtGui.QPixmap(":/Icons/Icons/BlueSettingsIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) item.setIcon(icon2) self.settingsView.addItem(item) item = QtWidgets.QListWidgetItem() font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(35) item.setFont(font) icon3 = QtGui.QIcon() icon3.addPixmap(QtGui.QPixmap(":/Icons/Icons/Algorithm_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) item.setIcon(icon3) self.settingsView.addItem(item) self.gridLayout_2.addWidget(self.settingsView, 0, 0, 1, 1) self.settingsStack.addWidget(self.mainPage) self.systemPage = QtWidgets.QWidget() self.systemPage.setStyleSheet("") self.systemPage.setObjectName("systemPage") self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.systemPage) self.verticalLayout_2.setContentsMargins(0, 0, 0, 0) self.verticalLayout_2.setObjectName("verticalLayout_2") self.scrollArea = QtWidgets.QScrollArea(self.systemPage) self.scrollArea.setStyleSheet("QWidget\n" "{\n" " background-color: #232629;\n" "}") self.scrollArea.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOn) self.scrollArea.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.scrollArea.setWidgetResizable(True) self.scrollArea.setObjectName("scrollArea") self.scrollAreaWidgetContents = QtWidgets.QWidget() self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, 0, 777, 408)) self.scrollAreaWidgetContents.setStyleSheet("") self.scrollAreaWidgetContents.setObjectName("scrollAreaWidgetContents") self.verticalLayout_4 = QtWidgets.QVBoxLayout( self.scrollAreaWidgetContents) self.verticalLayout_4.setContentsMargins(0, 0, 0, 0) self.verticalLayout_4.setSpacing(2) self.verticalLayout_4.setObjectName("verticalLayout_4") self.gridLayout_3 = QtWidgets.QGridLayout() self.gridLayout_3.setHorizontalSpacing(14) self.gridLayout_3.setObjectName("gridLayout_3") self.label_2 = QtWidgets.QLabel(self.scrollAreaWidgetContents) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(25) self.label_2.setFont(font) self.label_2.setObjectName("label_2") self.gridLayout_3.addWidget(self.label_2, 0, 0, 1, 1) self.swapScannersBtn = TouchButton(self.scrollAreaWidgetContents) self.swapScannersBtn.setMinimumSize(QtCore.QSize(64, 64)) self.swapScannersBtn.setMaximumSize(QtCore.QSize(64, 64)) self.swapScannersBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.swapScannersBtn.setText("") icon4 = QtGui.QIcon() icon4.addPixmap(QtGui.QPixmap(":/Icons/Icons/Swap_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.swapScannersBtn.setIcon(icon4) self.swapScannersBtn.setIconSize(QtCore.QSize(64, 64)) self.swapScannersBtn.setObjectName("swapScannersBtn") self.gridLayout_3.addWidget(self.swapScannersBtn, 0, 3, 2, 1) self.secondaryLabel = QtWidgets.QLabel(self.scrollAreaWidgetContents) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.secondaryLabel.setFont(font) self.secondaryLabel.setObjectName("secondaryLabel") self.gridLayout_3.addWidget(self.secondaryLabel, 1, 1, 1, 1) spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_3.addItem(spacerItem2, 0, 2, 1, 1) self.primaryLabel = QtWidgets.QLabel(self.scrollAreaWidgetContents) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.primaryLabel.setFont(font) self.primaryLabel.setObjectName("primaryLabel") self.gridLayout_3.addWidget(self.primaryLabel, 0, 1, 1, 1) self.label_3 = QtWidgets.QLabel(self.scrollAreaWidgetContents) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(25) self.label_3.setFont(font) self.label_3.setObjectName("label_3") self.gridLayout_3.addWidget(self.label_3, 1, 0, 1, 1) self.verticalLayout_4.addLayout(self.gridLayout_3) self.line = QtWidgets.QFrame(self.scrollAreaWidgetContents) self.line.setFrameShape(QtWidgets.QFrame.HLine) self.line.setFrameShadow(QtWidgets.QFrame.Sunken) self.line.setObjectName("line") self.verticalLayout_4.addWidget(self.line) spacerItem3 = QtWidgets.QSpacerItem(20, 253, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem3) self.scrollArea.setWidget(self.scrollAreaWidgetContents) self.verticalLayout_2.addWidget(self.scrollArea) self.settingsStack.addWidget(self.systemPage) self.page = QtWidgets.QWidget() self.page.setObjectName("page") self.verticalLayout_5 = QtWidgets.QVBoxLayout(self.page) self.verticalLayout_5.setContentsMargins(0, 0, 0, 0) self.verticalLayout_5.setObjectName("verticalLayout_5") self.scrollArea_2 = QtWidgets.QScrollArea(self.page) self.scrollArea_2.setStyleSheet("QWidget\n" "{\n" " background-color: #232629;\n" "}") self.scrollArea_2.setVerticalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOn) self.scrollArea_2.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.scrollArea_2.setWidgetResizable(True) self.scrollArea_2.setObjectName("scrollArea_2") self.scrollAreaWidgetContents_2 = QtWidgets.QWidget() self.scrollAreaWidgetContents_2.setGeometry( QtCore.QRect(0, 0, 777, 408)) self.scrollAreaWidgetContents_2.setObjectName( "scrollAreaWidgetContents_2") self.verticalLayout_6 = QtWidgets.QVBoxLayout( self.scrollAreaWidgetContents_2) self.verticalLayout_6.setContentsMargins(0, 0, 0, 0) self.verticalLayout_6.setObjectName("verticalLayout_6") self.gridLayout = QtWidgets.QGridLayout() self.gridLayout.setContentsMargins(-1, 0, -1, -1) self.gridLayout.setObjectName("gridLayout") self.expDateSpinBox = TouchSpinBox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.expDateSpinBox.setFont(font) self.expDateSpinBox.setMinimum(1) self.expDateSpinBox.setMaximum(25) self.expDateSpinBox.setObjectName("expDateSpinBox") self.gridLayout.addWidget(self.expDateSpinBox, 2, 3, 1, 1) self.label_6 = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label_6.setFont(font) self.label_6.setObjectName("label_6") self.gridLayout.addWidget(self.label_6, 1, 2, 1, 1) self.shelfTimeCheckBox = TouchCheckbox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.shelfTimeCheckBox.setFont(font) self.shelfTimeCheckBox.setObjectName("shelfTimeCheckBox") self.gridLayout.addWidget(self.shelfTimeCheckBox, 0, 0, 1, 1) self.label_7 = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label_7.setFont(font) self.label_7.setObjectName("label_7") self.gridLayout.addWidget(self.label_7, 2, 2, 1, 1) self.expDateCheckBox = TouchCheckbox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.expDateCheckBox.setFont(font) self.expDateCheckBox.setObjectName("expDateCheckBox") self.gridLayout.addWidget(self.expDateCheckBox, 2, 0, 1, 1) self.usageRateCheckBox = TouchCheckbox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.usageRateCheckBox.setFont(font) self.usageRateCheckBox.setObjectName("usageRateCheckBox") self.gridLayout.addWidget(self.usageRateCheckBox, 1, 0, 1, 1) self.label = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label.setFont(font) self.label.setObjectName("label") self.gridLayout.addWidget(self.label, 0, 2, 1, 1) self.usageRateSpinBox = TouchSpinBox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.usageRateSpinBox.setFont(font) self.usageRateSpinBox.setMinimum(1) self.usageRateSpinBox.setMaximum(25) self.usageRateSpinBox.setObjectName("usageRateSpinBox") self.gridLayout.addWidget(self.usageRateSpinBox, 1, 3, 1, 1) self.shelfTimeSpinBox = TouchSpinBox(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.shelfTimeSpinBox.setFont(font) self.shelfTimeSpinBox.setMinimum(1) self.shelfTimeSpinBox.setMaximum(25) self.shelfTimeSpinBox.setProperty("value", 1) self.shelfTimeSpinBox.setObjectName("shelfTimeSpinBox") self.gridLayout.addWidget(self.shelfTimeSpinBox, 0, 3, 1, 1) self.label_8 = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label_8.setFont(font) self.label_8.setObjectName("label_8") self.gridLayout.addWidget(self.label_8, 0, 4, 1, 1) self.label_10 = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label_10.setFont(font) self.label_10.setObjectName("label_10") self.gridLayout.addWidget(self.label_10, 2, 4, 1, 1) self.label_9 = QtWidgets.QLabel(self.scrollAreaWidgetContents_2) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(20) self.label_9.setFont(font) self.label_9.setObjectName("label_9") self.gridLayout.addWidget(self.label_9, 1, 4, 1, 1) spacerItem4 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout.addItem(spacerItem4, 0, 1, 1, 1) spacerItem5 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout.addItem(spacerItem5, 1, 1, 1, 1) spacerItem6 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout.addItem(spacerItem6, 2, 1, 1, 1) self.verticalLayout_6.addLayout(self.gridLayout) self.line_2 = QtWidgets.QFrame(self.scrollAreaWidgetContents_2) self.line_2.setFrameShape(QtWidgets.QFrame.HLine) self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken) self.line_2.setObjectName("line_2") self.verticalLayout_6.addWidget(self.line_2) spacerItem7 = QtWidgets.QSpacerItem(20, 203, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_6.addItem(spacerItem7) self.scrollArea_2.setWidget(self.scrollAreaWidgetContents_2) self.verticalLayout_5.addWidget(self.scrollArea_2) self.settingsStack.addWidget(self.page) self.page_2 = QtWidgets.QWidget() self.page_2.setObjectName("page_2") self.settingsStack.addWidget(self.page_2) self.verticalLayout_3.addWidget(self.settingsStack) self.horizontalLayout_3 = QtWidgets.QHBoxLayout() self.horizontalLayout_3.setObjectName("horizontalLayout_3") self.verticalLayout_3.addLayout(self.horizontalLayout_3) self.retranslateUi(SettingsWindow) self.settingsStack.setCurrentIndex(2) self.settingsView.setCurrentRow(-1) QtCore.QMetaObject.connectSlotsByName(SettingsWindow) def retranslateUi(self, SettingsWindow): _translate = QtCore.QCoreApplication.translate SettingsWindow.setWindowTitle( _translate("SettingsWindow", "Smart Shop")) __sortingEnabled = self.settingsView.isSortingEnabled() self.settingsView.setSortingEnabled(False) item = self.settingsView.item(0) item.setText(_translate("SettingsWindow", "System")) item = self.settingsView.item(1) item.setText(_translate("SettingsWindow", "Algorithm")) self.settingsView.setSortingEnabled(__sortingEnabled) self.label_2.setText(_translate("SettingsWindow", "Primary:")) self.secondaryLabel.setText(_translate("SettingsWindow", "5")) self.primaryLabel.setText(_translate("SettingsWindow", "4")) self.label_3.setText(_translate("SettingsWindow", "Secondary:")) self.label_6.setText(_translate("SettingsWindow", "Threshold:")) self.shelfTimeCheckBox.setText( _translate("SettingsWindow", "Shelf Time Algorithm")) self.label_7.setText(_translate("SettingsWindow", "Threshold:")) self.expDateCheckBox.setText( _translate("SettingsWindow", "Expiration Date Algorithm")) self.usageRateCheckBox.setText( _translate("SettingsWindow", "Usage Rate Algorithm")) self.label.setText(_translate("SettingsWindow", "Threshold:")) self.label_8.setText(_translate("SettingsWindow", "days")) self.label_10.setText(_translate("SettingsWindow", "days")) self.label_9.setText(_translate("SettingsWindow", "days"))
class Ui_PurchaseHistoryWindow(object): def setupUi(self, PurchaseHistoryWindow): PurchaseHistoryWindow.setObjectName("PurchaseHistoryWindow") PurchaseHistoryWindow.setWindowModality(QtCore.Qt.NonModal) PurchaseHistoryWindow.resize(800, 480) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( PurchaseHistoryWindow.sizePolicy().hasHeightForWidth()) PurchaseHistoryWindow.setSizePolicy(sizePolicy) PurchaseHistoryWindow.setMaximumSize(QtCore.QSize(855, 661)) font = QtGui.QFont() font.setPointSize(15) PurchaseHistoryWindow.setFont(font) PurchaseHistoryWindow.setContextMenuPolicy( QtCore.Qt.PreventContextMenu) PurchaseHistoryWindow.setProperty("dockNestingEnabled", False) PurchaseHistoryWindow.setProperty("unifiedTitleAndToolBarOnMac", False) self.gridLayout = QtWidgets.QGridLayout(PurchaseHistoryWindow) self.gridLayout.setContentsMargins(0, 0, 0, 0) self.gridLayout.setSpacing(0) self.gridLayout.setObjectName("gridLayout") self.gridLayout_5 = QtWidgets.QGridLayout() self.gridLayout_5.setContentsMargins(0, -1, 0, 0) self.gridLayout_5.setObjectName("gridLayout_5") self.horizontalLayout_2 = QtWidgets.QHBoxLayout() self.horizontalLayout_2.setContentsMargins(5, -1, 5, -1) self.horizontalLayout_2.setObjectName("horizontalLayout_2") self.backBtn = TouchButton(PurchaseHistoryWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.backBtn.sizePolicy().hasHeightForWidth()) self.backBtn.setSizePolicy(sizePolicy) self.backBtn.setMinimumSize(QtCore.QSize(64, 64)) self.backBtn.setMaximumSize(QtCore.QSize(64, 64)) self.backBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.backBtn.setText("") icon = QtGui.QIcon() icon.addPixmap( QtGui.QPixmap(":/Icons/Icons/BlueBackIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.backBtn.setIcon(icon) self.backBtn.setIconSize(QtCore.QSize(64, 64)) self.backBtn.setObjectName("backBtn") self.horizontalLayout_2.addWidget(self.backBtn) spacerItem = QtWidgets.QSpacerItem(214, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_2.addItem(spacerItem) self.gridLayout_5.addLayout(self.horizontalLayout_2, 0, 0, 1, 1) self.homeBtn = TouchButton(PurchaseHistoryWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.homeBtn.sizePolicy().hasHeightForWidth()) self.homeBtn.setSizePolicy(sizePolicy) self.homeBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.homeBtn.setText("") icon1 = QtGui.QIcon() icon1.addPixmap( QtGui.QPixmap(":/Icons/Icons/SSLogo_No_Background.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.homeBtn.setIcon(icon1) self.homeBtn.setIconSize(QtCore.QSize(256, 64)) self.homeBtn.setCheckable(False) self.homeBtn.setChecked(False) self.homeBtn.setObjectName("homeBtn") self.gridLayout_5.addWidget(self.homeBtn, 0, 1, 1, 1) spacerItem1 = QtWidgets.QSpacerItem(260, 63, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_5.addItem(spacerItem1, 0, 2, 1, 1) self.gridLayout_5.setColumnStretch(0, 1) self.gridLayout_5.setColumnStretch(1, 1) self.gridLayout_5.setColumnStretch(2, 1) self.gridLayout.addLayout(self.gridLayout_5, 2, 0, 1, 2) self.horizontalLayout_3 = QtWidgets.QHBoxLayout() self.horizontalLayout_3.setObjectName("horizontalLayout_3") self.gridLayout.addLayout(self.horizontalLayout_3, 4, 1, 1, 1) self.historyView = QtWidgets.QTableView(PurchaseHistoryWindow) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(21) self.historyView.setFont(font) self.historyView.setStyleSheet("QTableView::item {\n" " border: 0px;\n" " padding-left: 5px;\n" " padding-right: 5px;\n" "}") self.historyView.setFrameShape(QtWidgets.QFrame.StyledPanel) self.historyView.setFrameShadow(QtWidgets.QFrame.Sunken) self.historyView.setLineWidth(3) self.historyView.setVerticalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOn) self.historyView.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.historyView.setEditTriggers( QtWidgets.QAbstractItemView.NoEditTriggers) self.historyView.setProperty("showDropIndicator", False) self.historyView.setAlternatingRowColors(True) self.historyView.setSelectionMode( QtWidgets.QAbstractItemView.NoSelection) self.historyView.setSelectionBehavior( QtWidgets.QAbstractItemView.SelectRows) self.historyView.setVerticalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.historyView.setHorizontalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.historyView.setSortingEnabled(True) self.historyView.setWordWrap(False) self.historyView.setObjectName("historyView") self.historyView.verticalHeader().setVisible(False) self.historyView.verticalHeader().setDefaultSectionSize(45) self.gridLayout.addWidget(self.historyView, 3, 0, 1, 2) self.gridLayout.setColumnStretch(0, 1) self.retranslateUi(PurchaseHistoryWindow) QtCore.QMetaObject.connectSlotsByName(PurchaseHistoryWindow) def retranslateUi(self, PurchaseHistoryWindow): _translate = QtCore.QCoreApplication.translate PurchaseHistoryWindow.setWindowTitle( _translate("PurchaseHistoryWindow", "Smart Shop"))
class Ui_MainWindow(object): def setupUi(self, MainWindow): MainWindow.setObjectName("MainWindow") MainWindow.setWindowModality(QtCore.Qt.NonModal) MainWindow.resize(800, 480) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(MainWindow.sizePolicy().hasHeightForWidth()) MainWindow.setSizePolicy(sizePolicy) font = QtGui.QFont() font.setFamily("Cronus Round") font.setPointSize(19) font.setBold(True) font.setWeight(75) MainWindow.setFont(font) MainWindow.setContextMenuPolicy(QtCore.Qt.PreventContextMenu) MainWindow.setProperty("dockNestingEnabled", False) MainWindow.setProperty("unifiedTitleAndToolBarOnMac", False) self.gridLayout = QtWidgets.QGridLayout(MainWindow) self.gridLayout.setContentsMargins(0, 0, 0, 6) self.gridLayout.setSpacing(0) self.gridLayout.setObjectName("gridLayout") self.gridLayout_3 = QtWidgets.QGridLayout() self.gridLayout_3.setContentsMargins(7, -1, 6, 6) self.gridLayout_3.setObjectName("gridLayout_3") spacerItem = QtWidgets.QSpacerItem(6, 20, QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum) self.gridLayout_3.addItem(spacerItem, 0, 2, 1, 1) spacerItem1 = QtWidgets.QSpacerItem(6, 20, QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum) self.gridLayout_3.addItem(spacerItem1, 0, 6, 1, 1) self.recItemsRemoveBtn = TouchButton(MainWindow) self.recItemsRemoveBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.recItemsRemoveBtn.setText("") icon = QtGui.QIcon() icon.addPixmap(QtGui.QPixmap(":/Icons/Icons/RedMinusIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.recItemsRemoveBtn.setIcon(icon) self.recItemsRemoveBtn.setIconSize(QtCore.QSize(58, 58)) self.recItemsRemoveBtn.setObjectName("recItemsRemoveBtn") self.gridLayout_3.addWidget(self.recItemsRemoveBtn, 4, 0, 1, 1) self.line_2 = QtWidgets.QFrame(MainWindow) self.line_2.setLineWidth(1) self.line_2.setMidLineWidth(1) self.line_2.setFrameShape(QtWidgets.QFrame.VLine) self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken) self.line_2.setObjectName("line_2") self.gridLayout_3.addWidget(self.line_2, 0, 3, 7, 1) self.verticalLayout_4 = QtWidgets.QVBoxLayout() self.verticalLayout_4.setContentsMargins(-1, -1, 0, -1) self.verticalLayout_4.setObjectName("verticalLayout_4") spacerItem2 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem2) self.checkInOutBtn = TouchButton(MainWindow) self.checkInOutBtn.setMinimumSize(QtCore.QSize(64, 64)) self.checkInOutBtn.setMaximumSize(QtCore.QSize(64, 64)) self.checkInOutBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.checkInOutBtn.setText("") icon1 = QtGui.QIcon() icon1.addPixmap(QtGui.QPixmap(":/Icons/Icons/RedMinusIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.On) icon1.addPixmap(QtGui.QPixmap(":/Icons/Icons/GreenPlusIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.checkInOutBtn.setIcon(icon1) self.checkInOutBtn.setIconSize(QtCore.QSize(58, 58)) self.checkInOutBtn.setCheckable(True) self.checkInOutBtn.setObjectName("checkInOutBtn") self.verticalLayout_4.addWidget(self.checkInOutBtn) spacerItem3 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem3) self.ManualAddButton = TouchButton(MainWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.ManualAddButton.sizePolicy().hasHeightForWidth()) self.ManualAddButton.setSizePolicy(sizePolicy) self.ManualAddButton.setMinimumSize(QtCore.QSize(64, 64)) self.ManualAddButton.setMaximumSize(QtCore.QSize(64, 64)) self.ManualAddButton.setStyleSheet("background-color: transparent;\n" "border: 0;") self.ManualAddButton.setText("") icon2 = QtGui.QIcon() icon2.addPixmap(QtGui.QPixmap(":/Icons/Icons/FingerIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.ManualAddButton.setIcon(icon2) self.ManualAddButton.setIconSize(QtCore.QSize(58, 58)) self.ManualAddButton.setObjectName("ManualAddButton") self.verticalLayout_4.addWidget(self.ManualAddButton) spacerItem4 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem4) self.PurchaseHistoryButton = TouchButton(MainWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.PurchaseHistoryButton.sizePolicy().hasHeightForWidth()) self.PurchaseHistoryButton.setSizePolicy(sizePolicy) self.PurchaseHistoryButton.setMinimumSize(QtCore.QSize(64, 64)) self.PurchaseHistoryButton.setMaximumSize(QtCore.QSize(64, 64)) font = QtGui.QFont() font.setFamily("Cronus Round") font.setPointSize(22) self.PurchaseHistoryButton.setFont(font) self.PurchaseHistoryButton.setStyleSheet("background-color: transparent;\n" "border: 0;") self.PurchaseHistoryButton.setText("") icon3 = QtGui.QIcon() icon3.addPixmap(QtGui.QPixmap(":/Icons/Icons/ShoppingCart2_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.PurchaseHistoryButton.setIcon(icon3) self.PurchaseHistoryButton.setIconSize(QtCore.QSize(58, 58)) self.PurchaseHistoryButton.setObjectName("PurchaseHistoryButton") self.verticalLayout_4.addWidget(self.PurchaseHistoryButton) spacerItem5 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem5) self.SettingsButton = TouchButton(MainWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.SettingsButton.sizePolicy().hasHeightForWidth()) self.SettingsButton.setSizePolicy(sizePolicy) self.SettingsButton.setMinimumSize(QtCore.QSize(64, 64)) self.SettingsButton.setMaximumSize(QtCore.QSize(64, 64)) self.SettingsButton.setLayoutDirection(QtCore.Qt.LeftToRight) self.SettingsButton.setStyleSheet("background-color: transparent;\n" "border: 0;") self.SettingsButton.setText("") icon4 = QtGui.QIcon() icon4.addPixmap(QtGui.QPixmap(":/Icons/Icons/BlueSettingsIconSOLID_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.SettingsButton.setIcon(icon4) self.SettingsButton.setIconSize(QtCore.QSize(58, 58)) self.SettingsButton.setObjectName("SettingsButton") self.verticalLayout_4.addWidget(self.SettingsButton) spacerItem6 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.verticalLayout_4.addItem(spacerItem6) self.gridLayout_3.addLayout(self.verticalLayout_4, 0, 7, 7, 1) self.printShoppingListButton = TouchButton(MainWindow) self.printShoppingListButton.setMinimumSize(QtCore.QSize(0, 53)) self.printShoppingListButton.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setFamily("Cronus Round") font.setPointSize(22) self.printShoppingListButton.setFont(font) self.printShoppingListButton.setStyleSheet("background-color: transparent;\n" "border: 0;") icon5 = QtGui.QIcon() icon5.addPixmap(QtGui.QPixmap(":/Icons/Icons/PrintIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.printShoppingListButton.setIcon(icon5) self.printShoppingListButton.setIconSize(QtCore.QSize(32, 32)) self.printShoppingListButton.setCheckable(False) self.printShoppingListButton.setObjectName("printShoppingListButton") self.gridLayout_3.addWidget(self.printShoppingListButton, 0, 0, 1, 2) self.recItemsTableView = QtWidgets.QTableView(MainWindow) font = QtGui.QFont() font.setPointSize(19) self.recItemsTableView.setFont(font) self.recItemsTableView.setStyleSheet("QTableView\n" "{\n" " border: 1px solid #76797C;\n" "}") self.recItemsTableView.setFrameShape(QtWidgets.QFrame.NoFrame) self.recItemsTableView.setFrameShadow(QtWidgets.QFrame.Plain) self.recItemsTableView.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.recItemsTableView.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.recItemsTableView.setDragEnabled(True) self.recItemsTableView.setDragDropOverwriteMode(False) self.recItemsTableView.setDragDropMode(QtWidgets.QAbstractItemView.DragOnly) self.recItemsTableView.setDefaultDropAction(QtCore.Qt.LinkAction) self.recItemsTableView.setAlternatingRowColors(True) self.recItemsTableView.setSelectionMode(QtWidgets.QAbstractItemView.MultiSelection) self.recItemsTableView.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows) self.recItemsTableView.setVerticalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel) self.recItemsTableView.setHorizontalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel) self.recItemsTableView.setShowGrid(False) self.recItemsTableView.setSortingEnabled(True) self.recItemsTableView.setObjectName("recItemsTableView") self.recItemsTableView.verticalHeader().setVisible(False) self.gridLayout_3.addWidget(self.recItemsTableView, 6, 1, 1, 1) self.label_4 = QtWidgets.QLabel(MainWindow) font = QtGui.QFont() font.setFamily("Cronus Round") font.setPointSize(16) font.setBold(False) font.setWeight(50) self.label_4.setFont(font) self.label_4.setAlignment(QtCore.Qt.AlignCenter) self.label_4.setObjectName("label_4") self.gridLayout_3.addWidget(self.label_4, 1, 1, 1, 1) self.reqItemsRemoveBtn = TouchButton(MainWindow) self.reqItemsRemoveBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.reqItemsRemoveBtn.setText("") self.reqItemsRemoveBtn.setIcon(icon) self.reqItemsRemoveBtn.setIconSize(QtCore.QSize(58, 58)) self.reqItemsRemoveBtn.setObjectName("reqItemsRemoveBtn") self.gridLayout_3.addWidget(self.reqItemsRemoveBtn, 2, 0, 1, 1) self.reqItemsTableView = QtWidgets.QTableView(MainWindow) font = QtGui.QFont() font.setPointSize(19) self.reqItemsTableView.setFont(font) self.reqItemsTableView.setStyleSheet("QTableView\n" "{\n" " border: 1px solid #76797C;\n" "}") self.reqItemsTableView.setFrameShape(QtWidgets.QFrame.NoFrame) self.reqItemsTableView.setFrameShadow(QtWidgets.QFrame.Plain) self.reqItemsTableView.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAsNeeded) self.reqItemsTableView.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.reqItemsTableView.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.reqItemsTableView.setDragDropMode(QtWidgets.QAbstractItemView.DropOnly) self.reqItemsTableView.setDefaultDropAction(QtCore.Qt.MoveAction) self.reqItemsTableView.setAlternatingRowColors(True) self.reqItemsTableView.setSelectionMode(QtWidgets.QAbstractItemView.MultiSelection) self.reqItemsTableView.setSelectionBehavior(QtWidgets.QAbstractItemView.SelectRows) self.reqItemsTableView.setVerticalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel) self.reqItemsTableView.setHorizontalScrollMode(QtWidgets.QAbstractItemView.ScrollPerPixel) self.reqItemsTableView.setSortingEnabled(True) self.reqItemsTableView.setObjectName("reqItemsTableView") self.reqItemsTableView.verticalHeader().setVisible(False) self.gridLayout_3.addWidget(self.reqItemsTableView, 6, 0, 1, 1) self.label_3 = QtWidgets.QLabel(MainWindow) font = QtGui.QFont() font.setFamily("Cronus Round") font.setPointSize(16) font.setBold(False) font.setWeight(50) self.label_3.setFont(font) self.label_3.setAlignment(QtCore.Qt.AlignCenter) self.label_3.setObjectName("label_3") self.gridLayout_3.addWidget(self.label_3, 1, 0, 1, 1) self.moveToReqListBtn = TouchButton(MainWindow) self.moveToReqListBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.moveToReqListBtn.setText("") icon6 = QtGui.QIcon() icon6.addPixmap(QtGui.QPixmap(":/Icons/Icons/ListIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.moveToReqListBtn.setIcon(icon6) self.moveToReqListBtn.setIconSize(QtCore.QSize(58, 58)) self.moveToReqListBtn.setObjectName("moveToReqListBtn") self.gridLayout_3.addWidget(self.moveToReqListBtn, 5, 0, 1, 1) self.gridLayout.addLayout(self.gridLayout_3, 1, 0, 1, 1) self.gridLayout_2 = QtWidgets.QGridLayout() self.gridLayout_2.setSizeConstraint(QtWidgets.QLayout.SetMinimumSize) self.gridLayout_2.setContentsMargins(0, 0, 0, -1) self.gridLayout_2.setHorizontalSpacing(7) self.gridLayout_2.setObjectName("gridLayout_2") spacerItem7 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_2.addItem(spacerItem7, 0, 2, 1, 1) spacerItem8 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_2.addItem(spacerItem8, 0, 0, 1, 1) self.line_3 = QtWidgets.QFrame(MainWindow) self.line_3.setFrameShape(QtWidgets.QFrame.HLine) self.line_3.setFrameShadow(QtWidgets.QFrame.Sunken) self.line_3.setObjectName("line_3") self.gridLayout_2.addWidget(self.line_3, 1, 0, 1, 3) self.homeBtn = QtWidgets.QPushButton(MainWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.homeBtn.sizePolicy().hasHeightForWidth()) self.homeBtn.setSizePolicy(sizePolicy) self.homeBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.homeBtn.setText("") icon7 = QtGui.QIcon() icon7.addPixmap(QtGui.QPixmap(":/Icons/Icons/SSLogo_No_Background.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.homeBtn.setIcon(icon7) self.homeBtn.setIconSize(QtCore.QSize(256, 64)) self.homeBtn.setCheckable(False) self.homeBtn.setChecked(False) self.homeBtn.setObjectName("homeBtn") self.gridLayout_2.addWidget(self.homeBtn, 0, 1, 1, 1) self.gridLayout.addLayout(self.gridLayout_2, 0, 0, 1, 1) self.retranslateUi(MainWindow) QtCore.QMetaObject.connectSlotsByName(MainWindow) def retranslateUi(self, MainWindow): _translate = QtCore.QCoreApplication.translate MainWindow.setWindowTitle(_translate("MainWindow", "Smart Shop")) self.printShoppingListButton.setText(_translate("MainWindow", "Shopping List")) self.label_4.setText(_translate("MainWindow", "Recommended Items")) self.label_3.setText(_translate("MainWindow", "Required Items"))
class Ui_FavoriteWindow(object): def setupUi(self, FavoriteWindow): FavoriteWindow.setObjectName("FavoriteWindow") FavoriteWindow.setWindowModality(QtCore.Qt.NonModal) FavoriteWindow.resize(800, 480) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( FavoriteWindow.sizePolicy().hasHeightForWidth()) FavoriteWindow.setSizePolicy(sizePolicy) FavoriteWindow.setMaximumSize(QtCore.QSize(855, 661)) font = QtGui.QFont() font.setPointSize(15) FavoriteWindow.setFont(font) FavoriteWindow.setContextMenuPolicy(QtCore.Qt.PreventContextMenu) FavoriteWindow.setProperty("dockNestingEnabled", False) FavoriteWindow.setProperty("unifiedTitleAndToolBarOnMac", False) self.gridLayout = QtWidgets.QGridLayout(FavoriteWindow) self.gridLayout.setContentsMargins(0, 0, 0, 0) self.gridLayout.setSpacing(0) self.gridLayout.setObjectName("gridLayout") self.gridLayout_5 = QtWidgets.QGridLayout() self.gridLayout_5.setContentsMargins(0, -1, 0, 0) self.gridLayout_5.setObjectName("gridLayout_5") self.horizontalLayout_2 = QtWidgets.QHBoxLayout() self.horizontalLayout_2.setContentsMargins(5, -1, 5, -1) self.horizontalLayout_2.setObjectName("horizontalLayout_2") self.backBtn = TouchButton(FavoriteWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.backBtn.sizePolicy().hasHeightForWidth()) self.backBtn.setSizePolicy(sizePolicy) self.backBtn.setMinimumSize(QtCore.QSize(64, 64)) self.backBtn.setMaximumSize(QtCore.QSize(64, 64)) self.backBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.backBtn.setText("") icon = QtGui.QIcon() icon.addPixmap( QtGui.QPixmap(":/Icons/Icons/BlueBackIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.backBtn.setIcon(icon) self.backBtn.setIconSize(QtCore.QSize(64, 64)) self.backBtn.setObjectName("backBtn") self.horizontalLayout_2.addWidget(self.backBtn) spacerItem = QtWidgets.QSpacerItem(214, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_2.addItem(spacerItem) self.gridLayout_5.addLayout(self.horizontalLayout_2, 0, 0, 1, 1) self.homeBtn = TouchButton(FavoriteWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Maximum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.homeBtn.sizePolicy().hasHeightForWidth()) self.homeBtn.setSizePolicy(sizePolicy) self.homeBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.homeBtn.setText("") icon1 = QtGui.QIcon() icon1.addPixmap( QtGui.QPixmap(":/Icons/Icons/SSLogo_No_Background.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.homeBtn.setIcon(icon1) self.homeBtn.setIconSize(QtCore.QSize(256, 64)) self.homeBtn.setCheckable(False) self.homeBtn.setChecked(False) self.homeBtn.setObjectName("homeBtn") self.gridLayout_5.addWidget(self.homeBtn, 0, 1, 1, 1) spacerItem1 = QtWidgets.QSpacerItem(260, 63, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.gridLayout_5.addItem(spacerItem1, 0, 2, 1, 1) self.gridLayout_5.setColumnStretch(0, 1) self.gridLayout_5.setColumnStretch(1, 1) self.gridLayout_5.setColumnStretch(2, 1) self.gridLayout.addLayout(self.gridLayout_5, 2, 0, 1, 3) self.horizontalLayout_4 = QtWidgets.QHBoxLayout() self.horizontalLayout_4.setObjectName("horizontalLayout_4") spacerItem2 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_4.addItem(spacerItem2) self.shoppingListAddBtn = TouchButton(FavoriteWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.shoppingListAddBtn.sizePolicy().hasHeightForWidth()) self.shoppingListAddBtn.setSizePolicy(sizePolicy) self.shoppingListAddBtn.setMinimumSize(QtCore.QSize(48, 48)) self.shoppingListAddBtn.setMaximumSize(QtCore.QSize(48, 48)) self.shoppingListAddBtn.setFocusPolicy(QtCore.Qt.StrongFocus) self.shoppingListAddBtn.setStyleSheet( "background-color: transparent;\n" "border: 0;r") self.shoppingListAddBtn.setText("") icon2 = QtGui.QIcon() icon2.addPixmap(QtGui.QPixmap(":/Icons/Icons/ListIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.shoppingListAddBtn.setIcon(icon2) self.shoppingListAddBtn.setIconSize(QtCore.QSize(48, 48)) self.shoppingListAddBtn.setObjectName("shoppingListAddBtn") self.horizontalLayout_4.addWidget(self.shoppingListAddBtn) spacerItem3 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_4.addItem(spacerItem3) self.gridLayout.addLayout(self.horizontalLayout_4, 4, 0, 1, 1) self.categoryTabWidget = QtWidgets.QTabWidget(FavoriteWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.categoryTabWidget.sizePolicy().hasHeightForWidth()) self.categoryTabWidget.setSizePolicy(sizePolicy) font = QtGui.QFont() font.setPointSize(15) font.setBold(False) font.setItalic(False) font.setUnderline(False) font.setWeight(50) font.setKerning(True) self.categoryTabWidget.setFont(font) self.categoryTabWidget.setAcceptDrops(True) self.categoryTabWidget.setStyleSheet("") self.categoryTabWidget.setUsesScrollButtons(True) self.categoryTabWidget.setDocumentMode(False) self.categoryTabWidget.setMovable(False) self.categoryTabWidget.setObjectName("categoryTabWidget") self.favoritesTab = QtWidgets.QWidget() self.favoritesTab.setObjectName("favoritesTab") self.gridLayout_4 = QtWidgets.QGridLayout(self.favoritesTab) self.gridLayout_4.setContentsMargins(0, 0, 0, 0) self.gridLayout_4.setSpacing(0) self.gridLayout_4.setObjectName("gridLayout_4") self.favoritesTableView = TileView(self.favoritesTab) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.favoritesTableView.sizePolicy().hasHeightForWidth()) self.favoritesTableView.setSizePolicy(sizePolicy) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(15) self.favoritesTableView.setFont(font) self.favoritesTableView.setStyleSheet("") self.favoritesTableView.setFrameShape(QtWidgets.QFrame.NoFrame) self.favoritesTableView.setFrameShadow(QtWidgets.QFrame.Plain) self.favoritesTableView.setLineWidth(0) self.favoritesTableView.setVerticalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOn) self.favoritesTableView.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.favoritesTableView.setSizeAdjustPolicy( QtWidgets.QAbstractScrollArea.AdjustIgnored) self.favoritesTableView.setAutoScroll(True) self.favoritesTableView.setEditTriggers( QtWidgets.QAbstractItemView.NoEditTriggers) self.favoritesTableView.setDragEnabled(True) self.favoritesTableView.setDragDropMode( QtWidgets.QAbstractItemView.DragDrop) self.favoritesTableView.setDefaultDropAction(QtCore.Qt.ActionMask) self.favoritesTableView.setAlternatingRowColors(True) self.favoritesTableView.setSelectionMode( QtWidgets.QAbstractItemView.MultiSelection) self.favoritesTableView.setTextElideMode(QtCore.Qt.ElideRight) self.favoritesTableView.setVerticalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.favoritesTableView.setHorizontalScrollMode( QtWidgets.QAbstractItemView.ScrollPerPixel) self.favoritesTableView.setShowGrid(True) self.favoritesTableView.setWordWrap(True) self.favoritesTableView.setObjectName("favoritesTableView") self.favoritesTableView.horizontalHeader().setVisible(False) self.favoritesTableView.horizontalHeader().setDefaultSectionSize(165) self.favoritesTableView.verticalHeader().setVisible(False) self.favoritesTableView.verticalHeader().setDefaultSectionSize(90) self.gridLayout_4.addWidget(self.favoritesTableView, 0, 0, 1, 1) self.categoryTabWidget.addTab(self.favoritesTab, "") self.gridLayout.addWidget(self.categoryTabWidget, 3, 0, 1, 3) self.floatingBtnWidget = QtWidgets.QWidget(FavoriteWindow) self.floatingBtnWidget.setStyleSheet( "background-color: rgba(0,0,0,0);") self.floatingBtnWidget.setObjectName("floatingBtnWidget") self.horizontalLayout = QtWidgets.QHBoxLayout(self.floatingBtnWidget) self.horizontalLayout.setContentsMargins(0, 3, 0, 6) self.horizontalLayout.setSpacing(20) self.horizontalLayout.setObjectName("horizontalLayout") self.addBtn = TouchButton(self.floatingBtnWidget) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.addBtn.sizePolicy().hasHeightForWidth()) self.addBtn.setSizePolicy(sizePolicy) self.addBtn.setMinimumSize(QtCore.QSize(48, 48)) self.addBtn.setMaximumSize(QtCore.QSize(48, 48)) self.addBtn.setStyleSheet("background-color: transparent; border: 0;") self.addBtn.setText("") icon3 = QtGui.QIcon() icon3.addPixmap( QtGui.QPixmap(":/Icons/Icons/GreenPlusIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.addBtn.setIcon(icon3) self.addBtn.setIconSize(QtCore.QSize(48, 48)) self.addBtn.setObjectName("addBtn") self.horizontalLayout.addWidget(self.addBtn) self.removeBtn = TouchButton(self.floatingBtnWidget) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.removeBtn.sizePolicy().hasHeightForWidth()) self.removeBtn.setSizePolicy(sizePolicy) self.removeBtn.setMinimumSize(QtCore.QSize(48, 48)) self.removeBtn.setMaximumSize(QtCore.QSize(48, 48)) self.removeBtn.setStyleSheet("background-color: transparent;\n" "border: 0;") self.removeBtn.setText("") icon4 = QtGui.QIcon() icon4.addPixmap( QtGui.QPixmap(":/Icons/Icons/RedMinusIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.removeBtn.setIcon(icon4) self.removeBtn.setIconSize(QtCore.QSize(48, 48)) self.removeBtn.setObjectName("removeBtn") self.horizontalLayout.addWidget(self.removeBtn) self.gridLayout.addWidget(self.floatingBtnWidget, 4, 1, 1, 1) self.horizontalLayout_3 = QtWidgets.QHBoxLayout() self.horizontalLayout_3.setObjectName("horizontalLayout_3") spacerItem4 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_3.addItem(spacerItem4) self.listAddBtn = TouchButton(FavoriteWindow) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.listAddBtn.sizePolicy().hasHeightForWidth()) self.listAddBtn.setSizePolicy(sizePolicy) self.listAddBtn.setMinimumSize(QtCore.QSize(48, 48)) self.listAddBtn.setMaximumSize(QtCore.QSize(48, 48)) self.listAddBtn.setFocusPolicy(QtCore.Qt.StrongFocus) self.listAddBtn.setStyleSheet("background-color: transparent;\n" "border: 0;r") self.listAddBtn.setText("") icon5 = QtGui.QIcon() icon5.addPixmap(QtGui.QPixmap(":/Icons/Icons/EditIcon_Finished.png"), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.listAddBtn.setIcon(icon5) self.listAddBtn.setIconSize(QtCore.QSize(48, 48)) self.listAddBtn.setObjectName("listAddBtn") self.horizontalLayout_3.addWidget(self.listAddBtn) spacerItem5 = QtWidgets.QSpacerItem(40, 20, QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Minimum) self.horizontalLayout_3.addItem(spacerItem5) self.gridLayout.addLayout(self.horizontalLayout_3, 4, 2, 1, 1) self.gridLayout.setColumnStretch(0, 1) self.gridLayout.setColumnStretch(1, 1) self.gridLayout.setColumnStretch(2, 1) self.retranslateUi(FavoriteWindow) self.categoryTabWidget.setCurrentIndex(0) QtCore.QMetaObject.connectSlotsByName(FavoriteWindow) def retranslateUi(self, FavoriteWindow): _translate = QtCore.QCoreApplication.translate FavoriteWindow.setWindowTitle( _translate("FavoriteWindow", "Smart Shop")) self.categoryTabWidget.setTabText( self.categoryTabWidget.indexOf(self.favoritesTab), _translate("FavoriteWindow", "Favorite\'s"))