Closed hannesdelbeke closed 1 year ago
from PySide2.QtWidgets import QApplication, QMainWindow, QPushButton
app = QApplication([])
window = QMainWindow()
button = QPushButton("Click me", window, objectName="jezus")
window.show()
app.exec_()
objectame is always unique, and makes for nicer print statements when debugging. we can use this to compare
test widget, paste in blender console, assumes bqt is active
from PySide2.QtWidgets import QWidget, QSlider, QVBoxLayout, QApplication
widget = QWidget(objectName="sliderboy")
slider = QSlider()
layout = QVBoxLayout()
layout.addWidget(slider)
widget.setLayout(layout)
widget.show()
now that we can manage widgets with
bqt.add
, add feature to not open a new widget, if the widget is already open.instead set widget active. can be done based on name? forcing devs to use a nice qt name for their tools