Advertisement
MyNamesNotReallyDave

Document Splitter - main.py

Nov 17th, 2019
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.06 KB | None | 0 0
  1. from PyQt5 import QtWidgets, uic
  2. import sys, os, PyPDF2
  3.  
  4. uicFile = 'mainUi.ui'
  5. path = f'{os.path.dirname(os.path.abspath(__file__))}\\{uicFile}'
  6.  
  7. class Ui(QtWidgets.QMainWindow):
  8.     def __init__(self):
  9.         super(Ui, self).__init__() # Call the inherited classes __init__ method
  10.         uic.loadUi(path, self) # Load the .ui file
  11.        
  12. class Documents(self, file):
  13.    
  14.     @staticmethod
  15.     def documentsPages():
  16.         doc_pages = {}
  17.         fields = {
  18.             'schedule':'Schedule',
  19.             'miof':'MI OForm',
  20.             'gsc':'GSC',
  21.             'smokeco':'Smoke Test',
  22.             'eicr':'EICR',
  23.             'featic':'FEAT & IC',
  24.             'past':'Past'
  25.             }
  26.         for k, v in fields:
  27.             start_page = f'Ui.{k}SpinMin'
  28.             doc_pages[v] = {'startPage':}
  29.  
  30.  
  31.  
  32.  
  33.  
  34. if __name__ == '__main__':
  35.     app = QtWidgets.QApplication(sys.argv) # Create an instance of QtWidgets.QApplication
  36.     window = Ui() # Create an instance of our class
  37.     window.show() # Show the GUI
  38.     app.exec_() # Start the application
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement