当前位置: 首页>>代码示例>>Python>>正文


Python ErrorMessageClass.setFixedSize方法代码示例

本文整理汇总了Python中ErrorMessageClass.setFixedSize方法的典型用法代码示例。如果您正苦于以下问题:Python ErrorMessageClass.setFixedSize方法的具体用法?Python ErrorMessageClass.setFixedSize怎么用?Python ErrorMessageClass.setFixedSize使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ErrorMessageClass的用法示例。


在下文中一共展示了ErrorMessageClass.setFixedSize方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: deleteProductClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class deleteProductClass(QWidget):
    """ A representation of the Adding Product Interface"""
    def __init__(self):
        super().__init__()
        #Adding group box
        self.product_info_group_box = QGroupBox()
        self.product_info_group_box.setTitle("Enter Product Information:")
        
        

        #creating the buttons
        self.find_product_id_layout = QHBoxLayout()
        self.find_product_id_widget = QWidget()
        self.find_product_id_label = QLabel("ProductID")
        self.find_product_id_line_edit = QLineEdit()
        self.find_product_id_button = QPushButton("Find...")
        self.find_product_id_button.setFixedSize(84,27)
        self.find_product_id_button.clicked.connect(self.find_product_by_id)

                                        
        self.find_product_id_layout.addWidget(self.find_product_id_label)
        self.find_product_id_layout.addWidget(self.find_product_id_line_edit)
        self.find_product_id_layout.addWidget(self.find_product_id_button)
        self.find_product_id_widget.setLayout(self.find_product_id_layout)
        
        #Price
        self.pound = QLabel("Price: £")
        self.price_button = QLineEdit("")
        self.price_button.setReadOnly(True)
        self.validator = QDoubleValidator()
        self.price_button.setPlaceholderText("Price: £0.00")
        self.price_widget = QWidget()
        self.price_layout = QHBoxLayout()
        self.price_layout.addWidget(self.pound)
        self.price_layout.addWidget(self.price_button)
        self.price_widget.setLayout(self.price_layout)
        

        #Size
        self.size_layout = QHBoxLayout()
        self.size_widget = QWidget()
        self.size_integer = QLineEdit()
        self.size_integer.setReadOnly(True)
        self.size_integer.setPlaceholderText("Size: (750)")
        self.size_integer.setFixedWidth(180)
        self.size_button = QComboBox()
        self.size_button.setDisabled(True)
        self.size_button.addItem("Kg.")
        self.size_button.addItem("g.")
        self.size_button.addItem("L.")
        self.size_button.addItem("ml.")
        self.size_layout.addWidget(self.size_integer)
        self.size_layout.addWidget(self.size_button)
        self.size_widget.setLayout(self.size_layout)

        #Category
        self.category_layout = QHBoxLayout()
        self.category_label = QLabel("Category")
        self.category1_button = QComboBox()
        self.category1_button.setFixedHeight(30)
        self.category1_button.setDisabled(True)
        self.category2_button = QComboBox()
        self.category2_button.setFixedHeight(30)
        self.category2_button.setDisabled(True)
        self.category1_button.addItem("Dog")
        self.category1_button.addItem("Cat")
        self.category1_button.addItem("Fish")
        self.category1_button.addItem("Small Pet")
        self.category1_button.addItem("Bird")
        self.category1_button.addItem("Reptile")
        self.category1_button.addItem("Equine")
        self.category2_button.addItem("Food")
        self.category2_button.addItem("Health Care")
        self.category_layout.addWidget(self.category_label)
        self.category_layout.addWidget(self.category1_button)
        self.category_layout.addWidget(self.category2_button)
        self.category_widget = QWidget()
        self.category_widget.setLayout(self.category_layout)

        #Location 1
        self.location1 = QLineEdit()
        self.location1.setPlaceholderText("Stock In Location 1...")
        self.location1.setDisabled(True)


        #Location 2
        self.location2 = QLineEdit()
        self.location2.setPlaceholderText("Stock In Location 2...")
        self.location2.setDisabled(True)


        #Done
        self.done = QPushButton("Delete Product")
        self.done.clicked.connect(self.CreatePopUpWindow)
        self.done.setShortcut(QKeySequence("CTRL+S"))
        self.done.setFixedSize(110, 27)

        #Product Name
        self.product_name = QLineEdit()
        self.product_name.setReadOnly(True)
#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:DeleteProductClass.py

示例2: manageStockClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class manageStockClass(QWidget):
    """A representation of managing stock"""
    def __init__(self):
        super().__init__()
        self.product_id_layout = QHBoxLayout()
        self.product_id_widget = QWidget()
        self.product_id_label = QLabel("Product ID: ")
        self.product_id = QLineEdit()
        self.find_button = QPushButton("Find..")
        self.find_button.setFixedSize(84,27)
        self.find_button.clicked.connect(self.find_product_by_id)
        self.product_id_layout.addWidget(self.product_id_label)
        self.product_id_layout.addWidget(self.product_id)
        self.product_id_layout.addWidget(self.find_button)
        self.product_id_widget.setLayout(self.product_id_layout)

        self.buttonBox = QDialogButtonBox()
        self.buttonBox.setOrientation(Qt.Horizontal)
        self.buttonBox.setStandardButtons(QDialogButtonBox.Save)
        self.buttonBox.button(QDialogButtonBox.Save).setFixedSize(84,27)
        self.buttonBox.button(QDialogButtonBox.Save).setShortcut(QKeySequence("CTRL+S"))
        self.buttonBox.button(QDialogButtonBox.Save).clicked.connect(self.save)

        self.path = (".\images\Default.png")
        self.image = QLabel()
        self.image_pixmap = QPixmap(self.path)
        self.scaled_image = self.image_pixmap.scaled(180, 180, Qt.IgnoreAspectRatio, Qt.FastTransformation)
        self.image.setPixmap(self.scaled_image)

        self.product_name = QLabel("Product Name")
        self.product_name.setObjectName("product_name")
        self.stock1_label = QLabel("Stock in Shop: ")
        self.stock2_label = QLabel("Stock in Storage Room: ")
        self.stock1 = QSpinBox()
        self.stock1.setFixedWidth(50)
        self.stock2 = QSpinBox()
        self.stock2.setFixedWidth(50)

        self.current_stock_groupbox = QGroupBox("Current Stock: ")
        self.current_stock_layout = QHBoxLayout()
        self.product_info_layout = QVBoxLayout() 
        self.product_info_widget = QWidget()
        self.stock_layout = QGridLayout()
        self.stock_widget = QWidget()

        self.stock_layout.addWidget(self.stock1_label, 0,0)
        self.stock_layout.addWidget(self.stock1, 0,1)
        self.stock_layout.addWidget(self.stock2_label, 1,0)
        self.stock_layout.addWidget(self.stock2, 1,1)
        self.stock_widget.setLayout(self.stock_layout)
        
        self.product_info_layout.addWidget(self.product_name)
        self.product_info_layout.addWidget(self.stock_widget)
        self.product_info_widget.setLayout(self.product_info_layout)

        self.current_stock_layout.addWidget(self.image)
        self.current_stock_layout.addWidget(self.product_info_widget)
        self.current_stock_groupbox.setLayout(self.current_stock_layout)

        self.stock_prediction_groupbox = QGroupBox("Stock Prediction")
        self.stock_prediction_layout = QHBoxLayout()

        #ADDING THE GRAPH TO THE WINDOW
        self.figure = plt.figure()
        self.canvas = FigureCanvas(self.figure)
        #ADDING THE GRAPH TO THE WINDOW
        self.prediction_label = QLabel("Predicted  Sales Next Week: ")
        self.prediction = QLabel()

        self.prediction_layout = QHBoxLayout()
        self.prediction_widget = QWidget()
        self.prediction_layout.addWidget(self.prediction_label)
        self.prediction_layout.addWidget(self.prediction)
        self.prediction_widget.setLayout(self.prediction_layout)

        self.change_sales_layout = QHBoxLayout()
        self.change_sales_widget = QWidget()
        self.change_sales_label = QLabel("View Sales Per:")
        self.change_sales_box = QComboBox()
        self.change_sales_box.setFixedHeight(30)
        self.change_sales_box.addItem("Day")
        self.change_sales_box.addItem("Week")
        self.change_sales_box.currentIndexChanged.connect(self.change_graph)
        self.change_sales_layout.addWidget(self.change_sales_label)
        self.change_sales_layout.addWidget(self.change_sales_box)
        self.change_sales_widget.setLayout(self.change_sales_layout)

        self.sales_layout = QVBoxLayout()
        self.sales_widget = QWidget()
        self.sales_layout.addWidget(self.change_sales_widget)
        self.sales_layout.addWidget(self.prediction_widget)
        self.sales_widget.setLayout(self.sales_layout)

        self.stock_prediction_layout.addWidget(self.canvas)
        self.stock_prediction_layout.addWidget(self.sales_widget)
        self.stock_prediction_groupbox.setLayout(self.stock_prediction_layout)

        self.current_stock_groupbox.setDisabled(True)
        self.stock_prediction_groupbox.setDisabled(True)

