From 70da8615054960faede51004acd7b74b7385e79b Mon Sep 17 00:00:00 2001 From: ahmedk <karim.ahmed@xfel.eu> Date: Wed, 12 Jul 2023 14:05:24 +0200 Subject: [PATCH] switch tex_excape with split_len for converting value to latex --- src/xfel_calibrate/calibrate.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/xfel_calibrate/calibrate.py b/src/xfel_calibrate/calibrate.py index b3629a4f9..222ebfdcc 100755 --- a/src/xfel_calibrate/calibrate.py +++ b/src/xfel_calibrate/calibrate.py @@ -513,10 +513,6 @@ def make_par_table(parms): line = '' for i in range(0, len(seq), length): sub_line = seq[i:i + length] - # Ensure proper line break if the - # start of the new line begins with `_` - if sub_line[0] == '_' and line[-1] == "-": - line += '\\' line += sub_line.replace('/', '/\-') if not any(c in lbc for c in sub_line): line += '\-' @@ -532,10 +528,11 @@ def make_par_table(parms): len_parms[0] = max_len[0] name = split_len(name, max_len[0]) - value = tex_escape(str(p.value)) + value = str(p.value) if len(value) > max_len[1]: len_parms[1] = max_len[1] value = split_len(value, max_len[1]) + value = tex_escape(value) if issubclass(p.type, str): value = "``{}''".format(value) comment = tex_escape(str(p.comment)[1:]) -- GitLab