def start(self, close=False): # Create plot window win = self.WIN_CLASS(toolbar=True, wintitle=self.name) win.show() QApplication.processEvents() plot = win.get_plot() # Create item (ignore this step in benchmark result!) self.make_item() # Benchmarking t0 = time.time() self.add_to_plot(plot) print(self.name + ':') print(" N = %d" % self.nsamples) plot.replot() # Force replot print(" dt = %d ms" % ((time.time() - t0) * 1e3)) if close: win.close()
def start(self, close=False): # Create plot window win = self.WIN_CLASS(toolbar=True, wintitle=self.name) win.show() QApplication.processEvents() plot = win.get_plot() # Create item (ignore this step in benchmark result!) self.make_item() # Benchmarking t0 = time.time() self.add_to_plot(plot) print(self.name+':') print(" N = %d" % self.nsamples) plot.replot() # Force replot print(" dt = %d ms" % ((time.time()-t0)*1e3)) if close: win.close()
def xcsw_is_visible(self, state): if state: QApplication.processEvents() self.adjust_ycsw_height() else: self.adjust_ycsw_height(0)
def adjust_ycsw_height(self, height=None): if height is None: height = self.xcsw.height() - self.ycsw.toolbar.height() self.ycsw.adjust_height(height) if height: QApplication.processEvents()
def adjust_ycsw_height(self, height=None): if height is None: height = self.xcsw.height()-self.ycsw.toolbar.height() self.ycsw.adjust_height(height) if height: QApplication.processEvents()