mirror of
https://github.com/pyapp-kit/superqt.git
synced 2025-07-21 20:21:07 +02:00
* style: use ruff format * fix import * disallow pyside 6.6.2 * pin in tests too * pyside6.4 on windows * fix greedy imports * double quote * run sliders last * try 6.6.1 again
19 lines
497 B
Python
19 lines
497 B
Python
"""Example for QCollapsible."""
|
|
|
|
from qtpy.QtWidgets import QApplication, QLabel, QPushButton
|
|
|
|
from superqt import QCollapsible
|
|
|
|
app = QApplication([])
|
|
|
|
collapsible = QCollapsible("Advanced analysis")
|
|
collapsible.setCollapsedIcon("+")
|
|
collapsible.setExpandedIcon("-")
|
|
collapsible.addWidget(QLabel("This is the inside of the collapsible frame"))
|
|
for i in range(10):
|
|
collapsible.addWidget(QPushButton(f"Content button {i + 1}"))
|
|
|
|
collapsible.expand(animate=False)
|
|
collapsible.show()
|
|
app.exec_()
|