Skip to content

Instantly share code, notes, and snippets.

@kywthiha
Forked from anonymous/spread1.py
Created November 17, 2019 10:33
Show Gist options
  • Save kywthiha/ce0831efab5b6101708f466453e8ae1d to your computer and use it in GitHub Desktop.
Save kywthiha/ce0831efab5b6101708f466453e8ae1d to your computer and use it in GitHub Desktop.
import sys
from PyQt5.QtWidgets import QTableWidget, QApplication, QMainWindow
class MyTable(QTableWidget):
def __init__(self, r, c):
super().__init__(r, c)
self.show()
class Sheet(QMainWindow):
def __init__(self):
super().__init__()
self.form_widget = MyTable(10, 10)
self.setCentralWidget(self.form_widget)
self.show()
app = QApplication(sys.argv)
sheet = Sheet()
sys.exit(app.exec_())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment