loxxy
Gold Üye
- Katılım
- 19 Eki 2024
- Mesajlar
- 217
- Beğeniler
- 28
merhabalar bir satış konusunda bir loader gördüm (menü) sonra onu chat gpt ye yaptırdım aynsıın benzedi kodları aşağıya bıraktım
Kodlar
from PyQt5 import QtWidgets, QtGui, QtCore
import sys
class LicenseWindow(QtWidgets.QWidget):
def __init__(self):
super().__init__()
self.initUI()
def initUI(self):
# Ana pencere yapılandırması
self.setWindowTitle("Fusion")
self.setGeometry(100, 100, 600, 300)
# Ana widget için grid layout
main_layout = QtWidgets.QHBoxLayout(self)
# Sol kısım (Fusion metni ve arka plan gradyanı)
left_widget = QtWidgets.QWidget(self)
left_widget.setFixedSize(300, 300)
left_widget.setStyleSheet("""
QWidget {
background: qlineargradient(spreadad, x1:0, y1:0, x2:1, y2:0, stop:0 #FF5F6D, stop:1 #FFC371);
}
""")
# Sol kısım layout'u ve metinler
left_layout = QtWidgets.QVBoxLayout(left_widget)
left_layout.setAlignment(QtCore.Qt.AlignCenter)
fusion_label = QtWidgets.QLabel("FUSION", self)
fusion_label.setStyleSheet("color: white; font-size: 28px; font-weight: bold;")
desc_label = QtWidgets.QLabel("Next Generation\nSecurity Platform", self)
desc_label.setStyleSheet("color: white; font-size: 14px;")
version_label = QtWidgets.QLabel("Version 5.0", self)
version_label.setStyleSheet("color: white; font-size: 10px;")
left_layout.addWidget(fusion_label)
left_layout.addWidget(desc_label)
left_layout.addWidget(version_label)
# Sağ kısım (Lisans doğrulama kısmı)
right_widget = QtWidgets.QWidget(self)
right_widget.setStyleSheet("background-color: #1b1b1b;")
right_layout = QtWidgets.QVBoxLayout(right_widget)
right_layout.setAlignment(QtCore.Qt.AlignCenter)
activate_label = QtWidgets.QLabel("ACTIVATE LICENSE", self)
activate_label.setStyleSheet("color: #CCCCCC; font-size: 12px;")
input_field = QtWidgets.QLineEdit(self)
input_field.setPlaceholderText("XXXX-XXXX-XXXX")
input_field.setStyleSheet("""
QLineEdit {
background-color: #333333;
color: white;
padding: 8px;
border: none;
}
""")
verify_button = QtWidgets.QPushButton("VERIFY", self)
verify_button.setStyleSheet("""
QPushButton {
background-color: #FF007F;
color: white;
font-weight: bold;
padding: 8px;
}
QPushButton:hover {
background-color: #D6006F;
}
""")
# Sağ layout'a widget ekleme
right_layout.addWidget(activate_label)
right_layout.addWidget(input_field)
right_layout.addWidget(verify_button)
# Ana layout'a sol ve sağ widget'ları ekleme
main_layout.addWidget(left_widget)
main_layout.addWidget(right_widget)
self.setLayout(main_layout)
app = QtWidgets.QApplication(sys.argv)
window = LicenseWindow()
window.show()
sys.exit(app.exec_())
Kodlar
from PyQt5 import QtWidgets, QtGui, QtCore
import sys
class LicenseWindow(QtWidgets.QWidget):
def __init__(self):
super().__init__()
self.initUI()
def initUI(self):
# Ana pencere yapılandırması
self.setWindowTitle("Fusion")
self.setGeometry(100, 100, 600, 300)
# Ana widget için grid layout
main_layout = QtWidgets.QHBoxLayout(self)
# Sol kısım (Fusion metni ve arka plan gradyanı)
left_widget = QtWidgets.QWidget(self)
left_widget.setFixedSize(300, 300)
left_widget.setStyleSheet("""
QWidget {
background: qlineargradient(spreadad, x1:0, y1:0, x2:1, y2:0, stop:0 #FF5F6D, stop:1 #FFC371);
}
""")
# Sol kısım layout'u ve metinler
left_layout = QtWidgets.QVBoxLayout(left_widget)
left_layout.setAlignment(QtCore.Qt.AlignCenter)
fusion_label = QtWidgets.QLabel("FUSION", self)
fusion_label.setStyleSheet("color: white; font-size: 28px; font-weight: bold;")
desc_label = QtWidgets.QLabel("Next Generation\nSecurity Platform", self)
desc_label.setStyleSheet("color: white; font-size: 14px;")
version_label = QtWidgets.QLabel("Version 5.0", self)
version_label.setStyleSheet("color: white; font-size: 10px;")
left_layout.addWidget(fusion_label)
left_layout.addWidget(desc_label)
left_layout.addWidget(version_label)
# Sağ kısım (Lisans doğrulama kısmı)
right_widget = QtWidgets.QWidget(self)
right_widget.setStyleSheet("background-color: #1b1b1b;")
right_layout = QtWidgets.QVBoxLayout(right_widget)
right_layout.setAlignment(QtCore.Qt.AlignCenter)
activate_label = QtWidgets.QLabel("ACTIVATE LICENSE", self)
activate_label.setStyleSheet("color: #CCCCCC; font-size: 12px;")
input_field = QtWidgets.QLineEdit(self)
input_field.setPlaceholderText("XXXX-XXXX-XXXX")
input_field.setStyleSheet("""
QLineEdit {
background-color: #333333;
color: white;
padding: 8px;
border: none;
}
""")
verify_button = QtWidgets.QPushButton("VERIFY", self)
verify_button.setStyleSheet("""
QPushButton {
background-color: #FF007F;
color: white;
font-weight: bold;
padding: 8px;
}
QPushButton:hover {
background-color: #D6006F;
}
""")
# Sağ layout'a widget ekleme
right_layout.addWidget(activate_label)
right_layout.addWidget(input_field)
right_layout.addWidget(verify_button)
# Ana layout'a sol ve sağ widget'ları ekleme
main_layout.addWidget(left_widget)
main_layout.addWidget(right_widget)
self.setLayout(main_layout)
app = QtWidgets.QApplication(sys.argv)
window = LicenseWindow()
window.show()
sys.exit(app.exec_())