Advertisement
AMONRA75

PYQT5 - UI LOAD

Sep 8th, 2023
25
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. import typing
  2. from PyQt5.QtWidgets import QMainWindow, QApplication, QPushButton, QTextBrowser, QWidget
  3. from PyQt5 import QtCore, uic
  4. import sys
  5.  
  6.  
  7.  
  8. class UI(QMainWindow):
  9. def __init__(self):
  10. super(UI, self).__init__()
  11.  
  12.  
  13.  
  14. #load file
  15. uic.loadUi("ui.ui",self)
  16.  
  17.  
  18. #show the app
  19. self.show()
  20.  
  21.  
  22. app = QApplication(sys.argv)
  23.  
  24. UIWindow = UI()
  25. app.exec_()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement