def _create_controls(self): self._chart_type_combo = QtWidgets.QComboBox() self._chart_type_combo.setMaximumWidth(100) self._start_date_edit = QtWidgets.QDateEdit() self._start_date_edit.setMaximumWidth(100) self._end_date_edit = QtWidgets.QDateEdit() self._end_date_edit.setMaximumWidth(100)
def __init__(self, parent=None): super().__init__(parent) self.setWindowTitle("Dodaj proizvod") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.naziv_p_input = QtWidgets.QLineEdit(self) self.rok_upotrebe_input = QtWidgets.QDateEdit(self) self.temp_cuvanja_input = QtWidgets.QLineEdit(self) self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.rok_upotrebe_input.setDate(QtCore.QDate.currentDate()) self.rok_upotrebe_input.setCalendarPopup(True) self.form_layout.addRow("Naziv Proizvoda:", self.naziv_p_input) self.form_layout.addRow("Rok Upotrebe:", self.rok_upotrebe_input) self.form_layout.addRow("Temperatura Čuvanja:", self.temp_cuvanja_input) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def __init__(self, analysis_start_values: AnalysisStartValues, callback, input_data_layout): self.housing_money_widgets = {} self.pop_bsu_widget = QtWidgets.QCheckBox('Pop BSU') self.pop_bsu_widget.stateChanged.connect(callback) self.pop_bsu2_widget = QtWidgets.QCheckBox('Pop BSU2') self.pop_bsu2_widget.stateChanged.connect(callback) self.mortgage_date_widget = QtWidgets.QDateEdit() self.mortgage_date_widget.setDate(datetime.date.today() + datetime.timedelta(days=20)) self.mortgage_date_widget.dateChanged.connect(callback) input_data_layout.addRow('mortgage date', self.mortgage_date_widget) for person in analysis_start_values.persons: widget = QtWidgets.QLineEdit(str(person.housing_money)) widget.textChanged.connect(callback) self.housing_money_widgets[person.name] = widget input_data_layout.addRow(f'Housing money {person.name}', widget) for field in [ 'property_value', 'top_loan_interest_percentage', 'mortgage_interest_percentage' ]: widget = QtWidgets.QLineEdit( str(getattr(analysis_start_values, field))) setattr(self, f'{field}_widget', widget) widget.textChanged.connect(callback) input_data_layout.addRow(field.replace('_', ' '), getattr(self, f'{field}_widget'))
def __init__(self, parent=None): """ Inicijalizator dijaloga za izmjenu proizvoda. :param parent: roditeljski widget. :type parent: QWidget """ super().__init__(parent) self.setWindowTitle("Izmijeni proizvod") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.date_input = QtWidgets.QDateEdit(self) self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.date_input.setDate(QtCore.QDate.currentDate()) self.date_input.setCalendarPopup(True) self.form_layout.addRow("Datum isteka roka:", self.date_input) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self.accept) self.button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def __init__(self, parent): super().__init__(parent) self.resize(400, 350) self.setWindowTitle("Kreiraj novi kontakt") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.name_input = QtWidgets.QLineEdit(self) self.surname_input = QtWidgets.QLineEdit(self) self.birthday = QtWidgets.QDateEdit(self) self.email = QtWidgets.QLineEdit(self) self.name_input.setPlaceholderText("Ime") self.birthday.setCalendarPopup(True) self.form_layout.addRow("Ime:", self.name_input) self.form_layout.addRow("Prezime:", self.surname_input) self.form_layout.addRow("Datum rodjenja:", self.birthday) self.form_layout.addRow("Email:", self.email) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.setLayout(self.vbox_layout) self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject)
def __init__(self, hall, parent=None): """ Inicijalizator dijaloga za dodavanje novog proivoda. :param hall: selektovana hala :type hall: Hall :param parent: roditeljski widget. :type parent: QWidget """ super().__init__(parent) self.setWindowTitle("Dodaj proizvod") self.setWindowIcon(QIcon("resources/icons/plus.png")) self.resize(350, 256) self.button_box = QtWidgets.QDialogButtonBox(self) self.button_box.setGeometry(QtCore.QRect(200, 200, 140, 32)) self.button_box.setOrientation(QtCore.Qt.Horizontal) self.button_box.setStandardButtons(QtWidgets.QDialogButtonBox.Cancel | QtWidgets.QDialogButtonBox.Ok) self.hall = hall self.item = QtWidgets.QLabel(self) self.item.setText("Ime proizvoda") self.item.setGeometry(QtCore.QRect(10, 30, 111, 16)) self.item_name_input = QtWidgets.QComboBox(self) self.item_name_input.setGeometry(QtCore.QRect(200, 20, 110, 22)) self._available_items() self.expiration_date = QtWidgets.QLabel(self) self.expiration_date.setText("Rok upotrebe") self.expiration_date.setGeometry(QtCore.QRect(10, 60, 111, 16)) self.expiration_date_input = QtWidgets.QDateEdit(self) self.expiration_date_input.setGeometry(QtCore.QRect(200, 60, 110, 22)) self.expiration_date_input.setMaximumDate(QtCore.QDate(2090, 12, 31)) self.expiration_date_input.setCalendarPopup(True) self.expiration_date_input.setDate(QtCore.QDate.currentDate()) self.expiration_date_input.setDisplayFormat("dd.MM.yyyy") self.item_count = QtWidgets.QLabel(self) self.item_count.setGeometry(QtCore.QRect(10, 100, 55, 16)) self.item_count.setText("Količina") self.item_count_input = QtWidgets.QSpinBox(self) self.item_count_input.setGeometry(QtCore.QRect(200, 100, 110, 22)) self.item_count_input.setMaximum(self.num_of_places()) self.temperature = QtWidgets.QLabel(self) self.temperature.setGeometry(QtCore.QRect(10, 140, 171, 16)) self.temperature.setText("Temperatura za čuvanje") self.temperature_input = QtWidgets.QSpinBox(self) self.temperature_input.setGeometry(QtCore.QRect(200, 130, 110, 22)) self._set_temperature() self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject) self.new_item = None
def dt_tabela(self, tabela, row, col, data, status): item = QtWidgets.QDateEdit() # item.setGeometry(QtCore.QRect(120, 18, 140, 18)) item.setFixedWidth(90) if status == 1: item.setReadOnly(True) item.setStyleSheet( "QDateEdit {\n" "background: #FFF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 12px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 20px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(down.png);\n" " }\n" "QCalendarWidget QAbstractItemView:enabled \n" " {\n" "border: none;\n" " font-size:13px; \n" " color: #000; \n" " background-color: #F1F1F1; \n" " selection-background-color: rgb(64, 64, 64); \n" " selection-color: rgb(0, 255, 0); \n" " }\n" "QCalendarWidget QToolButton {\n" " border: none;\n" " color: #000\n" " }\n" "\n" " QCalendarWidget QMenu {\n" " width: 150px;\n" " left: 20px;\n" " color: white;\n" " font-size: 18px;\n" " background-color: rgb(100, 100, 100);\n" " }\n" "QCalendarWidget QWidget#qt_calendar_navigationbar\n" "{ \n" "border: none;\n" "}") item.setCalendarPopup(True) item.setDate(data) tabela.setCellWidget(row, col, item)
def __init__(self, parent=None, dodaj=True, proizvod=None): super().__init__(parent) if dodaj: self.setWindowTitle("Dodaj proizvod") self.setWindowIcon(QtGui.QIcon("resources/icons/fruit.png")) else: self.setWindowTitle("Izmeni proizvod") self.setWindowIcon( QtGui.QIcon("resources/icons/fruit-apple-half.png")) self._dodaj = dodaj self._proizvod = proizvod self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.line_edit_naziv = QtWidgets.QLineEdit(self) self.date_edit_rok_upotrebe = QtWidgets.QDateEdit(self) self.spin_box_temperatura = QtWidgets.QSpinBox() self.spin_box_kolicina = QtWidgets.QSpinBox() self.dialog_button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.line_edit_naziv.setMaxLength(14) self.spin_box_kolicina.setMinimum(1) self.spin_box_kolicina.setMaximum(250) self.spin_box_temperatura.setMinimum(-10) self.spin_box_temperatura.setMaximum(25) self.date_edit_rok_upotrebe.setDate(QtCore.QDate.currentDate()) self.date_edit_rok_upotrebe.setMinimumDate(QtCore.QDate.currentDate()) self.date_edit_rok_upotrebe.setCalendarPopup(True) self.date_edit_rok_upotrebe.setDisplayFormat("dd.MM.yyyy") self.date_edit_rok_upotrebe.setMinimumDate(QtCore.QDate.currentDate()) if not dodaj: self.line_edit_naziv.setText(proizvod.naziv) self.date_edit_rok_upotrebe.setDate( QtCore.QDate(int(proizvod.rok_upotrebe[6:]), int(proizvod.rok_upotrebe[3:5]), int(proizvod.rok_upotrebe[:2]))) self.spin_box_temperatura.setValue(proizvod.temperatura) self.spin_box_kolicina.setValue(proizvod.kolicina) self.form_layout.addRow("Naziv:", self.line_edit_naziv) self.form_layout.addRow("Rok upotrebe:", self.date_edit_rok_upotrebe) self.form_layout.addRow("Temperatura:", self.spin_box_temperatura) self.form_layout.addRow("Količina:", self.spin_box_kolicina) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.dialog_button_box) self.dialog_button_box.accepted.connect(self._ok) self.dialog_button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def __init__ (self, parent): super().__init__ (parent) self.setWindowTitle ("Review Config") self.id_label = QtWidgets.QLabel ("商品:", self) self.id = QtWidgets.QComboBox (self) self.id.currentTextChanged.connect (self.idTextChanged) self.month_label = QtWidgets.QLabel ("合約:", self) self.month = QtWidgets.QComboBox (self) self.month.currentTextChanged.connect (self.monthTextChanged) self.start_date_label = QtWidgets.QLabel ("開始日期:", self) self.start_date = QtWidgets.QDateEdit (self) self.start_time_label = QtWidgets.QLabel ("開始時間:", self) self.start_time = QtWidgets.QTimeEdit (self) self.start_time.setDisplayFormat('HH:mm:ss') self.end_date_label = QtWidgets.QLabel ("結束日期:", self) self.end_date = QtWidgets.QDateEdit (self) self.end_time_label = QtWidgets.QLabel ("結束時間:", self) self.end_time = QtWidgets.QTimeEdit (self) self.end_time.setDisplayFormat('HH:mm:ss') self.ok = QtWidgets.QPushButton (self) self.ok.setText ("OK") self.ok.clicked.connect (self.clickedOK) vlay = QtWidgets.QVBoxLayout(self) hlay = QtWidgets.QHBoxLayout() hlay.addWidget (self.id_label) hlay.addWidget (self.id) hlay.addWidget (self.month_label) hlay.addWidget (self.month) vlay.addLayout (hlay) hlay = QtWidgets.QHBoxLayout() hlay.addWidget (self.start_date_label) hlay.addWidget (self.start_date) hlay.addWidget (self.start_time_label) hlay.addWidget (self.start_time) vlay.addLayout (hlay) hlay = QtWidgets.QHBoxLayout() hlay.addWidget (self.end_date_label) hlay.addWidget (self.end_date) hlay.addWidget (self.end_time_label) hlay.addWidget (self.end_time) vlay.addLayout (hlay) vlay.addWidget (self.ok)
def __init__(self, parent=None): """ Inicijalizator dijaloga za dodavanje proizvoda u halu. :param parent: roditeljski widget. :type parent: QWidget """ super().__init__(parent) self._hale = [] self._proizvodi = [] self.setWindowTitle("Dodaj proizvod") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.proizvod_input = QtWidgets.QComboBox(self) self.get_all_proizvodi() for p in self._proizvodi: self.proizvod_input.addItem(p[0]) self.quantity_input = QtWidgets.QSpinBox(self) self.hala_input = QtWidgets.QComboBox(self) self.get_all_hale() for h in self._hale: icon = None if(h[1]=="Sobna temperatura"): icon = "resources/icons/sun.png" elif(h[1]=="Rashladna"): icon = "resources/icons/fan.png" else: icon = "resources/icons/weather-snowflake.png" self.hala_input.addItem(QtGui.QIcon(icon), h[0]) self.date_input = QtWidgets.QDateEdit(self) self.button_box = QtWidgets.QDialogButtonBox(QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.quantity_input.setMinimum(1) self.quantity_input.setMaximum(999999) self.quantity_input.setSingleStep(1) self.date_input.setDate(QtCore.QDate.currentDate()) self.date_input.setCalendarPopup(True) self.form_layout.addRow("Proizvod:", self.proizvod_input) self.form_layout.addRow("Kolicina:", self.quantity_input) self.form_layout.addRow("Hala:", self.hala_input) self.form_layout.addRow("Datum isteka roka:", self.date_input) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self.accept) self.button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def __init__(self, parent=None): super(MeterDialog, self).__init__(parent) layout = QtWidgets.QVBoxLayout(self) # nice widget for editing the date # self.datetime = QtWidgets.QDateTimeEdit(self) self.datetime = QtWidgets.QDateEdit(self) self.datetime.setCalendarPopup(True) self.datetime.setDateTime(QDateTime.currentDateTime()) layout.addWidget(self.datetime) # Meter type - selector meterTypeLabel = QtWidgets.QLabel("Zähler") layout.addWidget(meterTypeLabel) self.meterTypeWidget = QtWidgets.QWidget(self) self.miniLayout = QtWidgets.QHBoxLayout(self.meterTypeWidget) self.meterTypeGrp = QtWidgets.QButtonGroup() self.electricity = QtWidgets.QCheckBox('Strom') self.electricity.setCheckState(Qt.CheckState.Checked) self.meterTypeGrp.addButton(self.electricity, 0) self.miniLayout.addWidget(self.electricity) self.gas = QtWidgets.QCheckBox('Gas') self.meterTypeGrp.addButton(self.gas, 1) self.miniLayout.addWidget(self.gas) self.water = QtWidgets.QCheckBox('Wasser') self.meterTypeGrp.addButton(self.water, 2) self.miniLayout.addWidget(self.water) layout.addWidget(self.meterTypeWidget) # level lvlLabel = QtWidgets.QLabel('Zählerstand') layout.addWidget(lvlLabel) self.lvlSpinBox = QtWidgets.QDoubleSpinBox() self.lvlSpinBox.setRange(0, 1000000) self.lvlSpinBox.setDecimals(3) # self.lvlSpinBox.setSuffix(' m^2') self.lvlSpinBox.setValue(0) layout.addWidget(self.lvlSpinBox) # OK and Cancel buttons self.buttons = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, Qt.Horizontal, self) layout.addWidget(self.buttons) ## SIGNALS/SLOTS ## self.buttons.accepted.connect(self.accept) self.buttons.rejected.connect(self.reject)
def __init__(self, parent, database_manager): QtWidgets.QWidget.__init__(self, parent) config = configparser.ConfigParser() path = os.path.expanduser('~/Documents/JAM/JAMviewer/jam.ini') config.read(path) self.database_manager = database_manager self.scheduler = BackgroundScheduler() jam_dur = config.getint('Network', 'interval') self.schedule_jam(interval=jam_dur) self.table_model = QtGui.QStandardItemModel(3, 10) self.table_view = QtWidgets.QTableView() self.table_view.setModel(self.table_model) self.table_view.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.table_view.setAlternatingRowColors(True) v_header = self.table_view.verticalHeader() v_header.hide() hbox = QtWidgets.QHBoxLayout() date_label = QtWidgets.QLabel('Date: ') self.date_spin = QtWidgets.QDateEdit() self.date_spin.setDate(QtCore.QDate.currentDate()) start_label = QtWidgets.QLabel('Start: ') self.start_spin = QtWidgets.QTimeEdit(QtCore.QTime(7, 0)) self.start_spin.setDisplayFormat('HH:mm') hour_label = QtWidgets.QLabel('Hours: ') self.hour_spin = QtWidgets.QSpinBox() self.hour_spin.setMinimum(1) self.hour_spin.setMaximum(24) self.hour_spin.setValue(12) populate_btn = QtWidgets.QPushButton('Refresh') populate_btn.clicked.connect(self.populate_table) hbox.addWidget(date_label) hbox.addWidget(self.date_spin) hbox.addWidget(start_label) hbox.addWidget(self.start_spin) hbox.addWidget(hour_label) hbox.addWidget(self.hour_spin) hbox.addWidget(populate_btn) box_layout = QtWidgets.QVBoxLayout() box_layout.addLayout(hbox) box_layout.addWidget(self.table_view) self.setLayout(box_layout) self.show() self.populate_table() self.scheduler.start()
def germanDatePicker(selected: QDate) -> qw.QDateEdit: picker = qw.QDateEdit() picker.setDisplayFormat(pp("dd.MM.yyyy")) picker.setLocale(QLocale.German) picker.setCalendarPopup(True) calendar = picker.calendarWidget() calendar.setGridVisible(False) calendar.setFirstDayOfWeek(Qt.Monday) calendar.setHorizontalHeaderFormat( qw.QCalendarWidget.HorizontalHeaderFormat.SingleLetterDayNames) calendar.setVerticalHeaderFormat(qw.QCalendarWidget.ISOWeekNumbers) picker.setDate(selected) return picker
def __init__(self, parent=None, selected_date=None, path=None): super().__init__(parent) self.path = path self.setWindowTitle("Add event") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.name_input = QtWidgets.QLineEdit(self) self.desc_input = QtWidgets.QTextEdit(self) self.desc_input.setTabChangesFocus(True) self.selected_date = selected_date self.date_input = QtWidgets.QDateEdit(self) self.date_input.setDisplayFormat('d.M.yyyy.') if self.selected_date != None: self.date_input.setDate(selected_date) self.iterator_input = QtWidgets.QComboBox() self.iterator_input.setStyleSheet('background: white;') self.iterator_input.addItem('One time') self.iterator_input.addItem('Daily') self.iterator_input.addItem('Weekly') self.iterator_input.addItem('Monthly') self.iterator_input.addItem('Annualy') self.form_layout.addRow('Name: ', self.name_input) self.form_layout.addRow('Description: ', self.desc_input) self.form_layout.addRow('Date: ', self.date_input) self.form_layout.addRow('Frequency: ', self.iterator_input) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject) children = self.vbox_layout.children() self.setStyleSheet('font: 15px') self.setLayout(self.vbox_layout)
def __init__(self, parent, database_manager): QtWidgets.QWidget.__init__(self, parent) config = configparser.ConfigParser() path = os.path.expanduser('~/Documents/JAM/JAMviewer/jam.ini') config.read(path) self.database_manager = database_manager self.sfu_model = QtGui.QStandardItemModel(3, 10) self.sfu_treeview = QtWidgets.QTreeView(self) self.sfu_treeview.setModel(self.sfu_model) self.sfu_treeview.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.sfu_treeview.setAlternatingRowColors(True) self.sfu_treeview.setRootIsDecorated(False) self.sfu_treeview.setSortingEnabled(True) header = self.sfu_treeview.header() header.setStretchLastSection(False) header.setSectionResizeMode(QtWidgets.QHeaderView.Stretch) hbox = QtWidgets.QHBoxLayout() date_label = QtWidgets.QLabel('Date: ') self.date_spin = QtWidgets.QDateEdit() self.date_spin.setDate(QtCore.QDate.currentDate()) start_label = QtWidgets.QLabel('Start time: ') self.start_spin = QtWidgets.QTimeEdit(QtCore.QTime(7, 0)) self.start_spin.setDisplayFormat('HH:mm') hour_label = QtWidgets.QLabel('End time: ') self.end_spin = QtWidgets.QTimeEdit(QtCore.QTime(19, 0)) self.end_spin.setDisplayFormat('HH:mm') refresh_btn = QtWidgets.QPushButton('Refresh') refresh_btn.clicked.connect(self.populate_table) hbox.addWidget(date_label) hbox.addWidget(self.date_spin) hbox.addWidget(start_label) hbox.addWidget(self.start_spin) hbox.addWidget(hour_label) hbox.addWidget(self.end_spin) hbox.addWidget(refresh_btn) box_layout = QtWidgets.QVBoxLayout() box_layout.addLayout(hbox) box_layout.addWidget(self.sfu_treeview) self.setLayout(box_layout) self.show() self.populate_table()
def __init__(self, parent=None): """ Inicijalizator dijaloga za dodavanje novog kontakta u imenik. :param parent: roditeljski widget. :type parent: QWidget """ super().__init__(parent) self.setWindowTitle("Dodaj kontakt") self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.name_input = QtWidgets.QLineEdit(self) self.surname_input = QtWidgets.QLineEdit(self) self.phone_input = QtWidgets.QLineEdit(self) self.email_input = QtWidgets.QLineEdit(self) self.birthday_input = QtWidgets.QDateEdit(self) self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) self.email_re = QtCore.QRegExp( r"(^[a-zA-Z0-9_.+-]+@[a-zA-Z0-9-]+\.[a-zA-Z0-9-.]+$)", QtCore.Qt.CaseInsensitive) self.email_validator = QtGui.QRegExpValidator(self.email_re) self.email_input.setValidator(self.email_validator) self.email_input.textChanged.connect(self.adjust_text_color) self.birthday_input.setDate(QtCore.QDate.currentDate()) self.birthday_input.setCalendarPopup(True) self.form_layout.addRow("Ime:", self.name_input) self.form_layout.addRow("Prezime:", self.surname_input) self.form_layout.addRow("Telefon:", self.phone_input) self.form_layout.addRow("Email:", self.email_input) self.form_layout.addRow("Datum rodjenja:", self.birthday_input) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def setupUi(self, MainWindow): MainWindow.setObjectName("MainWindow") MainWindow.resize(800, 600) self.centralwidget = QtWidgets.QWidget(MainWindow) self.centralwidget.setObjectName("centralwidget") self.pushButton = QtWidgets.QPushButton(self.centralwidget) self.pushButton.setGeometry(QtCore.QRect(450, 360, 331, 191)) self.pushButton.setObjectName("pushButton") self.timeEdit = QtWidgets.QTimeEdit(self.centralwidget) self.timeEdit.setGeometry(QtCore.QRect(180, 490, 118, 24)) self.timeEdit.setObjectName("timeEdit") self.dateEdit = QtWidgets.QDateEdit(self.centralwidget) self.dateEdit.setGeometry(QtCore.QRect(40, 490, 110, 24)) self.dateEdit.setObjectName("dateEdit") self.label = QtWidgets.QLabel(self.centralwidget) self.label.setGeometry(QtCore.QRect(60, 0, 91, 41)) self.label.setObjectName("label") self.dial = QtWidgets.QDial(self.centralwidget) self.dial.setGeometry(QtCore.QRect(610, 220, 161, 151)) self.dial.setObjectName("dial") self.horizontalSlider = QtWidgets.QSlider(self.centralwidget) self.horizontalSlider.setGeometry(QtCore.QRect(300, 510, 160, 22)) self.horizontalSlider.setSliderPosition(50) self.horizontalSlider.setOrientation(QtCore.Qt.Horizontal) self.horizontalSlider.setTickInterval(6) self.horizontalSlider.setObjectName("horizontalSlider") self.calendarWidget = QtWidgets.QCalendarWidget(self.centralwidget) self.calendarWidget.setGeometry(QtCore.QRect(460, 0, 296, 173)) self.calendarWidget.setObjectName("calendarWidget") self.tableView = QtWidgets.QTableView(self.centralwidget) self.tableView.setGeometry(QtCore.QRect(40, 50, 391, 401)) self.tableView.setObjectName("tableView") MainWindow.setCentralWidget(self.centralwidget) self.menubar = QtWidgets.QMenuBar() self.menubar.setGeometry(QtCore.QRect(0, 0, 800, 22)) self.menubar.setObjectName("menubar") MainWindow.setMenuBar(self.menubar) self.statusbar = QtWidgets.QStatusBar(MainWindow) self.statusbar.setObjectName("statusbar") MainWindow.setStatusBar(self.statusbar) self.retranslateUi(MainWindow) QtCore.QMetaObject.connectSlotsByName(MainWindow)
def setupUi(self, Dialog): Dialog.setObjectName("Dialog") Dialog.resize(303, 131) self.gridLayout = QtWidgets.QGridLayout(Dialog) self.gridLayout.setObjectName("gridLayout") self.label_3 = QtWidgets.QLabel(Dialog) self.label_3.setObjectName("label_3") self.gridLayout.addWidget(self.label_3, 2, 0, 1, 1) self.comboBox = QtWidgets.QComboBox(Dialog) self.comboBox.setObjectName("comboBox") self.gridLayout.addWidget(self.comboBox, 1, 0, 1, 1) self.label_2 = QtWidgets.QLabel(Dialog) self.label_2.setObjectName("label_2") self.gridLayout.addWidget(self.label_2, 0, 1, 1, 1) self.comboBox_2 = QtWidgets.QComboBox(Dialog) self.comboBox_2.setObjectName("comboBox_2") self.gridLayout.addWidget(self.comboBox_2, 1, 1, 1, 1) self.label = QtWidgets.QLabel(Dialog) self.label.setObjectName("label") self.gridLayout.addWidget(self.label, 0, 0, 1, 1) self.label_4 = QtWidgets.QLabel(Dialog) self.label_4.setObjectName("label_4") self.gridLayout.addWidget(self.label_4, 2, 1, 1, 1) self.lineEdit = QtWidgets.QLineEdit(Dialog) self.lineEdit.setObjectName("lineEdit") self.gridLayout.addWidget(self.lineEdit, 3, 0, 1, 1) self.pushButton = QtWidgets.QPushButton(Dialog) self.pushButton.setObjectName("pushButton") self.gridLayout.addWidget(self.pushButton, 5, 1, 1, 1) self.dateEdit = QtWidgets.QDateEdit(Dialog) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth(self.dateEdit.sizePolicy().hasHeightForWidth()) self.dateEdit.setSizePolicy(sizePolicy) self.dateEdit.setObjectName("dateEdit") self.gridLayout.addWidget(self.dateEdit, 3, 1, 1, 1) self.retranslateUi(Dialog) QtCore.QMetaObject.connectSlotsByName(Dialog)
def __init__(self, parent=None, selected_date=None, model=None, path=None): super().__init__(parent) self.setWindowTitle("Delete event") self.resize(550, 400) self.path = path self.events = model._data self.model = model self.vbox_layout = QtWidgets.QVBoxLayout() self.form_layout = QtWidgets.QFormLayout() self.button_box = QtWidgets.QDialogButtonBox( QtWidgets.QDialogButtonBox.Ok | QtWidgets.QDialogButtonBox.Cancel, parent=self) # self.selected_date = selected_date self.date_input = QtWidgets.QDateEdit(self) self.date_input.setDisplayFormat('d.M.yyyy.') if selected_date != None: self.date_input.setDate(selected_date) self.table_view = QtWidgets.QTableView(self) self.table_view.setSelectionBehavior( QtWidgets.QAbstractItemView.SelectionBehavior.SelectRows) self.table_view.setModel(model) self.form_layout.addRow(self.date_input) self.vbox_layout.addWidget(self.table_view) self.vbox_layout.addLayout(self.form_layout) self.vbox_layout.addWidget(self.button_box) self.button_box.accepted.connect(self._on_accept) self.button_box.rejected.connect(self.reject) self.setLayout(self.vbox_layout)
def __init__(self): QtWidgets.QWidget.__init__(self) self.table_model = QtGui.QStandardItemModel(3, 10) self.table_view = QtWidgets.QTableView() self.table_view.setModel(self.table_model) self.table_view.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.table_view.setAlternatingRowColors(True) v_header = self.table_view.verticalHeader() v_header.hide() hbox = QtWidgets.QHBoxLayout() date_label = QtWidgets.QLabel('Date: ') self.date_spin = QtWidgets.QDateEdit() self.date_spin.setDate(QtCore.QDate.currentDate()) start_label = QtWidgets.QLabel('Start: ') self.start_spin = QtWidgets.QTimeEdit(QtCore.QTime(7, 0)) self.start_spin.setDisplayFormat('HH:mm') hour_label = QtWidgets.QLabel('Hours: ') self.hour_spin = QtWidgets.QSpinBox() self.hour_spin.setMinimum(1) self.hour_spin.setMaximum(24) populate_btn = QtWidgets.QPushButton('Refresh') populate_btn.clicked.connect(self.populate_table) hbox.addWidget(date_label) hbox.addWidget(self.date_spin) hbox.addWidget(start_label) hbox.addWidget(self.start_spin) hbox.addWidget(hour_label) hbox.addWidget(self.hour_spin) hbox.addWidget(populate_btn) box_layout = QtWidgets.QVBoxLayout() box_layout.addLayout(hbox) box_layout.addWidget(self.table_view) self.setLayout(box_layout) self.show()
def setupUi(self, Form): Form.setObjectName("Form") Form.resize(500, 470) self.verticalLayoutWidget = QtWidgets.QWidget(Form) self.verticalLayoutWidget.setGeometry(QtCore.QRect(30, 30, 431, 381)) self.verticalLayoutWidget.setObjectName("verticalLayoutWidget") self.verticalLayout = QtWidgets.QVBoxLayout(self.verticalLayoutWidget) self.verticalLayout.setContentsMargins(0, 0, 0, 0) self.verticalLayout.setObjectName("verticalLayout") self.horizontalLayout = QtWidgets.QHBoxLayout() self.horizontalLayout.setObjectName("horizontalLayout") self.dateEdit = QtWidgets.QDateEdit(self.verticalLayoutWidget) self.dateEdit.setObjectName("dateEdit") self.horizontalLayout.addWidget(self.dateEdit) self.OK_Button = QtWidgets.QPushButton(self.verticalLayoutWidget) self.OK_Button.setObjectName("OK_Button") self.horizontalLayout.addWidget(self.OK_Button) self.Reset_Button = QtWidgets.QPushButton(self.verticalLayoutWidget) self.Reset_Button.setObjectName("Reset_Button") self.horizontalLayout.addWidget(self.Reset_Button) self.verticalLayout.addLayout(self.horizontalLayout) self.horizontalLayout_2 = QtWidgets.QHBoxLayout() self.horizontalLayout_2.setObjectName("horizontalLayout_2") self.Prev_Button = QtWidgets.QPushButton(self.verticalLayoutWidget) self.Prev_Button.setObjectName("Prev_Button") self.horizontalLayout_2.addWidget(self.Prev_Button) self.Next_Button = QtWidgets.QPushButton(self.verticalLayoutWidget) self.Next_Button.setObjectName("Next_Button") self.horizontalLayout_2.addWidget(self.Next_Button) self.verticalLayout.addLayout(self.horizontalLayout_2) self.listWidget = QtWidgets.QListWidget(self.verticalLayoutWidget) self.listWidget.setObjectName("listWidget") self.verticalLayout.addWidget(self.listWidget) self.retranslateUi(Form) QtCore.QMetaObject.connectSlotsByName(Form)
def __init__(self, current_project): super().__init__() self.current_project = current_project self.selected_card = "" self.current_day_edited = 0 # menu menu = self.menuBar() menu.setNativeMenuBar(False) file_menu = menu.addMenu("Rapport") load_action = QtWidgets.QAction("ouvrir un rapport", self) load_action.triggered.connect(self.open_report) save_action = QtWidgets.QAction("Sauvegarder le rapport", self) save_action.triggered.connect(self.save_report) file_menu.addAction(load_action) file_menu.addAction(save_action) #Window setup self.setWindowTitle("La Ruche QCReport") # LAYOUT ################## LAYOUT #Layouts creation and setup self.main_layout = QtWidgets.QGridLayout() self.side_layout = QtWidgets.QVBoxLayout() self.day_header_layout = QtWidgets.QGridLayout() self.day_header_layout.setSpacing(0) ###HEADER############################################ #DAY HEADER WIDEGTS CREATION and assignment self.lab_shooting_day_number_title = QtWidgets.QLabel('Jour') self.lab_shooting_day_number = QtWidgets.QLabel( f"{self.current_day_edited} : {self.current_project.get_shooting_date_string_from_number(self.current_day_edited)}" ) self.lab_shooting_day_number.setStyleSheet( "font-size: 40px; color:DarkSlateGray; font-style: bold") self.lab_clip_number = QtWidgets.QLabel() self.lab_clip_number.setStyleSheet("font-size: 20px;") self.te_day_comment = QtWidgets.QPlainTextEdit() self.te_day_comment.setPlaceholderText("Commentaire de la journée.") self.te_day_comment.setMaximumWidth(300) self.te_day_comment.setMaximumHeight(80) self.te_day_comment.cursorPositionChanged.connect(self.set_day_comment) #### A REPARER self.lw_framerate_list = QtWidgets.QListWidget() self.lw_framerate_list.setMaximumSize(100, 80) self.lw_codec_list = QtWidgets.QListWidget() self.lw_codec_list.setMaximumSize(150, 80) self.lw_cards_list = QtWidgets.QListWidget() self.lw_cards_list.setMaximumSize(100, 80) self.lab_codec = QtWidgets.QLabel("Codec detectés") self.lab_codec.setStyleSheet("font-size: 10px;") self.lab_framerates = QtWidgets.QLabel("Cadences detectées") self.lab_framerates.setStyleSheet("font-size: 10px;") self.lab_cards = QtWidgets.QLabel("Cartes") self.lab_cards.setStyleSheet("font-size: 10px;") self.day_header_layout.addWidget(self.lab_shooting_day_number, 0, 0, 1, 1) self.day_header_layout.addWidget(self.lab_clip_number, 1, 0, 1, 1) self.day_header_layout.addWidget(self.te_day_comment, 2, 0, 1, 1) self.day_header_layout.addWidget(self.lab_framerates, 1, 2, 1, 1) self.day_header_layout.addWidget(self.lw_framerate_list, 2, 2, 1, 1) self.day_header_layout.addWidget(self.lab_codec, 1, 3, 1, 1) self.day_header_layout.addWidget(self.lw_codec_list, 2, 3, 1, 1) self.day_header_layout.addWidget(self.lab_cards, 1, 4, 1, 1) self.day_header_layout.addWidget(self.lw_cards_list, 2, 4, 1, 1) # HEADER END ### CLIP LIST # set scrollable area self.lab_scroll = QtWidgets.QLabel("") self.clips_layout = QtWidgets.QVBoxLayout(self) self.scrollable_area = QtWidgets.QScrollArea(self) self.placeholder_widget = QtWidgets.QWidget(self) self.placeholder_widget.setLayout(self.clips_layout) self.scrollable_area.setVerticalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOn) self.scrollable_area.setHorizontalScrollBarPolicy( QtCore.Qt.ScrollBarAlwaysOff) self.scrollable_area.setWidgetResizable(True) self.scrollable_area.setWidget(self.placeholder_widget) self.scrollable_area.setFrameStyle(QtWidgets.QFrame.StyledPanel | QtWidgets.QFrame.Sunken) # Assigning widgets #self.side_layout.addWidget(self.lab_side) self.clips_layout.addWidget(self.lab_scroll) # Side widgets #labels self.side_lab_title = QtWidgets.QLabel("Titre du film:") self.side_lab_director = QtWidgets.QLabel("Mise en scène:") self.side_lab_production = QtWidgets.QLabel("Production:") self.side_lab_cinematographer = QtWidgets.QLabel("Chef opérateur:") self.side_lab_verification_date = QtWidgets.QLabel( "Date de vérification:") #Line edits self.side_le_title = QtWidgets.QLineEdit( self.current_project.film_title) self.side_le_director = QtWidgets.QLineEdit( self.current_project.director) self.side_le_production = QtWidgets.QLineEdit( self.current_project.production) self.side_le_cinematographer = QtWidgets.QLineEdit( self.current_project.cinematographer) self.side_le_verification_date = QtWidgets.QDateEdit( QtCore.QDate(self.current_project.qc_date.get("year"), self.current_project.qc_date.get("month"), self.current_project.qc_date.get("day"))) self.side_le_verification_date.setCalendarPopup(True) # Side connectipns self.side_le_title.textChanged.connect(self.set_title) self.side_le_director.textChanged.connect(self.set_director) self.side_le_production.textChanged.connect(self.set_production) self.side_le_cinematographer.textChanged.connect( self.set_cinematographer) self.side_le_verification_date.userDateChanged.connect( self.set_verification_date) # Adding widgets self.side_layout.addWidget(self.side_lab_title) self.side_layout.addWidget(self.side_le_title) self.side_layout.addWidget(self.side_lab_director) self.side_layout.addWidget(self.side_le_director) self.side_layout.addWidget(self.side_lab_production) self.side_layout.addWidget(self.side_le_production) self.side_layout.addWidget(self.side_lab_cinematographer) self.side_layout.addWidget(self.side_le_cinematographer) self.side_layout.addWidget(self.side_lab_verification_date) self.side_layout.addWidget(self.side_le_verification_date) self.side_layout.addWidget(QtWidgets.QLabel("Jours de tournage")) self.day_list = QtWidgets.QListWidget() self.day_list.itemSelectionChanged.connect(self.change_day) self.side_layout.addWidget(self.day_list) self.populate_day_list() # self.side_layout.addWidget(QtWidgets.QPushButton("Manage Report")) # self.side_layout.addWidget(QtWidgets.QPushButton("Save Report")) # self.side_layout.addWidget(QtWidgets.QPushButton("Export Report")) ###DEBUG self.debug = QtWidgets.QPushButton("Debug") self.side_layout.addWidget(self.debug) self.debug.clicked.connect(self.current_project.export_report) # LAYOUTS HIERARCHY self.main_layout.addLayout(self.side_layout, 0, 0, 8, 2) self.main_layout.addLayout(self.day_header_layout, 0, 2, 2, 8) self.main_layout.addWidget(self.scrollable_area, 2, 2, 6, 8) self.widget = QtWidgets.QWidget() self.widget.setLayout(self.main_layout) self.setCentralWidget(self.widget) self.resize(1200, 800)
def setFormAPagar(self, ct_FormPagar): ct_FormPagar.setObjectName("ct_FormPagar") ct_FormPagar.resize(1000, 500) self.fr_FormPagar = QtWidgets.QFrame(ct_FormPagar) self.fr_FormPagar.setGeometry(QtCore.QRect(0, 0, 1000, 500)) self.fr_FormPagar.setStyleSheet("background: #FFF;\n" "border: none") self.fr_FormPagar.setFrameShape(QtWidgets.QFrame.StyledPanel) self.fr_FormPagar.setFrameShadow(QtWidgets.QFrame.Raised) self.fr_FormPagar.setObjectName("fr_FormPagar") self.lb_FormProdutos = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormProdutos.setGeometry(QtCore.QRect(100, 10, 880, 30)) self.lb_FormProdutos.setStyleSheet("QLabel{\n" "font-size: 14px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "\n" "border-bottom: 2px solid #A2A2A2\n" "}") self.lb_FormProdutos.setObjectName("lb_FormProdutos") self.tx_Cod = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_Cod.setEnabled(False) self.tx_Cod.setGeometry(QtCore.QRect(20, 10, 50, 30)) self.tx_Cod.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border: 1px solid #A2A2A2;\n" "color: #000;\n" "font-size: 14px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "\n" "}") self.tx_Cod.setText("") self.tx_Cod.setAlignment(QtCore.Qt.AlignCenter) self.tx_Cod.setObjectName("tx_Cod") self.lb_FormCompra_5 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_5.setGeometry(QtCore.QRect(510, 60, 110, 20)) self.lb_FormCompra_5.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_5.setObjectName("lb_FormCompra_5") self.tx_Id = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_Id.setGeometry(QtCore.QRect(20, 80, 100, 30)) self.tx_Id.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_Id.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_Id.setAlignment(QtCore.Qt.AlignCenter) self.tx_Id.setObjectName("tx_Id") self.lb_FormCompra_2 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_2.setGeometry(QtCore.QRect(140, 60, 120, 20)) self.lb_FormCompra_2.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_2.setObjectName("lb_FormCompra_2") self.tx_NomeFantasia = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_NomeFantasia.setGeometry(QtCore.QRect(140, 80, 350, 30)) self.tx_NomeFantasia.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_NomeFantasia.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_NomeFantasia.setObjectName("tx_NomeFantasia") self.lb_FormCompra_3 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_3.setGeometry(QtCore.QRect(20, 60, 100, 20)) self.lb_FormCompra_3.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_3.setObjectName("lb_FormCompra_3") self.tx_Telefone = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_Telefone.setGeometry(QtCore.QRect(510, 80, 110, 30)) self.tx_Telefone.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_Telefone.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_Telefone.setReadOnly(True) self.tx_Telefone.setObjectName("tx_Telefone") self.tx_descricao = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_descricao.setGeometry(QtCore.QRect(20, 140, 600, 30)) self.tx_descricao.setMouseTracking(True) self.tx_descricao.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_descricao.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_descricao.setText("") self.tx_descricao.setFrame(False) self.tx_descricao.setCursorPosition(0) self.tx_descricao.setAlignment(QtCore.Qt.AlignLeading | QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter) self.tx_descricao.setReadOnly(False) self.tx_descricao.setObjectName("tx_descricao") self.lb_FormCompra_4 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_4.setGeometry(QtCore.QRect(20, 120, 120, 20)) self.lb_FormCompra_4.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_4.setObjectName("lb_FormCompra_4") self.lb_FormCompra_6 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_6.setGeometry(QtCore.QRect(20, 180, 120, 20)) self.lb_FormCompra_6.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_6.setObjectName("lb_FormCompra_6") self.cb_categoria = QtWidgets.QComboBox(self.fr_FormPagar) self.cb_categoria.setGeometry(QtCore.QRect(20, 200, 180, 30)) self.cb_categoria.setStyleSheet( "QComboBox{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QComboBox:Focus {\n" "border: 1px solid red;\n" "}\n" " QComboBox::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QComboBox::down-arrow {\n" " image: url(Images/down.png);\n" " }\n" "") self.cb_categoria.setObjectName("cb_categoria") self.bt_AddCategoriaProduto = QtWidgets.QPushButton(self.fr_FormPagar) self.bt_AddCategoriaProduto.setGeometry(QtCore.QRect(200, 200, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") font.setPointSize(16) font.setWeight(75) font.setBold(True) self.bt_AddCategoriaProduto.setFont(font) self.bt_AddCategoriaProduto.setStyleSheet("QPushButton{\n" "background: #7AB32E;\n" "color: #FFF\n" "}\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_AddCategoriaProduto.setText("") self.bt_AddCategoriaProduto.setObjectName("bt_AddCategoriaProduto") self.bt_CancelAddCatergoria = QtWidgets.QPushButton(self.fr_FormPagar) self.bt_CancelAddCatergoria.setGeometry(QtCore.QRect(200, 200, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") font.setPointSize(16) font.setWeight(75) font.setBold(True) self.bt_CancelAddCatergoria.setFont(font) self.bt_CancelAddCatergoria.setStyleSheet("QPushButton{\n" "background: #FAB32E;\n" "color: #FFF\n" "}\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_CancelAddCatergoria.setText("") self.bt_CancelAddCatergoria.setObjectName("bt_CancelAddCatergoria") self.dt_Vencimento = QtWidgets.QDateEdit(self.fr_FormPagar) self.dt_Vencimento.setGeometry(QtCore.QRect(250, 200, 120, 30)) self.dt_Vencimento.setStyleSheet( "QDateEdit {\n" "background: #CFCFCF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 16px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(Images/down.png);\n" " }\n" "\n" "QCalendarWidget QAbstractItemView:enabled \n" " {\n" "border: none;\n" " font-size:13px; \n" " color: #000; \n" " background-color: #F1F1F1; \n" " selection-background-color: rgb(64, 64, 64); \n" " selection-color: rgb(0, 255, 0); \n" " }\n" "QCalendarWidget QToolButton {\n" " border: none;\n" " color: #000\n" " }\n" "\n" " QCalendarWidget QMenu {\n" " width: 150px;\n" " left: 20px;\n" " color: white;\n" " font-size: 18px;\n" " background-color: rgb(100, 100, 100);\n" " }\n" "QCalendarWidget QWidget#qt_calendar_navigationbar\n" "{ \n" "border: none;\n" "}") self.dt_Vencimento.setCalendarPopup(True) self.dt_Vencimento.setObjectName("dt_Vencimento") self.lb_FormCompra_7 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_7.setGeometry(QtCore.QRect(250, 180, 120, 20)) self.lb_FormCompra_7.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_7.setObjectName("lb_FormCompra_7") self.tx_Obs = QtWidgets.QTextEdit(self.fr_FormPagar) self.tx_Obs.setGeometry(QtCore.QRect(20, 260, 600, 160)) self.tx_Obs.setStyleSheet("QTextEdit{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QTextEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_Obs.setObjectName("tx_Obs") self.lb_FormCompra_8 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_8.setGeometry(QtCore.QRect(20, 240, 120, 20)) self.lb_FormCompra_8.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_8.setObjectName("lb_FormCompra_8") self.fr_financeiroCompra = QtWidgets.QFrame(self.fr_FormPagar) self.fr_financeiroCompra.setGeometry(QtCore.QRect(640, 60, 340, 360)) self.fr_financeiroCompra.setStyleSheet( "background: #F1F1F1;\n" "border-top: 4px solid #277298;\n" "border-bottom: 4px solid #277298;") self.fr_financeiroCompra.setFrameShape(QtWidgets.QFrame.StyledPanel) self.fr_financeiroCompra.setFrameShadow(QtWidgets.QFrame.Raised) self.fr_financeiroCompra.setObjectName("fr_financeiroCompra") self.lb_FormVenda_14 = QtWidgets.QLabel(self.fr_financeiroCompra) self.lb_FormVenda_14.setGeometry(QtCore.QRect(20, 20, 130, 30)) self.lb_FormVenda_14.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #277298;\n" "border: none\n" "}") self.lb_FormVenda_14.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.lb_FormVenda_14.setObjectName("lb_FormVenda_14") self.dt_dataPagamento = QtWidgets.QDateEdit(self.fr_financeiroCompra) self.dt_dataPagamento.setGeometry(QtCore.QRect(160, 20, 150, 30)) self.dt_dataPagamento.setStyleSheet( "QDateEdit {\n" "background: #FFF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 14px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(Images/down.png);\n" " }\n" "\n" "QCalendarWidget QAbstractItemView:enabled \n" " {\n" "border: none;\n" " font-size:13px; \n" " color: #000; \n" " background-color: #F1F1F1; \n" " selection-background-color: rgb(64, 64, 64); \n" " selection-color: rgb(0, 255, 0); \n" " }\n" "QCalendarWidget QToolButton {\n" " border: none;\n" " color: #000\n" " }\n" "\n" " QCalendarWidget QMenu {\n" " width: 150px;\n" " left: 20px;\n" " color: white;\n" " font-size: 18px;\n" " background-color: rgb(100, 100, 100);\n" " }\n" "QCalendarWidget QWidget#qt_calendar_navigationbar\n" "{ \n" "border: none;\n" "}") self.dt_dataPagamento.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.dt_dataPagamento.setCalendarPopup(True) self.dt_dataPagamento.setObjectName("dt_dataPagamento") self.lb_FormVenda_22 = QtWidgets.QLabel(self.fr_financeiroCompra) self.lb_FormVenda_22.setGeometry(QtCore.QRect(20, 320, 130, 30)) self.lb_FormVenda_22.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #277298;\n" "border: none\n" "}") self.lb_FormVenda_22.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.lb_FormVenda_22.setObjectName("lb_FormVenda_22") self.lb_ValorPendente = QtWidgets.QLabel(self.fr_financeiroCompra) self.lb_ValorPendente.setGeometry(QtCore.QRect(160, 320, 125, 30)) self.lb_ValorPendente.setStyleSheet("QLabel{\n" "font-size: 20px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #277298;\n" "border: none\n" "}") self.lb_ValorPendente.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.lb_ValorPendente.setObjectName("lb_ValorPendente") self.tx_valorPago = QtWidgets.QLineEdit(self.fr_financeiroCompra) self.tx_valorPago.setGeometry(QtCore.QRect(160, 100, 125, 30)) self.tx_valorPago.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_valorPago.setStyleSheet("QLineEdit{\n" "background: #FFF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 14px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_valorPago.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.tx_valorPago.setObjectName("tx_valorPago") self.lb_FormVenda_27 = QtWidgets.QLabel(self.fr_financeiroCompra) self.lb_FormVenda_27.setGeometry(QtCore.QRect(20, 60, 130, 30)) self.lb_FormVenda_27.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #277298;\n" "border: none\n" "}") self.lb_FormVenda_27.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.lb_FormVenda_27.setObjectName("lb_FormVenda_27") self.cb_formaPagamento = QtWidgets.QComboBox(self.fr_financeiroCompra) self.cb_formaPagamento.setGeometry(QtCore.QRect(160, 60, 150, 30)) self.cb_formaPagamento.setStyleSheet( "QComboBox{\n" "background: #FFF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 14px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "\n" "}\n" "QCombobox:on {\n" "color: #000;\n" "font: 10px \"Arial\" ;\n" "text-transform: uppercase;\n" "font-weight: bold;\n" "}\n" "QComboBox:Focus {\n" "border: 1px solid red;\n" "}\n" " QComboBox::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" "\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" "\n" " }\n" "QComboBox::down-arrow {\n" " image: url(down.png);\n" " }\n" "QComboBox QAbstractItemView {\n" " border: 1px solid darkgray;\n" " selection-background-color: #40a286;\n" "color: #000;\n" "font: 10px \"Arial\" ;\n" "text-transform: uppercase;\n" "font-weight: bold;\n" "}\n" "") self.cb_formaPagamento.setObjectName("cb_formaPagamento") self.lb_FormVenda_28 = QtWidgets.QLabel(self.fr_financeiroCompra) self.lb_FormVenda_28.setGeometry(QtCore.QRect(20, 100, 130, 30)) self.lb_FormVenda_28.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #277298;\n" "border: none\n" "}") self.lb_FormVenda_28.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.lb_FormVenda_28.setObjectName("lb_FormVenda_28") self.bt_receber = QtWidgets.QPushButton(self.fr_financeiroCompra) self.bt_receber.setEnabled(True) self.bt_receber.setGeometry(QtCore.QRect(160, 140, 125, 30)) font = QtGui.QFont() font.setFamily("Tahoma") font.setPointSize(10) font.setWeight(75) font.setBold(True) self.bt_receber.setFont(font) self.bt_receber.setCursor(QtCore.Qt.PointingHandCursor) self.bt_receber.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_receber.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu) self.bt_receber.setStyleSheet("QPushButton {\n" "background-color: #7AB32E;\n" "color: #FFF;\n" "border: none;\n" "border-radius: 2px\n" " }\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_receber.setIconSize(QtCore.QSize(75, 35)) self.bt_receber.setObjectName("bt_receber") self.lb_FormCompra_9 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_9.setGeometry(QtCore.QRect(390, 180, 100, 20)) self.lb_FormCompra_9.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_9.setObjectName("lb_FormCompra_9") self.tx_valor = QtWidgets.QLineEdit(self.fr_FormPagar) self.tx_valor.setGeometry(QtCore.QRect(390, 200, 100, 30)) self.tx_valor.setFocusPolicy(QtCore.Qt.WheelFocus) self.tx_valor.setStyleSheet("QLineEdit{\n" "background: #CFCFCF;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 20px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" "QLineEdit:Focus {\n" "border: 1px solid red;\n" "}") self.tx_valor.setAlignment(QtCore.Qt.AlignRight | QtCore.Qt.AlignTrailing | QtCore.Qt.AlignVCenter) self.tx_valor.setObjectName("tx_valor") self.cb_repetir = QtWidgets.QComboBox(self.fr_FormPagar) self.cb_repetir.setGeometry(QtCore.QRect(510, 200, 110, 30)) self.cb_repetir.setStyleSheet( "QComboBox{\n" "background: #CFCFCF;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 13px \"Arial\" ;\n" "text-transform: uppercase;\n" "}\n" "QComboBox:Focus {\n" "border: 1px solid red;\n" "}\n" " QComboBox::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QComboBox::down-arrow {\n" " image: url(Images/down.png);\n" " }\n" "") self.cb_repetir.setObjectName("cb_repetir") self.lb_FormCompra_10 = QtWidgets.QLabel(self.fr_FormPagar) self.lb_FormCompra_10.setGeometry(QtCore.QRect(510, 180, 110, 20)) self.lb_FormCompra_10.setStyleSheet("QLabel{\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #A2A2A2;\n" "}") self.lb_FormCompra_10.setObjectName("lb_FormCompra_10") self.fr_BotoesFormCompra = QtWidgets.QFrame(self.fr_FormPagar) self.fr_BotoesFormCompra.setGeometry(QtCore.QRect(0, 470, 1000, 30)) self.fr_BotoesFormCompra.setStyleSheet("background:#E1DFE0;\n" "border: none;") self.fr_BotoesFormCompra.setObjectName("fr_BotoesFormCompra") self.bt_Voltar = QtWidgets.QPushButton(self.fr_BotoesFormCompra) self.bt_Voltar.setGeometry(QtCore.QRect(870, 0, 120, 30)) font = QtGui.QFont() font.setFamily("Tahoma") font.setPointSize(10) font.setWeight(75) font.setBold(True) self.bt_Voltar.setFont(font) self.bt_Voltar.setCursor(QtCore.Qt.PointingHandCursor) self.bt_Voltar.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_Voltar.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu) self.bt_Voltar.setStyleSheet("QPushButton {\n" "background-color: #1E87F0;\n" "color: #FFF\n" "}\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_Voltar.setIconSize(QtCore.QSize(75, 35)) self.bt_Voltar.setObjectName("bt_Voltar") self.bt_Salvar = QtWidgets.QPushButton(self.fr_BotoesFormCompra) self.bt_Salvar.setGeometry(QtCore.QRect(610, 0, 120, 30)) font = QtGui.QFont() font.setFamily("Tahoma") font.setPointSize(10) font.setWeight(75) font.setBold(True) self.bt_Salvar.setFont(font) self.bt_Salvar.setCursor(QtCore.Qt.PointingHandCursor) self.bt_Salvar.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_Salvar.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu) self.bt_Salvar.setStyleSheet("QPushButton {\n" "background-color: #7AB32E;\n" "color: #FFF\n" " }\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_Salvar.setIconSize(QtCore.QSize(75, 35)) self.bt_Salvar.setObjectName("bt_Salvar") self.bt_Imprimir = QtWidgets.QPushButton(self.fr_BotoesFormCompra) self.bt_Imprimir.setEnabled(False) self.bt_Imprimir.setGeometry(QtCore.QRect(740, 0, 120, 30)) font = QtGui.QFont() font.setFamily("Tahoma") font.setPointSize(10) font.setWeight(75) font.setBold(True) self.bt_Imprimir.setFont(font) self.bt_Imprimir.setCursor(QtCore.Qt.PointingHandCursor) self.bt_Imprimir.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_Imprimir.setContextMenuPolicy(QtCore.Qt.ActionsContextMenu) self.bt_Imprimir.setStyleSheet("QPushButton {\n" "background-color: #5C9BBC;\n" "color: #FFF\n" " }\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_Imprimir.setIconSize(QtCore.QSize(75, 35)) self.bt_Imprimir.setObjectName("bt_Imprimir") self.tradFormAPagar(ct_FormPagar) QtCore.QMetaObject.connectSlotsByName(ct_FormPagar)
def setMainCompras(self, ct_MainCompras): ct_MainCompras.setObjectName("ct_MainCompras") ct_MainCompras.resize(1000, 600) ct_MainCompras.setStyleSheet("border:none") self.frameMainCompras = QtWidgets.QFrame(ct_MainCompras) self.frameMainCompras.setGeometry(QtCore.QRect(0, 0, 1000, 600)) self.frameMainCompras.setObjectName("frameMainCompras") self.fr_TopoMenuCompras = QtWidgets.QFrame(self.frameMainCompras) self.fr_TopoMenuCompras.setGeometry(QtCore.QRect(0, 60, 1000, 40)) self.fr_TopoMenuCompras.setStyleSheet("background:#E1DFE0;\n" "border: none;") self.fr_TopoMenuCompras.setObjectName("fr_TopoMenuCompras") self.bt_BuscaCompras = QtWidgets.QPushButton(self.fr_TopoMenuCompras) self.bt_BuscaCompras.setGeometry(QtCore.QRect(820, 5, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") self.bt_BuscaCompras.setFont(font) self.bt_BuscaCompras.setCursor( QtGui.QCursor(QtCore.Qt.PointingHandCursor)) self.bt_BuscaCompras.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_BuscaCompras.setContextMenuPolicy(QtCore.Qt.NoContextMenu) self.bt_BuscaCompras.setText("") self.bt_BuscaCompras.setObjectName("bt_BuscaCompras") self.bt_AddNovaCompra = QtWidgets.QPushButton(self.fr_TopoMenuCompras) self.bt_AddNovaCompra.setGeometry(QtCore.QRect(900, 0, 100, 40)) self.bt_AddNovaCompra.setCursor( QtGui.QCursor(QtCore.Qt.PointingHandCursor)) self.bt_AddNovaCompra.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_AddNovaCompra.setContextMenuPolicy( QtCore.Qt.ActionsContextMenu) self.bt_AddNovaCompra.setStyleSheet("QPushButton {\n" "background-color: #7AB32E;\n" " }\n" "QPushButton:hover{\n" "background-color: #40a286\n" "}") self.bt_AddNovaCompra.setText("") self.bt_AddNovaCompra.setObjectName("bt_AddNovaCompra") self.tx_BuscaCompras = QtWidgets.QLineEdit(self.fr_TopoMenuCompras) self.tx_BuscaCompras.setGeometry(QtCore.QRect(0, 5, 500, 30)) font = QtGui.QFont() font.setFamily("Arial") self.tx_BuscaCompras.setFont(font) self.tx_BuscaCompras.setFocusPolicy(QtCore.Qt.ClickFocus) self.tx_BuscaCompras.setStyleSheet("QLineEdit {\n" "color: #000\n" "}\n" "") self.tx_BuscaCompras.setObjectName("tx_BuscaCompras") self.bt_PrintRelatCompras = QtWidgets.QPushButton( self.fr_TopoMenuCompras) self.bt_PrintRelatCompras.setGeometry(QtCore.QRect(860, 5, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") self.bt_PrintRelatCompras.setFont(font) self.bt_PrintRelatCompras.setCursor( QtGui.QCursor(QtCore.Qt.PointingHandCursor)) self.bt_PrintRelatCompras.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_PrintRelatCompras.setContextMenuPolicy(QtCore.Qt.NoContextMenu) self.bt_PrintRelatCompras.setText("") self.bt_PrintRelatCompras.setObjectName("bt_PrintRelatCompras") self.lb_FormVenda_22 = QtWidgets.QLabel(self.fr_TopoMenuCompras) self.lb_FormVenda_22.setGeometry(QtCore.QRect(670, 2, 120, 16)) self.lb_FormVenda_22.setStyleSheet( "QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial Unicode MS\";\n" "\n" "color:#1E87F0;\n" "border: none;\n" "}") self.lb_FormVenda_22.setObjectName("lb_FormVenda_22") self.dt_InicioCompra = QtWidgets.QDateEdit(self.fr_TopoMenuCompras) self.dt_InicioCompra.setGeometry(QtCore.QRect(520, 16, 140, 20)) self.dt_InicioCompra.setStyleSheet( "QDateEdit {\n" "background: #E1DFE0;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 20px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(Images/down.png);\n" " }") self.dt_InicioCompra.setCalendarPopup(True) self.dt_InicioCompra.setObjectName("dt_InicioCompra") self.lb_FormVenda_21 = QtWidgets.QLabel(self.fr_TopoMenuCompras) self.lb_FormVenda_21.setGeometry(QtCore.QRect(520, 2, 120, 16)) self.lb_FormVenda_21.setStyleSheet( "QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial Unicode MS\";\n" "\n" "color:#1E87F0;\n" "border: none;\n" "}") self.lb_FormVenda_21.setObjectName("lb_FormVenda_21") self.dt_FimCompra = QtWidgets.QDateEdit(self.fr_TopoMenuCompras) self.dt_FimCompra.setGeometry(QtCore.QRect(670, 16, 140, 20)) self.dt_FimCompra.setStyleSheet( "QDateEdit {\n" "background: #E1DFE0;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 20px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(Images/down.png);\n" " }") self.dt_FimCompra.setCalendarPopup(True) self.dt_FimCompra.setObjectName("dt_FimCompra") self.ct_containerCompras = QtWidgets.QFrame(self.frameMainCompras) self.ct_containerCompras.setGeometry(QtCore.QRect(0, 100, 1000, 500)) self.ct_containerCompras.setStyleSheet("border: none") self.ct_containerCompras.setObjectName("ct_containerCompras") self.tb_Compras = QtWidgets.QTableWidget(self.ct_containerCompras) self.tb_Compras.setGeometry(QtCore.QRect(0, 0, 1000, 500)) self.tb_Compras.viewport().setProperty( "cursor", QtGui.QCursor(QtCore.Qt.PointingHandCursor)) self.tb_Compras.setFocusPolicy(QtCore.Qt.WheelFocus) self.tb_Compras.setStyleSheet("QTableView{\n" "color: #797979;\n" "font-weight: bold;\n" "font-size: 13px;\n" "background: #FFF;\n" "padding: 0 0 0 5px;\n" "}\n" "QHeaderView:section{\n" "background: #FFF;\n" "padding: 5px 0 ;\n" "font-size: 13px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #797979;\n" "border: none;\n" "border-bottom: 2px solid #CCC;\n" "}\n" "QTableView::item {\n" "border-bottom: 2px solid #CCC;\n" "padding: 2px;\n" "}\n" "\n" "") self.tb_Compras.setFrameShape(QtWidgets.QFrame.NoFrame) self.tb_Compras.setFrameShadow(QtWidgets.QFrame.Plain) self.tb_Compras.setAutoScrollMargin(20) self.tb_Compras.setEditTriggers( QtWidgets.QAbstractItemView.NoEditTriggers) self.tb_Compras.setTabKeyNavigation(False) self.tb_Compras.setProperty("showDropIndicator", False) self.tb_Compras.setDragDropOverwriteMode(False) self.tb_Compras.setSelectionMode( QtWidgets.QAbstractItemView.NoSelection) self.tb_Compras.setSelectionBehavior( QtWidgets.QAbstractItemView.SelectRows) self.tb_Compras.setTextElideMode(QtCore.Qt.ElideMiddle) self.tb_Compras.setShowGrid(False) self.tb_Compras.setCornerButtonEnabled(False) self.tb_Compras.setRowCount(0) self.tb_Compras.setObjectName("tb_Compras") self.tb_Compras.setColumnCount(7) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignLeading | QtCore.Qt.AlignVCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) item.setBackground(QtGui.QColor(0, 0, 0, 0)) brush = QtGui.QBrush(QtGui.QColor(80, 79, 79)) brush.setStyle(QtCore.Qt.SolidPattern) item.setForeground(brush) self.tb_Compras.setHorizontalHeaderItem(0, item) item = QtWidgets.QTableWidgetItem() self.tb_Compras.setHorizontalHeaderItem(1, item) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignLeading | QtCore.Qt.AlignVCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) brush = QtGui.QBrush(QtGui.QColor(80, 79, 79)) brush.setStyle(QtCore.Qt.SolidPattern) item.setForeground(brush) self.tb_Compras.setHorizontalHeaderItem(2, item) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) brush = QtGui.QBrush(QtGui.QColor(80, 79, 79)) brush.setStyle(QtCore.Qt.SolidPattern) item.setForeground(brush) self.tb_Compras.setHorizontalHeaderItem(3, item) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) brush = QtGui.QBrush(QtGui.QColor(80, 79, 79)) brush.setStyle(QtCore.Qt.SolidPattern) item.setForeground(brush) self.tb_Compras.setHorizontalHeaderItem(4, item) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) brush = QtGui.QBrush(QtGui.QColor(80, 79, 79)) brush.setStyle(QtCore.Qt.SolidPattern) item.setForeground(brush) self.tb_Compras.setHorizontalHeaderItem(5, item) item = QtWidgets.QTableWidgetItem() item.setTextAlignment(QtCore.Qt.AlignCenter) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(10) font.setBold(True) font.setWeight(75) item.setFont(font) self.tb_Compras.setHorizontalHeaderItem(6, item) self.tb_Compras.horizontalHeader().setDefaultSectionSize(120) self.tb_Compras.horizontalHeader().setStretchLastSection(True) self.tb_Compras.verticalHeader().setVisible(False) self.tb_Compras.verticalHeader().setCascadingSectionResizes(True) self.tb_Compras.verticalHeader().setDefaultSectionSize(50) self.fr_TituloCompras = QtWidgets.QFrame(self.frameMainCompras) self.fr_TituloCompras.setGeometry(QtCore.QRect(0, 0, 1000, 60)) self.fr_TituloCompras.setStyleSheet("border: none") self.fr_TituloCompras.setObjectName("fr_TituloCompras") self.lb_tituloCompras = QtWidgets.QLabel(self.fr_TituloCompras) self.lb_tituloCompras.setGeometry(QtCore.QRect(10, 15, 200, 30)) font = QtGui.QFont() font.setFamily("DejaVu Sans") font.setPointSize(18) font.setBold(True) font.setWeight(75) self.lb_tituloCompras.setFont(font) self.lb_tituloCompras.setStyleSheet("color: #FFF") self.lb_tituloCompras.setObjectName("lb_tituloCompras") self.ct_containerCompras.raise_() self.fr_TopoMenuCompras.raise_() self.fr_TituloCompras.raise_() self.tradMainCompras(ct_MainCompras) QtCore.QMetaObject.connectSlotsByName(ct_MainCompras)
def __init__(self, parent=None): super().__init__(parent) self.path = "" self.path_labels = "C:/Users/Petar Stefanovic/Desktop/singi/I_semestar/MRS/P_1/labels.csv" self.model = 0 self.layout = QtWidgets.QVBoxLayout() self.vbox_layout = QtWidgets.QVBoxLayout() self.hbox_layout_1 = QtWidgets.QHBoxLayout() self.hbox_layout_2 = QtWidgets.QHBoxLayout() self.hbox_layout_3 = QtWidgets.QHBoxLayout() # ============================================================================= # Buttons # ============================================================================= self.open_calendar = QtWidgets.QPushButton( QtGui.QIcon('resources/icons/folder-open-document.png'), 'Open calendar', self) self.delete_event = QtWidgets.QPushButton( QtGui.QIcon('resources/icons/cross.png'), 'Remove event', self) self.save_event = QtWidgets.QPushButton( QtGui.QIcon('resources/icons/disk.png'), 'Save calendar', self) self.create_label = QtWidgets.QPushButton( QtGui.QIcon('resources/icons/application-plus.png'), 'Create label', self) self.open_calendar.clicked.connect(self._on_open) self.delete_event.clicked.connect(self._on_remove) self.save_event.clicked.connect(self._on_save) self.create_label.clicked.connect(self._on_create_label) # ============================================================================= # Kalendar # ============================================================================= self.calendar = QtWidgets.QCalendarWidget() self.calendar.setFirstDayOfWeek(QtCore.Qt.Monday) self.calendar.setGridVisible(True) self.calendar.setHorizontalHeaderFormat( QtWidgets.QCalendarWidget().HorizontalHeaderFormat(3)) # format = QtGui.QTextCharFormat() # format.setFontCapitalization(QtGui.QFont().Capitalization(1)) # self.calendar.setHeaderTextFormat(format) self.calendar.setStyleSheet( 'background: white; color: black; font: 15px') self.calendar.setWindowTitle('Calendar Widget') # self.calendar.mousePressEvent() # rmb = QtGui.QMouseEvent(QtCore.QPoint(QtGui.QMouseEvent().globalX(), QtGui.QMouseEvent().globalY())) # print(rmb) # ============================================================================= # Current Date # ============================================================================= self.current_date = QtWidgets.QDateEdit() self.current_date.setDisplayFormat('dd MMM yyyy') self.current_date.setDate(self.calendar.selectedDate()) self.current_date.dateChanged.connect(self.calendar.setSelectedDate) self.current_date.setStyleSheet('font: 15px bold') # self.calendar.selectionChanged.connect(self.selected_date_change) # self.calendar.selectionChanged.connect(self.table_change) # ============================================================================= # Pravimo apstraktni View preko kalendara kako bi omogucili otvaranje meni-ja na RMB # ============================================================================= self.table_view = QtWidgets.QTableView(self) self.table_view.setSelectionBehavior( QtWidgets.QAbstractItemView.SelectionBehavior.SelectRows) self.table_view.setSelectionMode( QtWidgets.QAbstractItemView.SingleSelection) self.table_view.setStyleSheet('font: 15px') self.hbox_layout_1.addWidget(self.open_calendar) self.hbox_layout_1.addWidget(self.delete_event) self.hbox_layout_1.addWidget(self.save_event) self.hbox_layout_1.addWidget(self.create_label) self.hbox_layout_2.addWidget(self.current_date) self.hbox_layout_3.addWidget(self.calendar) self.vbox_layout.addLayout(self.hbox_layout_1) self.vbox_layout.addLayout(self.hbox_layout_2) self.vbox_layout.addLayout(self.hbox_layout_3) self.vbox_layout.addWidget(self.table_view, 1, 0) self.layout.addLayout(self.vbox_layout) self.setLayout(self.layout) self._table = self.calendar.findChild(QtWidgets.QTableView) self._table.setMouseTracking(True) self._table.viewport().installEventFilter(self) self.single_click_timer = QtCore.QTimer() self.single_click_timer.setInterval(200)
def setupUi(self, Dialog): Dialog.setObjectName("Dialog") Dialog.resize(463, 433) css_file = open('../Stylesheet/dialog_stylesheet.css').read() Dialog.setStyleSheet(css_file) # icon & text label self.clock_icon = QtWidgets.QLabel(Dialog) self.clock_icon.setGeometry(QtCore.QRect(30, 120, 30, 30)) self.clock_icon.setText("") self.clock_icon.setPixmap(QtGui.QPixmap("../Assets/clock.png")) self.clock_icon.setScaledContents(True) self.clock_icon.setObjectName("clock_icon") self.location_icon = QtWidgets.QLabel(Dialog) self.location_icon.setGeometry(QtCore.QRect(30, 170, 30, 30)) self.location_icon.setText("") self.location_icon.setPixmap(QtGui.QPixmap("../Assets/placeholder.png")) self.location_icon.setScaledContents(True) self.location_icon.setObjectName("location_icon") self.label_dueto = QtWidgets.QLabel(Dialog) self.label_dueto.setGeometry(QtCore.QRect(150, 80, 60, 16)) font = QtGui.QFont() font.setFamily("Roboto Light") font.setPointSize(18) self.label_dueto.setFont(font) self.label_dueto.setObjectName("label") self.label_location = QtWidgets.QLabel(Dialog) self.label_location.setGeometry(QtCore.QRect(70, 175, 81, 21)) self.label_location.setFont(font) self.label_location.setObjectName("label_3") self.label_desc = QtWidgets.QLabel(Dialog) self.label_desc.setGeometry(QtCore.QRect(30, 260, 121, 21)) self.label_desc.setFont(font) self.label_desc.setObjectName("label_5") self.label_to_time = QtWidgets.QLabel(Dialog) self.label_to_time.setGeometry(QtCore.QRect(200, 125, 21, 16)) self.label_time = QtWidgets.QLabel(Dialog) self.label_time.setGeometry(QtCore.QRect(70, 125, 41, 21)) self.label_time.setFont(font) self.label_time.setObjectName("label_2") # lineEdit self.title = QtWidgets.QLineEdit(Dialog) self.title.setGeometry(QtCore.QRect(30, 20, 281, 31)) font.setPointSize(21) self.title.setFont(font) self.title.setObjectName("title") self.from_dateEdit = QtWidgets.QDateEdit(Dialog) self.from_dateEdit.setGeometry(QtCore.QRect(30, 70, 110, 31)) self.from_dateEdit.setAcceptDrops(False) self.from_dateEdit.setAutoFillBackground(False) self.from_dateEdit.setFrame(False) self.from_dateEdit.setButtonSymbols(QtWidgets.QAbstractSpinBox.NoButtons) self.from_dateEdit.setCalendarPopup(True) self.from_dateEdit.setObjectName("from_dateEdit") self.from_dateEdit.setDate(QDate.currentDate()) self.to_dateEdit = QtWidgets.QDateEdit(Dialog) self.to_dateEdit.setGeometry(QtCore.QRect(210, 70, 110, 31)) self.to_dateEdit.setAcceptDrops(False) self.to_dateEdit.setAutoFillBackground(False) self.to_dateEdit.setFrame(False) self.to_dateEdit.setButtonSymbols(QtWidgets.QAbstractSpinBox.NoButtons) self.to_dateEdit.setCalendarPopup(True) self.to_dateEdit.setObjectName("to_dateEdit") self.to_dateEdit.setDate(QDate.currentDate()) self.timeEdit = QtWidgets.QTimeEdit(Dialog) self.timeEdit.setGeometry(QtCore.QRect(130, 120, 61, 28)) self.timeEdit.setButtonSymbols(QtWidgets.QAbstractSpinBox.NoButtons) self.timeEdit.setObjectName("timeEdit") self.to_timeEdit = QtWidgets.QTimeEdit(Dialog) self.to_timeEdit.setGeometry(QtCore.QRect(220, 120, 61, 28)) self.to_timeEdit.setButtonSymbols(QtWidgets.QAbstractSpinBox.NoButtons) self.to_timeEdit.setObjectName("to_timeEdit") self.location = QtWidgets.QLineEdit(Dialog) font.setPointSize(16) self.location.setFont(font) self.location.setGeometry(QtCore.QRect(70, 210, 359, 28)) self.location.setObjectName("location") self.textEdit_desc = QtWidgets.QTextEdit(Dialog) self.textEdit_desc.setFont(font) self.textEdit_desc.setGeometry(QtCore.QRect(30, 290, 401, 114)) self.textEdit_desc.setObjectName("textEdit") self.retranslateUi(Dialog) QtCore.QMetaObject.connectSlotsByName(Dialog)
def setupUi(self, FiltroRemanufatura): FiltroRemanufatura.setObjectName("FiltroRemanufatura") FiltroRemanufatura.resize(645, 280) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( FiltroRemanufatura.sizePolicy().hasHeightForWidth()) FiltroRemanufatura.setSizePolicy(sizePolicy) FiltroRemanufatura.setMinimumSize(QtCore.QSize(600, 250)) FiltroRemanufatura.setMaximumSize(QtCore.QSize(645, 280)) FiltroRemanufatura.setSizeIncrement(QtCore.QSize(100, 50)) FiltroRemanufatura.setLocale( QtCore.QLocale(QtCore.QLocale.Portuguese, QtCore.QLocale.Brazil)) FiltroRemanufatura.setSizeGripEnabled(False) self.gridLayout = QtWidgets.QGridLayout(FiltroRemanufatura) self.gridLayout.setSpacing(6) self.gridLayout.setContentsMargins(0, 0, 0, 0) self.gridLayout.setObjectName("gridLayout") self.frame = QtWidgets.QFrame(FiltroRemanufatura) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.Expanding) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.frame.sizePolicy().hasHeightForWidth()) self.frame.setSizePolicy(sizePolicy) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.frame.setFont(font) self.frame.setLineWidth(0) self.frame.setObjectName("frame") self.gridLayout_2 = QtWidgets.QGridLayout(self.frame) self.gridLayout_2.setContentsMargins(0, 0, 0, 0) self.gridLayout_2.setVerticalSpacing(6) self.gridLayout_2.setObjectName("gridLayout_2") self.formFrame = QtWidgets.QFrame(self.frame) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.formFrame.sizePolicy().hasHeightForWidth()) self.formFrame.setSizePolicy(sizePolicy) font = QtGui.QFont() font.setWeight(50) font.setBold(False) self.formFrame.setFont(font) self.formFrame.setObjectName("formFrame") self.gridLayout_3 = QtWidgets.QGridLayout(self.formFrame) self.gridLayout_3.setContentsMargins(9, -1, -1, -1) self.gridLayout_3.setObjectName("gridLayout_3") self.frame_2 = QtWidgets.QFrame(self.formFrame) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.frame_2.sizePolicy().hasHeightForWidth()) self.frame_2.setSizePolicy(sizePolicy) self.frame_2.setObjectName("frame_2") self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.frame_2) self.verticalLayout_4.setObjectName("verticalLayout_4") self.groupBox_situacao = QtWidgets.QGroupBox(self.frame_2) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.groupBox_situacao.sizePolicy().hasHeightForWidth()) self.groupBox_situacao.setSizePolicy(sizePolicy) self.groupBox_situacao.setObjectName("groupBox_situacao") self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.groupBox_situacao) self.verticalLayout_2.setObjectName("verticalLayout_2") self.checkBox_cadastrada = QtWidgets.QCheckBox(self.groupBox_situacao) self.checkBox_cadastrada.setObjectName("checkBox_cadastrada") self.verticalLayout_2.addWidget(self.checkBox_cadastrada) self.checkBox_realizada = QtWidgets.QCheckBox(self.groupBox_situacao) self.checkBox_realizada.setObjectName("checkBox_realizada") self.verticalLayout_2.addWidget(self.checkBox_realizada) self.checkBox_encerrada = QtWidgets.QCheckBox(self.groupBox_situacao) self.checkBox_encerrada.setEnabled(True) self.checkBox_encerrada.setObjectName("checkBox_encerrada") self.verticalLayout_2.addWidget(self.checkBox_encerrada) self.verticalLayout_4.addWidget(self.groupBox_situacao) self.groupBox_classificacao = QtWidgets.QGroupBox(self.frame_2) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.groupBox_classificacao.sizePolicy().hasHeightForWidth()) self.groupBox_classificacao.setSizePolicy(sizePolicy) self.groupBox_classificacao.setObjectName("groupBox_classificacao") self.verticalLayout = QtWidgets.QVBoxLayout( self.groupBox_classificacao) self.verticalLayout.setObjectName("verticalLayout") self.checkBox_colorido = QtWidgets.QCheckBox( self.groupBox_classificacao) self.checkBox_colorido.setObjectName("checkBox_colorido") self.verticalLayout.addWidget(self.checkBox_colorido) self.checkBox_PB = QtWidgets.QCheckBox(self.groupBox_classificacao) self.checkBox_PB.setObjectName("checkBox_PB") self.verticalLayout.addWidget(self.checkBox_PB) self.verticalLayout_4.addWidget(self.groupBox_classificacao) self.gridLayout_3.addWidget(self.frame_2, 0, 1, 1, 1) self.frame_3 = QtWidgets.QFrame(self.formFrame) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.frame_3.sizePolicy().hasHeightForWidth()) self.frame_3.setSizePolicy(sizePolicy) self.frame_3.setFrameShape(QtWidgets.QFrame.NoFrame) self.frame_3.setFrameShadow(QtWidgets.QFrame.Plain) self.frame_3.setLineWidth(0) self.frame_3.setObjectName("frame_3") self.verticalLayout_5 = QtWidgets.QVBoxLayout(self.frame_3) self.verticalLayout_5.setContentsMargins(5, 5, 5, 5) self.verticalLayout_5.setObjectName("verticalLayout_5") self.horizontalGroupBox_2 = QtWidgets.QGroupBox(self.frame_3) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.horizontalGroupBox_2.sizePolicy().hasHeightForWidth()) self.horizontalGroupBox_2.setSizePolicy(sizePolicy) self.horizontalGroupBox_2.setCheckable(False) self.horizontalGroupBox_2.setObjectName("horizontalGroupBox_2") self.horizontalLayout_2 = QtWidgets.QHBoxLayout( self.horizontalGroupBox_2) self.horizontalLayout_2.setContentsMargins(9, 9, 9, 9) self.horizontalLayout_2.setObjectName("horizontalLayout_2") self.lineEdit_cliente_documento = QtWidgets.QLineEdit( self.horizontalGroupBox_2) self.lineEdit_cliente_documento.setMaximumSize( QtCore.QSize(60, 16777215)) self.lineEdit_cliente_documento.setObjectName( "lineEdit_cliente_documento") self.horizontalLayout_2.addWidget(self.lineEdit_cliente_documento) self.toolButton_cliente = QtWidgets.QToolButton( self.horizontalGroupBox_2) self.toolButton_cliente.setText("") self.toolButton_cliente.setObjectName("toolButton_cliente") self.horizontalLayout_2.addWidget(self.toolButton_cliente) self.lineEdit_cliente = QtWidgets.QLineEdit(self.horizontalGroupBox_2) self.lineEdit_cliente.setEnabled(False) self.lineEdit_cliente.setObjectName("lineEdit_cliente") self.horizontalLayout_2.addWidget(self.lineEdit_cliente) self.verticalLayout_5.addWidget(self.horizontalGroupBox_2) self.horizontalGroupBox_3 = QtWidgets.QGroupBox(self.frame_3) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.horizontalGroupBox_3.sizePolicy().hasHeightForWidth()) self.horizontalGroupBox_3.setSizePolicy(sizePolicy) self.horizontalGroupBox_3.setCheckable(False) self.horizontalGroupBox_3.setObjectName("horizontalGroupBox_3") self.horizontalLayout_3 = QtWidgets.QHBoxLayout( self.horizontalGroupBox_3) self.horizontalLayout_3.setContentsMargins(9, 9, 9, 9) self.horizontalLayout_3.setObjectName("horizontalLayout_3") self.lineEdit_mercadoria_id = QtWidgets.QLineEdit( self.horizontalGroupBox_3) self.lineEdit_mercadoria_id.setMaximumSize(QtCore.QSize(60, 16777215)) self.lineEdit_mercadoria_id.setObjectName("lineEdit_mercadoria_id") self.horizontalLayout_3.addWidget(self.lineEdit_mercadoria_id) self.toolButton_mercadoria = QtWidgets.QToolButton( self.horizontalGroupBox_3) self.toolButton_mercadoria.setText("") self.toolButton_mercadoria.setObjectName("toolButton_mercadoria") self.horizontalLayout_3.addWidget(self.toolButton_mercadoria) self.lineEdit_mercadoria = QtWidgets.QLineEdit( self.horizontalGroupBox_3) self.lineEdit_mercadoria.setEnabled(False) self.lineEdit_mercadoria.setObjectName("lineEdit_mercadoria") self.horizontalLayout_3.addWidget(self.lineEdit_mercadoria) self.verticalLayout_5.addWidget(self.horizontalGroupBox_3) self.widget_4 = QtWidgets.QWidget(self.frame_3) self.widget_4.setObjectName("widget_4") self.horizontalLayout_6 = QtWidgets.QHBoxLayout(self.widget_4) self.horizontalLayout_6.setContentsMargins(0, 0, 0, 0) self.horizontalLayout_6.setObjectName("horizontalLayout_6") self.groupBox_cadastro = QtWidgets.QGroupBox(self.widget_4) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.groupBox_cadastro.sizePolicy().hasHeightForWidth()) self.groupBox_cadastro.setSizePolicy(sizePolicy) self.groupBox_cadastro.setCheckable(True) self.groupBox_cadastro.setChecked(False) self.groupBox_cadastro.setObjectName("groupBox_cadastro") self.horizontalLayout = QtWidgets.QHBoxLayout(self.groupBox_cadastro) self.horizontalLayout.setContentsMargins(9, 9, 9, 9) self.horizontalLayout.setObjectName("horizontalLayout") self.dateEdit_data_entrada1 = QtWidgets.QDateEdit( self.groupBox_cadastro) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.dateEdit_data_entrada1.sizePolicy().hasHeightForWidth()) self.dateEdit_data_entrada1.setSizePolicy(sizePolicy) self.dateEdit_data_entrada1.setWrapping(False) self.dateEdit_data_entrada1.setFrame(False) self.dateEdit_data_entrada1.setReadOnly(False) self.dateEdit_data_entrada1.setButtonSymbols( QtWidgets.QAbstractSpinBox.UpDownArrows) self.dateEdit_data_entrada1.setCalendarPopup(True) self.dateEdit_data_entrada1.setDate(QtCore.QDate(2019, 1, 1)) self.dateEdit_data_entrada1.setObjectName("dateEdit_data_entrada1") self.horizontalLayout.addWidget(self.dateEdit_data_entrada1) self.label_2 = QtWidgets.QLabel(self.groupBox_cadastro) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.label_2.sizePolicy().hasHeightForWidth()) self.label_2.setSizePolicy(sizePolicy) self.label_2.setObjectName("label_2") self.horizontalLayout.addWidget(self.label_2) self.dateEdit_data_entrada2 = QtWidgets.QDateEdit( self.groupBox_cadastro) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.dateEdit_data_entrada2.sizePolicy().hasHeightForWidth()) self.dateEdit_data_entrada2.setSizePolicy(sizePolicy) self.dateEdit_data_entrada2.setWrapping(False) self.dateEdit_data_entrada2.setFrame(False) self.dateEdit_data_entrada2.setReadOnly(False) self.dateEdit_data_entrada2.setButtonSymbols( QtWidgets.QAbstractSpinBox.UpDownArrows) self.dateEdit_data_entrada2.setCalendarPopup(True) self.dateEdit_data_entrada2.setDate(QtCore.QDate(2019, 12, 31)) self.dateEdit_data_entrada2.setObjectName("dateEdit_data_entrada2") self.horizontalLayout.addWidget(self.dateEdit_data_entrada2) self.horizontalLayout_6.addWidget(self.groupBox_cadastro) self.groupBox_realizada = QtWidgets.QGroupBox(self.widget_4) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.groupBox_realizada.sizePolicy().hasHeightForWidth()) self.groupBox_realizada.setSizePolicy(sizePolicy) self.groupBox_realizada.setAlignment(QtCore.Qt.AlignLeading | QtCore.Qt.AlignLeft | QtCore.Qt.AlignVCenter) self.groupBox_realizada.setCheckable(True) self.groupBox_realizada.setChecked(False) self.groupBox_realizada.setObjectName("groupBox_realizada") self.horizontalLayout_4 = QtWidgets.QHBoxLayout( self.groupBox_realizada) self.horizontalLayout_4.setObjectName("horizontalLayout_4") self.dateEdit_data_saida1 = QtWidgets.QDateEdit( self.groupBox_realizada) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.dateEdit_data_saida1.sizePolicy().hasHeightForWidth()) self.dateEdit_data_saida1.setSizePolicy(sizePolicy) self.dateEdit_data_saida1.setWrapping(False) self.dateEdit_data_saida1.setFrame(False) self.dateEdit_data_saida1.setReadOnly(False) self.dateEdit_data_saida1.setButtonSymbols( QtWidgets.QAbstractSpinBox.UpDownArrows) self.dateEdit_data_saida1.setCalendarPopup(True) self.dateEdit_data_saida1.setDate(QtCore.QDate(2019, 1, 1)) self.dateEdit_data_saida1.setObjectName("dateEdit_data_saida1") self.horizontalLayout_4.addWidget(self.dateEdit_data_saida1) self.label_3 = QtWidgets.QLabel(self.groupBox_realizada) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Minimum) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.label_3.sizePolicy().hasHeightForWidth()) self.label_3.setSizePolicy(sizePolicy) self.label_3.setObjectName("label_3") self.horizontalLayout_4.addWidget(self.label_3) self.dateEdit_data_saida2 = QtWidgets.QDateEdit( self.groupBox_realizada) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.dateEdit_data_saida2.sizePolicy().hasHeightForWidth()) self.dateEdit_data_saida2.setSizePolicy(sizePolicy) self.dateEdit_data_saida2.setWrapping(False) self.dateEdit_data_saida2.setFrame(False) self.dateEdit_data_saida2.setReadOnly(False) self.dateEdit_data_saida2.setButtonSymbols( QtWidgets.QAbstractSpinBox.UpDownArrows) self.dateEdit_data_saida2.setCalendarPopup(True) self.dateEdit_data_saida2.setDate(QtCore.QDate(2019, 12, 31)) self.dateEdit_data_saida2.setObjectName("dateEdit_data_saida2") self.horizontalLayout_4.addWidget(self.dateEdit_data_saida2) self.horizontalLayout_6.addWidget(self.groupBox_realizada) self.verticalLayout_5.addWidget(self.widget_4) self.gridLayout_3.addWidget(self.frame_3, 0, 0, 1, 1) spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.gridLayout_3.addItem(spacerItem, 1, 0, 1, 1) self.gridLayout_2.addWidget(self.formFrame, 1, 0, 1, 1) self.gridLayout.addWidget(self.frame, 0, 0, 1, 1) self.retranslateUi(FiltroRemanufatura) QtCore.QMetaObject.connectSlotsByName(FiltroRemanufatura)
def setMovConta(self, ct_movimento): ct_movimento.setObjectName("ct_movimento") ct_movimento.resize(1000, 500) ct_movimento.setStyleSheet("background: #FFF;\n" "border: none") self.fr_movimento = QtWidgets.QFrame(ct_movimento) self.fr_movimento.setGeometry(QtCore.QRect(0, 0, 1000, 500)) self.fr_movimento.setFrameShape(QtWidgets.QFrame.StyledPanel) self.fr_movimento.setFrameShadow(QtWidgets.QFrame.Raised) self.fr_movimento.setObjectName("fr_movimento") self.fr_TopoMenuMovimento = QtWidgets.QFrame(self.fr_movimento) self.fr_TopoMenuMovimento.setGeometry(QtCore.QRect(0, 0, 1000, 40)) self.fr_TopoMenuMovimento.setStyleSheet("background:#E1DFE0;\n" "border: none;") self.fr_TopoMenuMovimento.setObjectName("fr_TopoMenuMovimento") self.bt_BuscaMovimento = QtWidgets.QPushButton(self.fr_TopoMenuMovimento) self.bt_BuscaMovimento.setGeometry(QtCore.QRect(920, 5, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") self.bt_BuscaMovimento.setFont(font) self.bt_BuscaMovimento.setCursor(QtCore.Qt.PointingHandCursor) self.bt_BuscaMovimento.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_BuscaMovimento.setContextMenuPolicy(QtCore.Qt.NoContextMenu) self.bt_BuscaMovimento.setStyleSheet("") self.bt_BuscaMovimento.setText("") self.bt_BuscaMovimento.setObjectName("bt_BuscaMovimento") self.bt_PrintMovimento = QtWidgets.QPushButton(self.fr_TopoMenuMovimento) self.bt_PrintMovimento.setGeometry(QtCore.QRect(960, 5, 30, 30)) font = QtGui.QFont() font.setFamily("Arial") self.bt_PrintMovimento.setFont(font) self.bt_PrintMovimento.setCursor(QtCore.Qt.PointingHandCursor) self.bt_PrintMovimento.setFocusPolicy(QtCore.Qt.NoFocus) self.bt_PrintMovimento.setContextMenuPolicy(QtCore.Qt.NoContextMenu) self.bt_PrintMovimento.setText("") self.bt_PrintMovimento.setObjectName("bt_PrintMovimento") self.dt_inicio = QtWidgets.QDateEdit(self.fr_TopoMenuMovimento) self.dt_inicio.setGeometry(QtCore.QRect(620, 16, 140, 20)) self.dt_inicio.setStyleSheet("QDateEdit {\n" "background: #E1DFE0;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 20px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(down.png);\n" " }\n" "QCalendarWidget QAbstractItemView:enabled \n" " {\n" "border: none;\n" " font-size:13px; \n" " color: #000; \n" " background-color: #F1F1F1; \n" " selection-background-color: rgb(64, 64, 64); \n" " selection-color: rgb(0, 255, 0); \n" " }\n" "QCalendarWidget QToolButton {\n" " border: none;\n" " color: #000\n" " }\n" "\n" " QCalendarWidget QMenu {\n" " width: 150px;\n" " left: 20px;\n" " color: white;\n" " font-size: 18px;\n" " background-color: rgb(100, 100, 100);\n" " }\n" "QCalendarWidget QWidget#qt_calendar_navigationbar\n" "{ \n" "border: none;\n" "}") self.dt_inicio.setMinimumDate(QtCore.QDate(2019, 1, 1)) self.dt_inicio.setCurrentSection(QtWidgets.QDateTimeEdit.DaySection) self.dt_inicio.setCalendarPopup(True) self.dt_inicio.setTimeSpec(QtCore.Qt.TimeZone) self.dt_inicio.setObjectName("dt_inicio") self.lb_FormVenda_21 = QtWidgets.QLabel(self.fr_TopoMenuMovimento) self.lb_FormVenda_21.setGeometry(QtCore.QRect(620, 2, 120, 16)) self.lb_FormVenda_21.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial Unicode MS\";\n" "\n" "color:#1E87F0;\n" "border: none;\n" "}") self.lb_FormVenda_21.setObjectName("lb_FormVenda_21") self.lb_FormVenda_22 = QtWidgets.QLabel(self.fr_TopoMenuMovimento) self.lb_FormVenda_22.setGeometry(QtCore.QRect(770, 2, 120, 16)) self.lb_FormVenda_22.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial Unicode MS\";\n" "\n" "color:#1E87F0;\n" "border: none;\n" "}") self.lb_FormVenda_22.setObjectName("lb_FormVenda_22") self.dt_fim = QtWidgets.QDateEdit(self.fr_TopoMenuMovimento) self.dt_fim.setGeometry(QtCore.QRect(770, 16, 140, 20)) self.dt_fim.setStyleSheet("QDateEdit {\n" "background: #E1DFE0;\n" "border: none;\n" "font-family: \"Arial\";\n" "font-size: 20px;\n" "font-weight: bold;\n" "color: rgb(80,79,79)\n" "}\n" " QDateEdit::drop-down {\n" " subcontrol-origin: padding;\n" " subcontrol-position: top right;\n" " width: 25px;\n" " border-left-width: 1px;\n" " border-left-color: darkgray;\n" " border-left-style: solid; /* just a single line */\n" " border-top-right-radius: 3px; /* same radius as the QComboBox */\n" " border-bottom-right-radius: 3px;\n" " }\n" "QDateEdit::down-arrow {\n" " image: url(down.png);\n" " }\n" "QCalendarWidget QAbstractItemView:enabled \n" " {\n" "border: none;\n" " font-size:13px; \n" " color: #000; \n" " background-color: #F1F1F1; \n" " selection-background-color: rgb(64, 64, 64); \n" " selection-color: rgb(0, 255, 0); \n" " }\n" "QCalendarWidget QToolButton {\n" " border: none;\n" " color: #000\n" " }\n" "\n" " QCalendarWidget QMenu {\n" " width: 150px;\n" " left: 20px;\n" " color: white;\n" " font-size: 18px;\n" " background-color: rgb(100, 100, 100);\n" " }\n" "QCalendarWidget QWidget#qt_calendar_navigationbar\n" "{ \n" "border: none;\n" "}") self.dt_fim.setButtonSymbols(QtWidgets.QAbstractSpinBox.PlusMinus) self.dt_fim.setMinimumDate(QtCore.QDate(2019, 1, 1)) self.dt_fim.setCalendarPopup(True) self.dt_fim.setObjectName("dt_fim") self.fr_Receita = QtWidgets.QFrame(self.fr_movimento) self.fr_Receita.setGeometry(QtCore.QRect(20, 50, 470, 100)) self.fr_Receita.setStyleSheet("QFrame {\n" "background: rgba(139, 194, 74, 100%);\n" "border: none;\n" "}\n" "") self.fr_Receita.setFrameShape(QtWidgets.QFrame.StyledPanel) self.fr_Receita.setFrameShadow(QtWidgets.QFrame.Raised) self.fr_Receita.setObjectName("fr_Receita") self.pr_receita = QtWidgets.QProgressBar(self.fr_Receita) self.pr_receita.setGeometry(QtCore.QRect(10, 65, 450, 30)) self.pr_receita.setStyleSheet("QProgressBar {\n" " border: 2px solid grey;\n" " border-radius: 5px;\n" " text-align: center;\n" " font: 14px \"Tahoma\";\n" " font-weight: bold;\n" " color: #000;\n" " background-color: #FFF\n" "\n" " }\n" " QProgressBar::chunk {\n" " background: rgb(122, 179, 46, 60%);\n" " width: 8px;\n" " margin: 0.5px;\n" " border-radius: 3px\n" " }") self.pr_receita.setObjectName("pr_receita") self.lb_FormVenda_20 = QtWidgets.QLabel(self.fr_Receita) self.lb_FormVenda_20.setGeometry(QtCore.QRect(10, 5, 150, 20)) self.lb_FormVenda_20.setLayoutDirection(QtCore.Qt.LeftToRight) self.lb_FormVenda_20.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_FormVenda_20.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter) self.lb_FormVenda_20.setObjectName("lb_FormVenda_20") self.label_3 = QtWidgets.QLabel(self.fr_Receita) self.label_3.setGeometry(QtCore.QRect(10, 35, 25, 20)) self.label_3.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 18px \"Arial\" ;\n" "font-weight: bold;\n" "color: #FFF;\n" "") self.label_3.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft) self.label_3.setObjectName("label_3") self.lb_entradaRecebido = QtWidgets.QLabel(self.fr_Receita) self.lb_entradaRecebido.setGeometry(QtCore.QRect(35, 30, 100, 25)) self.lb_entradaRecebido.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 25px \"Arial\" ;\n" "\n" "color: #FFF;\n" "") self.lb_entradaRecebido.setText("") self.lb_entradaRecebido.setObjectName("lb_entradaRecebido") self.lb_entradaPendente = QtWidgets.QLabel(self.fr_Receita) self.lb_entradaPendente.setGeometry(QtCore.QRect(165, 30, 100, 25)) self.lb_entradaPendente.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 25px \"Arial\" ;\n" "\n" "color: #FFF;\n" "") self.lb_entradaPendente.setText("") self.lb_entradaPendente.setObjectName("lb_entradaPendente") self.label_8 = QtWidgets.QLabel(self.fr_Receita) self.label_8.setGeometry(QtCore.QRect(140, 35, 25, 20)) self.label_8.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 18px \"Arial\" ;\n" "font-weight: bold;\n" "color: #FFF;\n" "") self.label_8.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft) self.label_8.setObjectName("label_8") self.line = QtWidgets.QFrame(self.fr_Receita) self.line.setGeometry(QtCore.QRect(130, 30, 2, 30)) self.line.setStyleSheet("background: #FFF") self.line.setFrameShape(QtWidgets.QFrame.VLine) self.line.setFrameShadow(QtWidgets.QFrame.Sunken) self.line.setObjectName("line") self.lb_inicioMovimento = QtWidgets.QLabel(self.fr_Receita) self.lb_inicioMovimento.setGeometry(QtCore.QRect(280, 5, 80, 20)) self.lb_inicioMovimento.setStyleSheet("QLabel{\n" "font-size: 15px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_inicioMovimento.setText("") self.lb_inicioMovimento.setObjectName("lb_inicioMovimento") self.label_2 = QtWidgets.QLabel(self.fr_Receita) self.label_2.setGeometry(QtCore.QRect(365, 5, 10, 20)) self.label_2.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.label_2.setObjectName("label_2") self.lb_fimMovimento = QtWidgets.QLabel(self.fr_Receita) self.lb_fimMovimento.setGeometry(QtCore.QRect(380, 5, 80, 20)) self.lb_fimMovimento.setStyleSheet("QLabel{\n" "font-size: 15px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_fimMovimento.setText("") self.lb_fimMovimento.setObjectName("lb_fimMovimento") self.fr_Despesa = QtWidgets.QFrame(self.fr_movimento) self.fr_Despesa.setGeometry(QtCore.QRect(510, 50, 470, 100)) self.fr_Despesa.setStyleSheet("QFrame {\n" "background: rgba(251, 90, 84, 100%);\n" "border: none;\n" "\n" "\n" "}") self.fr_Despesa.setFrameShape(QtWidgets.QFrame.StyledPanel) self.fr_Despesa.setFrameShadow(QtWidgets.QFrame.Raised) self.fr_Despesa.setObjectName("fr_Despesa") self.lb_FormVenda_24 = QtWidgets.QLabel(self.fr_Despesa) self.lb_FormVenda_24.setGeometry(QtCore.QRect(10, 5, 150, 20)) self.lb_FormVenda_24.setLayoutDirection(QtCore.Qt.LeftToRight) self.lb_FormVenda_24.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_FormVenda_24.setAlignment(QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft|QtCore.Qt.AlignVCenter) self.lb_FormVenda_24.setObjectName("lb_FormVenda_24") self.label_6 = QtWidgets.QLabel(self.fr_Despesa) self.label_6.setGeometry(QtCore.QRect(10, 35, 25, 20)) self.label_6.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 18px \"Arial\" ;\n" "font-weight: bold;\n" "color: #FFF;\n" "") self.label_6.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft) self.label_6.setObjectName("label_6") self.lb_despesaPaga = QtWidgets.QLabel(self.fr_Despesa) self.lb_despesaPaga.setGeometry(QtCore.QRect(35, 30, 100, 25)) self.lb_despesaPaga.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 25px \"Arial\" ;\n" "\n" "color: #FFF;\n" "") self.lb_despesaPaga.setText("") self.lb_despesaPaga.setObjectName("lb_despesaPaga") self.line_3 = QtWidgets.QFrame(self.fr_Despesa) self.line_3.setGeometry(QtCore.QRect(130, 30, 2, 30)) self.line_3.setStyleSheet("background: #FFF") self.line_3.setFrameShape(QtWidgets.QFrame.VLine) self.line_3.setFrameShadow(QtWidgets.QFrame.Sunken) self.line_3.setObjectName("line_3") self.lb_despesaAPagar = QtWidgets.QLabel(self.fr_Despesa) self.lb_despesaAPagar.setGeometry(QtCore.QRect(165, 30, 100, 25)) self.lb_despesaAPagar.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 25px \"Arial\" ;\n" "\n" "color: #FFF;\n" "") self.lb_despesaAPagar.setText("") self.lb_despesaAPagar.setObjectName("lb_despesaAPagar") self.label_10 = QtWidgets.QLabel(self.fr_Despesa) self.label_10.setGeometry(QtCore.QRect(140, 35, 25, 20)) self.label_10.setStyleSheet("background: none;\n" "border-radius: 2px;\n" "color: #000;\n" "font: 18px \"Arial\" ;\n" "font-weight: bold;\n" "color: #FFF;\n" "") self.label_10.setAlignment(QtCore.Qt.AlignBottom|QtCore.Qt.AlignLeading|QtCore.Qt.AlignLeft) self.label_10.setObjectName("label_10") self.lb_fimDespesa = QtWidgets.QLabel(self.fr_Despesa) self.lb_fimDespesa.setGeometry(QtCore.QRect(380, 5, 80, 20)) self.lb_fimDespesa.setStyleSheet("QLabel{\n" "font-size: 15px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_fimDespesa.setText("") self.lb_fimDespesa.setObjectName("lb_fimDespesa") self.label_12 = QtWidgets.QLabel(self.fr_Despesa) self.label_12.setGeometry(QtCore.QRect(365, 5, 10, 20)) self.label_12.setStyleSheet("QLabel{\n" "font-size: 12px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.label_12.setObjectName("label_12") self.lb_inicioDespesa = QtWidgets.QLabel(self.fr_Despesa) self.lb_inicioDespesa.setGeometry(QtCore.QRect(280, 5, 80, 20)) self.lb_inicioDespesa.setStyleSheet("QLabel{\n" "font-size: 15px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #FFF;\n" "border: none;\n" "background: none\n" "}") self.lb_inicioDespesa.setText("") self.lb_inicioDespesa.setObjectName("lb_inicioDespesa") self.pr_despesa = QtWidgets.QProgressBar(self.fr_Despesa) self.pr_despesa.setGeometry(QtCore.QRect(10, 65, 450, 30)) self.pr_despesa.setStyleSheet("QProgressBar {\n" " border: 2px solid grey;\n" " border-radius: 5px;\n" " text-align: center;\n" " font: 14px \"Tahoma\";\n" " font-weight: bold;\n" " color: #000;\n" " background: #FFF \n" "\n" " }\n" " QProgressBar::chunk {\n" " background: rgb(251, 90, 84, 60%);\n" " width: 8px;\n" " margin: 0.5px;\n" " border-radius: 3px\n" " }") self.pr_despesa.setObjectName("pr_despesa") self.tb_receita = QtWidgets.QTableWidget(self.fr_movimento) self.tb_receita.setGeometry(QtCore.QRect(20, 200, 470, 200)) self.tb_receita.setStyleSheet("QTableView{\n" "color: #797979;\n" "font-weight: bold;\n" "font-size: 13px;\n" "background: #FFF;\n" "padding: 0 0 0 5px;\n" "}\n" "") self.tb_receita.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.tb_receita.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.tb_receita.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.tb_receita.setTabKeyNavigation(False) self.tb_receita.setProperty("showDropIndicator", False) self.tb_receita.setDragDropOverwriteMode(False) self.tb_receita.setAlternatingRowColors(True) self.tb_receita.setSelectionMode(QtWidgets.QAbstractItemView.NoSelection) self.tb_receita.setShowGrid(False) self.tb_receita.setRowCount(0) self.tb_receita.setObjectName("tb_receita") self.tb_receita.setColumnCount(2) self.tb_receita.setRowCount(0) item = QtWidgets.QTableWidgetItem() self.tb_receita.setHorizontalHeaderItem(0, item) item = QtWidgets.QTableWidgetItem() self.tb_receita.setHorizontalHeaderItem(1, item) self.tb_receita.horizontalHeader().setVisible(False) self.tb_receita.horizontalHeader().setDefaultSectionSize(200) self.tb_receita.horizontalHeader().setStretchLastSection(True) self.tb_receita.verticalHeader().setVisible(False) self.tb_receita.verticalHeader().setDefaultSectionSize(25) self.tb_despesa = QtWidgets.QTableWidget(self.fr_movimento) self.tb_despesa.setGeometry(QtCore.QRect(510, 200, 470, 200)) self.tb_despesa.setStyleSheet("QTableView{\n" "color: #797979;\n" "font-weight: bold;\n" "font-size: 13px;\n" "background: #FFF;\n" "padding: 0 0 0 5px;\n" "}\n" "") self.tb_despesa.setVerticalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.tb_despesa.setHorizontalScrollBarPolicy(QtCore.Qt.ScrollBarAlwaysOff) self.tb_despesa.setEditTriggers(QtWidgets.QAbstractItemView.NoEditTriggers) self.tb_despesa.setTabKeyNavigation(False) self.tb_despesa.setProperty("showDropIndicator", False) self.tb_despesa.setDragDropOverwriteMode(False) self.tb_despesa.setAlternatingRowColors(True) self.tb_despesa.setSelectionMode(QtWidgets.QAbstractItemView.NoSelection) self.tb_despesa.setShowGrid(False) self.tb_despesa.setRowCount(1) self.tb_despesa.setObjectName("tb_despesa") self.tb_despesa.setColumnCount(2) self.tb_despesa.setRowCount(1) item = QtWidgets.QTableWidgetItem() self.tb_despesa.setHorizontalHeaderItem(0, item) item = QtWidgets.QTableWidgetItem() self.tb_despesa.setHorizontalHeaderItem(1, item) self.tb_despesa.horizontalHeader().setVisible(False) self.tb_despesa.horizontalHeader().setDefaultSectionSize(200) self.tb_despesa.horizontalHeader().setStretchLastSection(True) self.tb_despesa.verticalHeader().setVisible(False) self.tb_despesa.verticalHeader().setDefaultSectionSize(25) self.frameTotalmov = QtWidgets.QFrame(self.fr_movimento) self.frameTotalmov.setGeometry(QtCore.QRect(0, 460, 1000, 40)) self.frameTotalmov.setStyleSheet("border-bottom: 2px solid #CCC;\n" "background: #F7F7F7") self.frameTotalmov.setFrameShape(QtWidgets.QFrame.StyledPanel) self.frameTotalmov.setFrameShadow(QtWidgets.QFrame.Raised) self.frameTotalmov.setObjectName("frameTotalmov") self.label = QtWidgets.QLabel(self.frameTotalmov) self.label.setGeometry(QtCore.QRect(20, 10, 200, 20)) self.label.setStyleSheet("QLabel{\n" "font-size: 16px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #072D06;\n" "border: none;\n" "background: none\n" "}") self.label.setObjectName("label") self.lb_totalMovimento = QtWidgets.QLabel(self.frameTotalmov) self.lb_totalMovimento.setGeometry(QtCore.QRect(830, 5, 150, 30)) self.lb_totalMovimento.setStyleSheet("QLabel{\n" "font-size: 26px;\n" "font-family: \"Arial\";\n" "font-weight: bold;\n" "color: #072D06;\n" "border: none;\n" "background: none\n" "}") self.lb_totalMovimento.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter) self.lb_totalMovimento.setObjectName("lb_totalMovimento") self.tradMovConta(ct_movimento) QtCore.QMetaObject.connectSlotsByName(ct_movimento)
def setupUi(self, part_2_register_page): self.part_2_register_page = part_2_register_page part_2_register_page.setObjectName("part_2_register_page") part_2_register_page.resize(1600, 900) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( part_2_register_page.sizePolicy().hasHeightForWidth()) part_2_register_page.setSizePolicy(sizePolicy) part_2_register_page.setMinimumSize(QtCore.QSize(1600, 900)) part_2_register_page.setMaximumSize(QtCore.QSize(1600, 900)) part_2_register_page.setStyleSheet( "background-image: url(./image/black_register_wallpaper.jpg);\n" "\n" "background-size: contain;\n" "background-repeat: no-repeat;\n" "\n" "opacity : 0.5;\n" "") self.register_label = QtWidgets.QLabel(part_2_register_page) self.register_label.setGeometry(QtCore.QRect(600, 85, 500, 78)) font = QtGui.QFont() font.setFamily("Script MT Bold") font.setPointSize(38) font.setWeight(75) font.setBold(True) self.register_label.setFont(font) self.register_label.setStyleSheet("color : #FFE4C4;\n" "border-color : #FFE4C4;\n" "background : transparent;\n" "") self.register_label.setObjectName("register_label") self.first_sentence_label = QtWidgets.QLabel(part_2_register_page) self.first_sentence_label.setGeometry(QtCore.QRect(215, 190, 1208, 67)) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(30) self.first_sentence_label.setFont(font) self.first_sentence_label.setStyleSheet("color : #FFF;\n" "border-color : #FFF;\n" "background : transparent;") self.first_sentence_label.setObjectName("first_sentence_label") self.second_sentence_label = QtWidgets.QLabel(part_2_register_page) self.second_sentence_label.setGeometry(QtCore.QRect( 300, 250, 1056, 67)) font = QtGui.QFont() font.setFamily("Segoe UI") font.setPointSize(30) self.second_sentence_label.setFont(font) self.second_sentence_label.setStyleSheet("color : #FFF;\n" "border-color : #FFF;\n" "background : transparent;") self.second_sentence_label.setObjectName("second_sentence_label") self.weight_label = QtWidgets.QLabel(part_2_register_page) self.weight_label.setGeometry(QtCore.QRect(600, 360, 135, 40)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.weight_label.setFont(font) self.weight_label.setStyleSheet("color : white;\n" "background : transparent;") self.weight_label.setObjectName("weight_label") self.height_label = QtWidgets.QLabel(part_2_register_page) self.height_label.setGeometry(QtCore.QRect(870, 360, 135, 40)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.height_label.setFont(font) self.height_label.setStyleSheet("color : white;\n" "background : transparent;") self.height_label.setObjectName("height_label") self.sex_label = QtWidgets.QLabel(part_2_register_page) self.sex_label.setGeometry(QtCore.QRect(600, 520, 65, 40)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.sex_label.setFont(font) self.sex_label.setStyleSheet("color : white;\n" "background : transparent;") self.sex_label.setObjectName("sex_label") self.sex_comboBox = QtWidgets.QComboBox(part_2_register_page) self.sex_comboBox.setGeometry(QtCore.QRect(600, 590, 118, 41)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(18) self.sex_comboBox.setFont(font) self.sex_comboBox.setMouseTracking(True) self.sex_comboBox.setLayoutDirection(QtCore.Qt.LeftToRight) self.sex_comboBox.setStyleSheet( "background : white;\n" "color : black;\n" "border-radius : 17px solid white;\n" "\n" "QComboBox { background-color: white; color : black;}") self.sex_comboBox.setMaxVisibleItems(3) self.sex_comboBox.setInsertPolicy(QtWidgets.QComboBox.InsertAtBottom) self.sex_comboBox.setSizeAdjustPolicy( QtWidgets.QComboBox.AdjustToContents) self.sex_comboBox.setObjectName("sex_comboBox") icon = QtGui.QIcon() icon.addPixmap(QtGui.QPixmap("."), QtGui.QIcon.Normal, QtGui.QIcon.Off) self.sex_comboBox.addItem(icon, "") self.sex_comboBox.addItem("") self.sex_comboBox.addItem("") self.sex_label_2 = QtWidgets.QLabel(part_2_register_page) self.sex_label_2.setGeometry(QtCore.QRect(600, 690, 190, 40)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.sex_label_2.setFont(font) self.sex_label_2.setStyleSheet("color : white;\n" "background : transparent;") self.sex_label_2.setObjectName("sex_label_2") self.birthdate_dateEdit = QtWidgets.QDateEdit(part_2_register_page) self.birthdate_dateEdit.setGeometry(QtCore.QRect(600, 760, 225, 50)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(18) self.birthdate_dateEdit.setFont(font) self.birthdate_dateEdit.setCursor(QtCore.Qt.PointingHandCursor) self.birthdate_dateEdit.setCalendarPopup(True) self.birthdate_dateEdit.setObjectName("birthdate_dateEdit") self.weight_lineEdit = QtWidgets.QLineEdit(part_2_register_page) self.weight_lineEdit.setGeometry(QtCore.QRect(600, 430, 160, 50)) self.weight_lineEdit.setText("") font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.weight_lineEdit.setFont(font) self.weight_lineEdit.setLayoutDirection(QtCore.Qt.LeftToRight) self.weight_lineEdit.setStyleSheet( "background: white;\n" "color : black;\n" "border-radius : 17px solid white;\n" "") self.weight_lineEdit.setMaxLength(3) self.weight_lineEdit.setFrame(True) self.weight_lineEdit.setAlignment(QtCore.Qt.AlignCenter) self.weight_lineEdit.setObjectName("weight_lineEdit") self.height_lineEdit = QtWidgets.QLineEdit(part_2_register_page) self.height_lineEdit.setGeometry(QtCore.QRect(870, 430, 160, 50)) self.height_lineEdit.setText(" ") font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(20) self.height_lineEdit.setFont(font) self.height_lineEdit.setLayoutDirection(QtCore.Qt.LeftToRight) self.height_lineEdit.setStyleSheet( "background: white;\n" "color : black;\n" "border-radius : 17px solid white;\n" "") self.height_lineEdit.setText("") self.height_lineEdit.setMaxLength(3) self.height_lineEdit.setFrame(True) self.height_lineEdit.setAlignment(QtCore.Qt.AlignCenter) self.height_lineEdit.setObjectName("height_lineEdit") self.next_Button = QtWidgets.QPushButton(part_2_register_page) self.next_Button.clicked.connect(self.next_page) self.next_Button.setGeometry(QtCore.QRect(1210, 790, 347, 61)) font = QtGui.QFont() font.setFamily("Yu Gothic") font.setPointSize(22) self.next_Button.setFont(font) self.next_Button.setCursor(QtCore.Qt.PointingHandCursor) self.next_Button.setStyleSheet("color : white;\n" "background : #1347EC;\n" "border-color : white;\n" "border-width : 2.5px;\n" "border-radius : 30px;\n" "") self.next_Button.setObjectName("next_Button") self.retranslateUi(part_2_register_page) QtCore.QMetaObject.connectSlotsByName(part_2_register_page)
def setupUi(self, DockWidget): DockWidget.setObjectName("DockWidget") DockWidget.resize(703, 557) self.dockWidgetContents = QtWidgets.QWidget() self.dockWidgetContents.setObjectName("dockWidgetContents") self.gridLayout = QtWidgets.QGridLayout(self.dockWidgetContents) self.gridLayout.setObjectName("gridLayout") self.label = QtWidgets.QLabel(self.dockWidgetContents) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label.setFont(font) self.label.setObjectName("label") self.gridLayout.addWidget(self.label, 0, 1, 1, 1) self.label_2 = QtWidgets.QLabel(self.dockWidgetContents) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_2.setFont(font) self.label_2.setObjectName("label_2") self.gridLayout.addWidget(self.label_2, 0, 2, 1, 1) self.label_12 = QtWidgets.QLabel(self.dockWidgetContents) self.label_12.setMinimumSize(QtCore.QSize(0, 0)) self.label_12.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_12.setFont(font) self.label_12.setObjectName("label_12") self.gridLayout.addWidget(self.label_12, 1, 0, 1, 1) self.fontComboBox = QtWidgets.QFontComboBox(self.dockWidgetContents) self.fontComboBox.setMinimumSize(QtCore.QSize(0, 0)) self.fontComboBox.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.fontComboBox.setObjectName("fontComboBox") self.gridLayout.addWidget(self.fontComboBox, 1, 1, 1, 1) self.fontComboBoxDis = QtWidgets.QFontComboBox(self.dockWidgetContents) self.fontComboBoxDis.setEnabled(False) self.fontComboBoxDis.setMinimumSize(QtCore.QSize(0, 0)) self.fontComboBoxDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.fontComboBoxDis.setObjectName("fontComboBoxDis") self.gridLayout.addWidget(self.fontComboBoxDis, 1, 2, 1, 1) self.label_3 = QtWidgets.QLabel(self.dockWidgetContents) self.label_3.setObjectName("label_3") self.gridLayout.addWidget(self.label_3, 2, 0, 1, 1) self.comboBoxEdit = QtWidgets.QComboBox(self.dockWidgetContents) self.comboBoxEdit.setEditable(True) self.comboBoxEdit.setObjectName("comboBoxEdit") self.comboBoxEdit.addItem("") self.comboBoxEdit.addItem("") self.comboBoxEdit.addItem("") self.comboBoxEdit.setItemText(2, "") self.gridLayout.addWidget(self.comboBoxEdit, 2, 1, 1, 1) self.comboBoxEditDis = QtWidgets.QComboBox(self.dockWidgetContents) self.comboBoxEditDis.setEnabled(False) self.comboBoxEditDis.setEditable(True) self.comboBoxEditDis.setObjectName("comboBoxEditDis") self.comboBoxEditDis.addItem("") self.comboBoxEditDis.addItem("") self.comboBoxEditDis.addItem("") self.comboBoxEditDis.setItemText(2, "") self.gridLayout.addWidget(self.comboBoxEditDis, 2, 2, 1, 1) self.label_13 = QtWidgets.QLabel(self.dockWidgetContents) self.label_13.setMinimumSize(QtCore.QSize(0, 0)) self.label_13.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_13.setFont(font) self.label_13.setObjectName("label_13") self.gridLayout.addWidget(self.label_13, 3, 0, 1, 1) self.lineEdit = QtWidgets.QLineEdit(self.dockWidgetContents) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.lineEdit.sizePolicy().hasHeightForWidth()) self.lineEdit.setSizePolicy(sizePolicy) self.lineEdit.setMinimumSize(QtCore.QSize(0, 0)) self.lineEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.lineEdit.setObjectName("lineEdit") self.gridLayout.addWidget(self.lineEdit, 3, 1, 1, 1) self.lineEditDis = QtWidgets.QLineEdit(self.dockWidgetContents) self.lineEditDis.setEnabled(False) sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed) sizePolicy.setHorizontalStretch(0) sizePolicy.setVerticalStretch(0) sizePolicy.setHeightForWidth( self.lineEditDis.sizePolicy().hasHeightForWidth()) self.lineEditDis.setSizePolicy(sizePolicy) self.lineEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.lineEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.lineEditDis.setObjectName("lineEditDis") self.gridLayout.addWidget(self.lineEditDis, 3, 2, 1, 1) self.label_14 = QtWidgets.QLabel(self.dockWidgetContents) self.label_14.setMinimumSize(QtCore.QSize(0, 0)) self.label_14.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_14.setFont(font) self.label_14.setObjectName("label_14") self.gridLayout.addWidget(self.label_14, 4, 0, 1, 1) self.textEdit = QtWidgets.QTextEdit(self.dockWidgetContents) self.textEdit.setMinimumSize(QtCore.QSize(0, 0)) self.textEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.textEdit.setObjectName("textEdit") self.gridLayout.addWidget(self.textEdit, 4, 1, 1, 1) self.textEditDis = QtWidgets.QTextEdit(self.dockWidgetContents) self.textEditDis.setEnabled(False) self.textEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.textEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.textEditDis.setObjectName("textEditDis") self.gridLayout.addWidget(self.textEditDis, 4, 2, 1, 1) self.label_15 = QtWidgets.QLabel(self.dockWidgetContents) self.label_15.setMinimumSize(QtCore.QSize(0, 0)) self.label_15.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_15.setFont(font) self.label_15.setObjectName("label_15") self.gridLayout.addWidget(self.label_15, 5, 0, 1, 1) self.plainTextEdit = QtWidgets.QPlainTextEdit(self.dockWidgetContents) self.plainTextEdit.setMinimumSize(QtCore.QSize(0, 0)) self.plainTextEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.plainTextEdit.setObjectName("plainTextEdit") self.gridLayout.addWidget(self.plainTextEdit, 5, 1, 1, 1) self.plainTextEditDis = QtWidgets.QPlainTextEdit( self.dockWidgetContents) self.plainTextEditDis.setEnabled(False) self.plainTextEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.plainTextEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.plainTextEditDis.setObjectName("plainTextEditDis") self.gridLayout.addWidget(self.plainTextEditDis, 5, 2, 1, 1) self.label_16 = QtWidgets.QLabel(self.dockWidgetContents) self.label_16.setMinimumSize(QtCore.QSize(0, 0)) self.label_16.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_16.setFont(font) self.label_16.setObjectName("label_16") self.gridLayout.addWidget(self.label_16, 6, 0, 1, 1) self.spinBox = QtWidgets.QSpinBox(self.dockWidgetContents) self.spinBox.setMinimumSize(QtCore.QSize(0, 0)) self.spinBox.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.spinBox.setObjectName("spinBox") self.gridLayout.addWidget(self.spinBox, 6, 1, 1, 1) self.spinBoxDis = QtWidgets.QSpinBox(self.dockWidgetContents) self.spinBoxDis.setEnabled(False) self.spinBoxDis.setMinimumSize(QtCore.QSize(0, 0)) self.spinBoxDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.spinBoxDis.setObjectName("spinBoxDis") self.gridLayout.addWidget(self.spinBoxDis, 6, 2, 1, 1) self.label_17 = QtWidgets.QLabel(self.dockWidgetContents) self.label_17.setMinimumSize(QtCore.QSize(0, 0)) self.label_17.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_17.setFont(font) self.label_17.setObjectName("label_17") self.gridLayout.addWidget(self.label_17, 7, 0, 1, 1) self.doubleSpinBox = QtWidgets.QDoubleSpinBox(self.dockWidgetContents) self.doubleSpinBox.setMinimumSize(QtCore.QSize(0, 0)) self.doubleSpinBox.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.doubleSpinBox.setObjectName("doubleSpinBox") self.gridLayout.addWidget(self.doubleSpinBox, 7, 1, 1, 1) self.doubleSpinBoxDis = QtWidgets.QDoubleSpinBox( self.dockWidgetContents) self.doubleSpinBoxDis.setEnabled(False) self.doubleSpinBoxDis.setMinimumSize(QtCore.QSize(0, 0)) self.doubleSpinBoxDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.doubleSpinBoxDis.setObjectName("doubleSpinBoxDis") self.gridLayout.addWidget(self.doubleSpinBoxDis, 7, 2, 1, 1) self.label_18 = QtWidgets.QLabel(self.dockWidgetContents) self.label_18.setMinimumSize(QtCore.QSize(0, 0)) self.label_18.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_18.setFont(font) self.label_18.setObjectName("label_18") self.gridLayout.addWidget(self.label_18, 8, 0, 1, 1) self.timeEdit = QtWidgets.QTimeEdit(self.dockWidgetContents) self.timeEdit.setMinimumSize(QtCore.QSize(0, 0)) self.timeEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.timeEdit.setObjectName("timeEdit") self.gridLayout.addWidget(self.timeEdit, 8, 1, 1, 1) self.timeEditDis = QtWidgets.QTimeEdit(self.dockWidgetContents) self.timeEditDis.setEnabled(False) self.timeEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.timeEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.timeEditDis.setObjectName("timeEditDis") self.gridLayout.addWidget(self.timeEditDis, 8, 2, 1, 1) self.label_19 = QtWidgets.QLabel(self.dockWidgetContents) self.label_19.setMinimumSize(QtCore.QSize(0, 0)) self.label_19.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_19.setFont(font) self.label_19.setObjectName("label_19") self.gridLayout.addWidget(self.label_19, 9, 0, 1, 1) self.dateEdit = QtWidgets.QDateEdit(self.dockWidgetContents) self.dateEdit.setMinimumSize(QtCore.QSize(0, 0)) self.dateEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.dateEdit.setObjectName("dateEdit") self.gridLayout.addWidget(self.dateEdit, 9, 1, 1, 1) self.dateEditDis = QtWidgets.QDateEdit(self.dockWidgetContents) self.dateEditDis.setEnabled(False) self.dateEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.dateEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.dateEditDis.setObjectName("dateEditDis") self.gridLayout.addWidget(self.dateEditDis, 9, 2, 1, 1) self.label_20 = QtWidgets.QLabel(self.dockWidgetContents) self.label_20.setMinimumSize(QtCore.QSize(0, 0)) self.label_20.setMaximumSize(QtCore.QSize(16777215, 16777215)) font = QtGui.QFont() font.setWeight(75) font.setBold(True) self.label_20.setFont(font) self.label_20.setObjectName("label_20") self.gridLayout.addWidget(self.label_20, 10, 0, 1, 1) self.dateTimeEdit = QtWidgets.QDateTimeEdit(self.dockWidgetContents) self.dateTimeEdit.setMinimumSize(QtCore.QSize(0, 0)) self.dateTimeEdit.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.dateTimeEdit.setObjectName("dateTimeEdit") self.gridLayout.addWidget(self.dateTimeEdit, 10, 1, 1, 1) self.dateTimeEditDis = QtWidgets.QDateTimeEdit(self.dockWidgetContents) self.dateTimeEditDis.setEnabled(False) self.dateTimeEditDis.setMinimumSize(QtCore.QSize(0, 0)) self.dateTimeEditDis.setMaximumSize(QtCore.QSize(16777215, 16777215)) self.dateTimeEditDis.setObjectName("dateTimeEditDis") self.gridLayout.addWidget(self.dateTimeEditDis, 10, 2, 1, 1) spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding) self.gridLayout.addItem(spacerItem, 11, 0, 1, 1) self.label_51 = QtWidgets.QLabel(self.dockWidgetContents) self.label_51.setAlignment(QtCore.Qt.AlignCenter) self.label_51.setObjectName("label_51") self.gridLayout.addWidget(self.label_51, 12, 0, 1, 3) DockWidget.setWidget(self.dockWidgetContents) self.retranslateUi(DockWidget) QtCore.QObject.connect(self.fontComboBox, QtCore.SIGNAL("editTextChanged(QString)"), self.fontComboBoxDis.setEditText) QtCore.QObject.connect(self.lineEdit, QtCore.SIGNAL("textEdited(QString)"), self.lineEditDis.setText) QtCore.QObject.connect(self.spinBox, QtCore.SIGNAL("valueChanged(int)"), self.spinBoxDis.setValue) QtCore.QObject.connect(self.doubleSpinBox, QtCore.SIGNAL("valueChanged(double)"), self.doubleSpinBoxDis.setValue) QtCore.QObject.connect(self.timeEdit, QtCore.SIGNAL("timeChanged(QTime)"), self.timeEditDis.setTime) QtCore.QObject.connect(self.dateEdit, QtCore.SIGNAL("dateTimeChanged(QDateTime)"), self.dateEditDis.setDateTime) QtCore.QObject.connect(self.dateTimeEdit, QtCore.SIGNAL("dateTimeChanged(QDateTime)"), self.dateTimeEditDis.setDateTime) QtCore.QMetaObject.connectSlotsByName(DockWidget)