File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -427,7 +427,8 @@ def start_event_loop(self, timeout=0):
427427 raise RuntimeError ("Event loop already running" )
428428 self ._event_loop = event_loop = QtCore .QEventLoop ()
429429 if timeout > 0 :
430- timer = QtCore .QTimer .singleShot (timeout * 1000 , event_loop .quit )
430+ timer = QtCore .QTimer .singleShot (int (timeout * 1000 ),
431+ event_loop .quit )
431432 event_loop .exec_ ()
432433
433434 def stop_event_loop (self , event = None ):
@@ -462,7 +463,7 @@ def blit(self, bbox=None):
462463 if bbox is None and self .figure :
463464 bbox = self .figure .bbox # Blit the entire canvas if bbox is None.
464465 # repaint uses logical pixels, not physical pixels like the renderer.
465- l , b , w , h = [pt / self ._dpi_ratio for pt in bbox .bounds ]
466+ l , b , w , h = [int ( pt / self ._dpi_ratio ) for pt in bbox .bounds ]
466467 t = b + h
467468 self .repaint (l , self .rect ().height () - t , w , h )
468469
You can’t perform that action at this time.
0 commit comments