Use normal pen when last-datum color not provided

multichartz_backup
Tyler Goodlet 2023-01-23 19:28:05 -05:00
parent 99d0e4aab2
commit e84e5e3c39
1 changed files with 12 additions and 5 deletions

View File

@ -85,7 +85,7 @@ class FlowGraphic(pg.GraphicsObject):
# line styling
color: str = 'bracket',
last_step_color: str = 'original',
last_step_color: str | None = None,
fill_color: Optional[str] = None,
style: str = 'solid',
@ -126,10 +126,17 @@ class FlowGraphic(pg.GraphicsObject):
)
# last segment is drawn in 2px thickness for emphasis
if last_step_color:
self.last_step_pen = pg.mkPen(
hcolor(last_step_color),
width=2,
)
else:
self.last_step_pen = pg.mkPen(
self._pen,
width=2,
)
self._last_line: QLineF = QLineF()
super().__init__(*args, **kwargs)