From 00d26cda30fc6a8f416ba47d169384a1fb0d5d89 Mon Sep 17 00:00:00 2001 From: Markus Rosenstihl Date: Tue, 19 Apr 2016 09:28:29 +0200 Subject: [PATCH] idea for grace driver --- fileio/gracedriver.py | 2 ++ libmath/functions.py | 1 + 2 files changed, 3 insertions(+) diff --git a/fileio/gracedriver.py b/fileio/gracedriver.py index 32fb0bd..718fa87 100644 --- a/fileio/gracedriver.py +++ b/fileio/gracedriver.py @@ -44,7 +44,9 @@ class GracePlot(object): if "label" in kwds.keys(): # TODO: implement at least greek symbols and lower upper case (_ and ^)? + # with translate method? label = unicode(kwds["label"]).encode('ascii', 'ignore') + self.cmds.append('S%i LEGEND "%s"\n'%(self.data_counter, label)) if "ls" in kwds.keys(): diff --git a/libmath/functions.py b/libmath/functions.py index 3b0e607..533b424 100644 --- a/libmath/functions.py +++ b/libmath/functions.py @@ -110,6 +110,7 @@ def static_cmplx(p, x ): return static + class YaffCmplx(Function): def __init__(self): super(YaffCmplx, self).__init__()