parameters: (self)
docstring: Opens a window and initializes.  Called internally, and must be in the visualization thread.
docstring_summary: Opens a window and initializes.  Called internally, and must be in the visualization thread.
docstring_tokens: Opens a window and initializes . Called internally and must be in the visualization thread .
function: def initialize(self):
          """ Opens a window and initializes.  Called internally, and must be in the visualization thread."""
          assert self.program != None, "QGLWidget initialized without a GLProgram"
          try:
              glEnable(GL_MULTISAMPLE)
          except Exception:
              print("QGLWidget.initialize(): perhaps Qt didn't initialize properly?")
              pass
          self.setMouseTracking(True)
          self.setFocusPolicy(Qt.StrongFocus)
          def idleCallback():
              self.nextIdleEvent = 0
              if self.program: self.program.idlefunc()
              if self.nextIdleEvent == 0:
                  self.idleTimer.start(0)
          self.idleTimer = QTimer(self)
          self.idleTimer.timeout.connect(idleCallback)
          self.idleTimer.setSingleShot(True)
          self.idleTimer.start(0)
          #init function
          self.program.initialize()
  
          if self.actionMenu is not None:
              for a in self.actions:
                  self.actionMenu.addAction(a)
          else:
              print("QtGLWidget.initialize: no action menu?")
  
          self.initialized = True
function_tokens: def initialize ( self ) : assert self . program != None , "QGLWidget initialized without a GLProgram" try : glEnable ( GL_MULTISAMPLE ) except Exception : print ( "QGLWidget.initialize(): perhaps Qt didn't initialize properly?" ) pass self . setMouseTracking ( True ) self . setFocusPolicy ( Qt . StrongFocus ) def idleCallback ( ) : self . nextIdleEvent = 0 if self . program : self . program . idlefunc ( ) if self . nextIdleEvent == 0 : self . idleTimer . start ( 0 ) self . idleTimer = QTimer ( self ) self . idleTimer . timeout . connect ( idleCallback ) self . idleTimer . setSingleShot ( True ) self . idleTimer . start ( 0 ) #init function self . program . initialize ( ) if self . actionMenu is not None : for a in self . actions : self . actionMenu . addAction ( a ) else : print ( "QtGLWidget.initialize: no action menu?" ) self . initialized = True