#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:StockManagementClass.py

示例3: editEmployeeClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class editEmployeeClass(QWidget):
    """a representation of editing an Employee"""
    def __init__(self,ButtonText):
        super().__init__()

        self.find_employee_id_layout = QHBoxLayout()
        self.find_employee_id_widget = QWidget()
        self.find_employee_id_label = QLabel("MemberID")
        self.find_employee_id_line_edit = QLineEdit()
        self.find_employee_id_button = QPushButton("Find...")
        self.find_employee_id_button.setFixedSize(84,27)
        self.find_employee_id_button.clicked.connect(self.find_employee_by_id)                                        
        self.find_employee_id_layout.addWidget(self.find_employee_id_label)
        self.find_employee_id_layout.addWidget(self.find_employee_id_line_edit)
        self.find_employee_id_layout.addWidget(self.find_employee_id_button)
        self.find_employee_id_widget.setLayout(self.find_employee_id_layout)
        

        #User Name
        self.user_name_widget = QWidget()
        self.user_name_layout = QHBoxLayout()
        self.user_name_label = QLabel("Username: ")
        self.user_name_label.setFixedWidth(100)
        self.user_name_output = QLineEdit("")
        self.user_name_output.setReadOnly(True)
        self.user_name_layout.addWidget(self.user_name_label)
        self.user_name_layout.addWidget(self.user_name_output)
        self.user_name_widget.setLayout(self.user_name_layout)
        

        #First Name
        self.first_name_widget = QWidget()
        self.first_name_layout = QHBoxLayout()
        self.first_name_label = QLabel("First Name: ")
        self.first_name_label.setFixedWidth(100)
        self.first_name = QLineEdit("")
        self.first_name.textChanged.connect(self.validate_first_name)
        self.first_name.setPlaceholderText("First Name")
        self.first_name_output = QLineEdit("")
        self.first_name_output.setReadOnly(True)
        self.first_name_layout.addWidget(self.first_name_label)
        self.first_name_layout.addWidget(self.first_name_output)
        self.first_name_widget.setLayout(self.first_name_layout)

        #Last Name
        self.last_name_widget = QWidget()
        self.last_name_layout = QHBoxLayout()
        self.last_name_label = QLabel("Last Name: ")
        self.last_name_label.setFixedWidth(100)
        self.last_name = QLineEdit("")
        self.last_name.textChanged.connect(self.validate_last_name)
        self.last_name.setPlaceholderText("Last Name")
        self.last_name_output = QLineEdit("")
        self.last_name_output.setReadOnly(True)
        self.last_name_layout.addWidget(self.last_name_label)
        self.last_name_layout.addWidget(self.last_name_output)
        self.last_name_widget.setLayout(self.last_name_layout)

        #Email Address
        self.email_address_widget = QWidget()
        self.email_address_layout = QHBoxLayout()
        self.email_address_label = QLabel("Email Address: ")
        self.email_address_label.setFixedWidth(100)
        self.email_address = QLineEdit()
        self.email_address.textChanged.connect(self.validate_email)
        self.email_address.setPlaceholderText("Email Address")
        self.email_address_output = QLineEdit("")
        self.email_address_output.setReadOnly(True)
        self.email_address_layout.addWidget(self.email_address_label)
        self.email_address_layout.addWidget(self.email_address_output)
        self.email_address_widget.setLayout(self.email_address_layout)
        

        #Submit
        self.submit_button = QPushButton("Submit")
        self.submit_button.clicked.connect(self.update_preview)
        self.submit_button.setFixedSize(60,27)
        self.submit_button.setObjectName("submit")

        #Add Account
        self.add_account = QPushButton(ButtonText)
        self.add_account.clicked.connect(self.CreatePopUpWindow)
        self.add_account.setShortcut(QKeySequence("CTRL+S"))
        self.add_account.setFixedSize(120, 27)

        self.spacer = QLabel()
        self.spacer.setFixedWidth(600)
        self.add_employee_layout = QHBoxLayout()
        self.add_employee_widget = QWidget()
        self.add_employee_layout.addWidget(self.spacer)
        self.add_employee_layout.addWidget(self.add_account)
        self.add_employee_widget.setLayout(self.add_employee_layout)
        

        #Creating Layouts and Adding Widgets
        self.main_layout = QGridLayout()
        self.main_widget = QWidget()
        self.info_box = QGroupBox()
        self.info_box.setTitle("Enter Employee Information")
        self.info_box_layout = QVBoxLayout()
