From 9340f19ba24d72d14b860e59bcfc2a51cfeee1de Mon Sep 17 00:00:00 2001 From: wm4 Date: Thu, 6 Oct 2016 18:00:23 +0200 Subject: TOOLS/stats-conv.py: use different colors for symbols too Also, not setting pen=None seems to draw horizontal lines for the dots, which is fine too. --- TOOLS/stats-conv.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) (limited to 'TOOLS/stats-conv.py') diff --git a/TOOLS/stats-conv.py b/TOOLS/stats-conv.py index 120f69195a..5fc092e3c7 100755 --- a/TOOLS/stats-conv.py +++ b/TOOLS/stats-conv.py @@ -151,15 +151,16 @@ for cur in ax: cur.addLegend(offset = (-1, 1)) for e in G.sevents: cur = ax[1 if e.type == "value" else 0] + if not cur in G.curveno: + G.curveno[cur] = 0 args = {'name': e.name,'antialias':True} + color = mkColor(colors[G.curveno[cur] % len(colors)]) if e.type == "event-signal": args['symbol'] = e.marker - args['pen'] = None + args['symbolBrush'] = pg.mkBrush(color, width=0) else: - if not cur in G.curveno: - G.curveno[cur] = 0 - args['pen'] = pg.mkPen(mkColor(colors[G.curveno[cur] % len(colors)]), width=0) - G.curveno[cur] += 1 + args['pen'] = pg.mkPen(color, width=0) + G.curveno[cur] += 1 n = cur.plot([x for x,y in e.vals], [y for x,y in e.vals], **args) QtGui.QApplication.instance().exec_() -- cgit v1.2.3