Add no-path guard now that we can use a poly

big_data_lines
Tyler Goodlet 2022-03-14 06:04:18 -04:00
parent 5800c10901
commit 8627f6f6c5
1 changed files with 5 additions and 5 deletions

View File

@ -466,9 +466,8 @@ class FastAppendCurve(pg.GraphicsObject):
) -> None:
profiler = pg.debug.Profiler(
# disabled=False, #not pg_profile_enabled(),
disabled=not pg_profile_enabled(),
)
# p.setRenderHint(p.Antialiasing, True)
if (
self._step_mode
@ -486,13 +485,14 @@ class FastAppendCurve(pg.GraphicsObject):
profiler('.drawLine()')
p.setPen(self._pen)
# else:
path = self.path
if self._use_poly:
assert self.poly
p.drawPolyline(self.poly)
profiler('.drawPolyline()')
else:
p.drawPath(self.path)
elif path:
p.drawPath(path)
profiler('.drawPath()')
# TODO: try out new work from `pyqtgraph` main which should