#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:EditEmployeeClass.py

示例4: deleteMemberClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class deleteMemberClass(QWidget):
        """a representation of Deleting an Member"""
        def __init__(self, ButtonText):
                super().__init__()

                self.find_member_id_layout = QHBoxLayout()
                self.find_member_id_widget = QWidget()
                self.find_member_id_label = QLabel("MemberID")
                self.find_member_id_line_edit = QLineEdit()
                self.find_member_id_button = QPushButton("Find...")
                self.find_member_id_button.setFixedSize(84,27)
                self.find_member_id_button.clicked.connect(self.find_member_by_id)                                        
                self.find_member_id_layout.addWidget(self.find_member_id_label)
                self.find_member_id_layout.addWidget(self.find_member_id_line_edit)
                self.find_member_id_layout.addWidget(self.find_member_id_button)
                self.find_member_id_widget.setLayout(self.find_member_id_layout)

                #Name_title
                self.name_title = QComboBox()
                self.name_title.addItem("Mr.")
                self.name_title.addItem("Mrs.")
                self.name_title.addItem("Ms.")
                self.name_title.addItem("Miss.")
                self.name_title.addItem("Dr.")
                self.name_title.addItem("Prof.")
                self.name_title.addItem("Sgt.")

                #First name
                self.first_name = QLineEdit()
                self.first_name.setPlaceholderText("First Name: ")
                    
                #Last Name
                self.last_name = QLineEdit()
                self.last_name.setPlaceholderText("Last Name: ")
                    
                #Postcode Tickbox
                self.postcode_tickbox = QCheckBox("Do You Live in Cumbria?")

                #Find Button
                self.find_button = QPushButton("Find...")
                self.find_button.setEnabled(False)
                self.find_button.setFixedSize(84,27)
                self.find_button.setObjectName("find_button")
                self.find_button.clicked.connect(self.FindPostcode)

                    
                self.postcode_tickbox.stateChanged.connect(self.change_button)
                    

                #Postcode
                self.postcode_layout = QHBoxLayout()
                self.postcode_widget = QWidget()
                self.postcode_label = QLabel("Postcode: ")
                self.postcode = QLineEdit()
                #self.postcode.setStyleSheet("QLineEdit { background-color : rgb(166,251,153);}")
                self.postcode.setPlaceholderText("Postcode: i.e(CB7 5LQ) ")
                self.postcode_layout.addWidget(self.postcode_label)
                self.postcode_layout.addWidget(self.postcode)
                self.postcode_layout.addWidget(self.find_button)
                self.postcode_widget.setLayout(self.postcode_layout)                

                #County
                self.county_layout = QHBoxLayout()
                self.county_widget = QWidget()
                self.county_label = QLabel("County: ")
                self.county = QComboBox()
                self.county_list = []
                self.get_counties()
                
                for item in self.county_list:
                        self.county.addItem(item)

                
                self.county_layout.addWidget(self.county_label)
                self.county_layout.addWidget(self.county)
                self.county_widget.setLayout(self.county_layout)
                

                #City
                self.city_layout = QHBoxLayout()
                self.city_widget = QWidget()
                self.city_label = QLabel("City: ")
                self.city = QLineEdit()
                self.city.setPlaceholderText("City: ")
                self.city_layout.addWidget(self.city_label)
                self.city_layout.addWidget(self.city)
                self.city_widget.setLayout(self.city_layout)
 
                #Town
                self.town_layout = QHBoxLayout()
                self.town_widget = QWidget()
                self.town_label = QLabel("Town: ")
                self.town = QLineEdit()
                self.town.setPlaceholderText("Town: ")
                self.town_layout.addWidget(self.town_label)
                self.town_layout.addWidget(self.town)
                self.town_widget.setLayout(self.town_layout)

                #Street
                self.street_layout = QHBoxLayout()
#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:DeleteMemberClass.py

示例5: preferencesClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class preferencesClass(QWidget):
    """ A representation of the Adding Product Interface"""
    def __init__(self):
        super().__init__()
        settings = getSettings()
        self.main_layout = QVBoxLayout()
        self.main_widget = QWidget()
        ##
        self.company_info = QGroupBox("Company Info:")
        self.company_info_layout = QVBoxLayout()
        self.buttonBox = QDialogButtonBox()
        self.buttonBox.setOrientation(Qt.Horizontal)
        self.buttonBox.setStandardButtons(QDialogButtonBox.Save)
        self.buttonBox.button(QDialogButtonBox.Save).clicked.connect(self.save_clicked)
        self.buttonBox.button(QDialogButtonBox.Save).setFixedSize(84,27)

        self.image_layout = QVBoxLayout()
        self.image_widget = QWidget()
        ##
        if not settings:
            path = ""
        else:
            path = settings[0][1]
        self.unscaled_pixmap = QPixmap(path)
        self.pixmap = self.unscaled_pixmap.scaled(230, 230, Qt.IgnoreAspectRatio, Qt.FastTransformation)
        self.image_label = QLabel()
        self.image_label.setPixmap(self.pixmap)
        self.logo = QGroupBox("Logo:")


        self.path_layout = QHBoxLayout()
        self.path_widget = QWidget()
        #
        self.path = QLineEdit()
        self.path.setReadOnly(True)
        self.path.setText(path)
        self.browse_button = QPushButton("Browse...")
        self.browse_button.setFixedSize(100, 27)
        self.browse_button.setObjectName('browse')
        self.browse_button.clicked.connect(self.get_path)
        self.path_layout.addWidget(self.path)
        self.path_layout.addWidget(self.browse_button)
        self.path_widget.setLayout(self.path_layout)
        self.path_widget.setFixedWidth(300)
        
        self.details_layout = QGridLayout()
        self.details_widget = QWidget()
        self.company_name_label = QLabel("Company Name: ")
        self.street_label = QLabel("Street: ")
        self.town_label = QLabel("Town: ")
        self.city_label = QLabel("City: ")
        self.county_label = QLabel("County: ")
        self.postcode_label = QLabel("Postcode: ")
        self.phone_label = QLabel("Phone Number: ")
        self.email_label = QLabel("Email Address: ")
        self.company_name = QLineEdit()
        self.street = QLineEdit()
        self.town = QLineEdit()
        self.city = QLineEdit()
        self.county = QLineEdit()
        self.postcode = QLineEdit()
        self.phone = QLineEdit()
        self.email = QLineEdit()

        self.invoice_email_label = QLabel("Email: ")
        self.invoice_password_label = QLabel("Password: ")
        self.invoice_email = QLineEdit()
        self.invoice_password = QLineEdit()
        self.invoice_password.setEchoMode(QLineEdit.Password)

        self.new_path_line_edit = QLineEdit()

        #INSERT THE DATA FROM FILE HERE
        if settings:
            self.company_name.setText(settings[0][2])
            self.street.setText(settings[0][3])
            self.town.setText(settings[0][4])
            self.city.setText(settings[0][5])
            self.county.setText(settings[0][6])
            self.postcode.setText(settings[0][7])
            self.phone.setText(settings[0][8])
            self.email.setText(settings[0][9])
            self.invoice_email.setText(settings[0][10])
            self.invoice_password.setText(settings[0][11])
            #INSERT THE DATA FROM FILE HERE

        self.question = ExtendedQLabel("What is this?")
        self.question.setObjectName("blue_question")
        self.question.setFixedSize(100, 40)

        self.gmail_groupbox = QGroupBox("Email Account:")
        self.gmail_layout = QGridLayout()
        self.gmail_layout.addWidget(self.invoice_email_label, 0,0)
        self.gmail_layout.addWidget(self.invoice_email, 0,1)
        self.gmail_layout.addWidget(self.invoice_password_label, 1,0)
        self.gmail_layout.addWidget(self.invoice_password, 1,1)
        self.gmail_layout.addWidget(self.question, 2,1)
        self.gmail_groupbox.setLayout(self.gmail_layout)
        self.gmail_groupbox.setFixedHeight(250)
        
#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:PreferencesClass.py

示例6: deleteEmployeeClass

# 需要导入模块: import ErrorMessageClass [as 别名]
# 或者: from ErrorMessageClass import setFixedSize [as 别名]
class deleteEmployeeClass(QWidget):
    """a representation of Adding an Employee"""
    def __init__(self,ButtonText):
        super().__init__()

        self.find_employee_id_layout = QHBoxLayout()
        self.find_employee_id_widget = QWidget()
        self.find_employee_id_label = QLabel("MemberID")
        self.find_employee_id_line_edit = QLineEdit()
        self.find_employee_id_button = QPushButton("Find...")
        self.find_employee_id_button.setFixedSize(84,27)
        self.find_employee_id_button.clicked.connect(self.find_employee_by_id)                                        
        self.find_employee_id_layout.addWidget(self.find_employee_id_label)
        self.find_employee_id_layout.addWidget(self.find_employee_id_line_edit)
        self.find_employee_id_layout.addWidget(self.find_employee_id_button)
        self.find_employee_id_widget.setLayout(self.find_employee_id_layout)
        

        #User Name
        self.user_name_widget = QWidget()
        self.user_name_layout = QHBoxLayout()
        self.user_name_label = QLabel("Username: ")
        self.user_name_label.setFixedWidth(100)
        self.user_name_output = QLineEdit("")
        self.user_name_output.setReadOnly(True)
        self.user_name_layout.addWidget(self.user_name_label)
        self.user_name_layout.addWidget(self.user_name_output)
        self.user_name_widget.setLayout(self.user_name_layout)
        

        #First Name
        self.first_name_widget = QWidget()
        self.first_name_layout = QHBoxLayout()
        self.first_name_label = QLabel("First Name: ")
        self.first_name_label.setFixedWidth(100)
        self.first_name = QLineEdit("")
        self.first_name.setPlaceholderText("First Name")
        self.first_name_output = QLineEdit("")
        self.first_name_output.setReadOnly(True)
        self.first_name_layout.addWidget(self.first_name_label)
        self.first_name_layout.addWidget(self.first_name_output)
        self.first_name_widget.setLayout(self.first_name_layout)

        #Last Name
        self.last_name_widget = QWidget()
        self.last_name_layout = QHBoxLayout()
        self.last_name_label = QLabel("Last Name: ")
        self.last_name_label.setFixedWidth(100)
        self.last_name = QLineEdit("")
        self.last_name.setPlaceholderText("Last Name")
        self.last_name_output = QLineEdit("")
        self.last_name_output.setReadOnly(True)
        self.last_name_layout.addWidget(self.last_name_label)
        self.last_name_layout.addWidget(self.last_name_output)
        self.last_name_widget.setLayout(self.last_name_layout)

        #Email Address
        self.email_address_widget = QWidget()
        self.email_address_layout = QHBoxLayout()
        self.email_address_label = QLabel("Email Address: ")
        self.email_address_label.setFixedWidth(100)
        self.email_address = QLineEdit()
        self.email_address.setPlaceholderText("Email Address")
        self.email_address_output = QLineEdit("")
        self.email_address_output.setReadOnly(True)
        self.email_address_layout.addWidget(self.email_address_label)
        self.email_address_layout.addWidget(self.email_address_output)
        self.email_address_widget.setLayout(self.email_address_layout)
        

        #Submit
        self.submit_button = QPushButton("Submit")
        self.submit_button.clicked.connect(self.update_preview)
        self.submit_button.setFixedSize(60,27)
        self.submit_button.setObjectName("submit")

        #Add Account
        self.add_account = QPushButton(ButtonText)
        self.add_account.clicked.connect(self.CreatePopUpWindow)
        self.add_account.setShortcut(QKeySequence("CTRL+S"))
        self.add_account.setFixedSize(120, 27)

        self.spacer = QLabel()
        self.spacer.setFixedWidth(600)
        self.add_employee_layout = QHBoxLayout()
        self.add_employee_widget = QWidget()
        self.add_employee_layout.addWidget(self.spacer)
        self.add_employee_layout.addWidget(self.add_account)
        self.add_employee_widget.setLayout(self.add_employee_layout)
        

        #Creating Layouts and Adding Widgets
        self.main_layout = QGridLayout()
        self.main_widget = QWidget()
        self.info_box = QGroupBox()
        self.info_box.setTitle("Enter Employee Information")
        self.info_box_layout = QVBoxLayout()

        
        self.info_box_layout.addWidget(self.first_name)
#.........这里部分代码省略.........
开发者ID:mattling9,项目名称:COMP4Coursework,代码行数:103,代码来源:DeleteEmployeeClass.py


注:本文中的ErrorMessageClass.setFixedSize方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。