FlatCAM.py 608 B

123456789101112131415161718192021222324
  1. import sys
  2. from PyQt4 import QtGui
  3. from FlatCAMApp import App
  4. def debug_trace():
  5. """
  6. Set a tracepoint in the Python debugger that works with Qt
  7. :return: None
  8. """
  9. from PyQt4.QtCore import pyqtRemoveInputHook
  10. #from pdb import set_trace
  11. pyqtRemoveInputHook()
  12. #set_trace()
  13. debug_trace()
  14. # All X11 calling should be thread safe otherwise we have strange issues
  15. # QtCore.QCoreApplication.setAttribute(QtCore.Qt.AA_X11InitThreads)
  16. # NOTE: Never talk to the GUI from threads! This is why I commented the above.
  17. app = QtGui.QApplication(sys.argv)
  18. fc = App()
  19. sys.exit(app.exec_())