slightly nicer logic using LINE_STYLE_CYCLE instead of LINE_COLORS
This commit is contained in:
@ -14,8 +14,7 @@ class MDISubPlot(MDISubWindow):
|
||||
|
||||
|
||||
|
||||
from itertools import cycle
|
||||
from ..theme import LINE_COLORS
|
||||
from ..theme import LINE_STYLE_CYCLE
|
||||
|
||||
|
||||
class MDISubMultiPlot(MDISubWindow):
|
||||
@ -25,14 +24,8 @@ class MDISubMultiPlot(MDISubWindow):
|
||||
super().__init__(title, *args, **kwargs)
|
||||
|
||||
plt = pg.PlotWidget()
|
||||
self.plots = [d.make_plot(plt) for d in descs]
|
||||
self.plots = [d.make_plot(plt, style=s) for d, s in zip(descs, LINE_STYLE_CYCLE)]
|
||||
self.setWidget(plt)
|
||||
|
||||
cc = cycle(LINE_COLORS)
|
||||
for p, c in zip(self.plots, cc):
|
||||
#TODO: this overwrites the line width, etc.
|
||||
p.setPen(c)
|
||||
p.setSymbolBrush(c)
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user