From 1b37720b45648a0aaf18a75d38378e91b8b030fd Mon Sep 17 00:00:00 2001 From: NT Date: Fri, 6 Aug 2021 20:21:51 +0200 Subject: [PATCH] more minor fixes --- fixup-latex.py | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/fixup-latex.py b/fixup-latex.py index 323efa3..ae708f7 100644 --- a/fixup-latex.py +++ b/fixup-latex.py @@ -95,13 +95,10 @@ def parseF(inf,outf,reSkip,reSCnt,applyRecs=False): fout.write("% SKIP due to RE #"+format(r)+" , L"+format(reSCnt[r]) +" "+line) #print("S "+line[:-1]) # debug else: - # fix captions - for i in range(len(recs)): - line = recs[i].sub( rect[i], line ) # replace all - - # line = rec1.sub( rec1t, line ) # replace - # line = rec2.sub( rec2t, line ) # replace - # line = rec3.sub( rec3t, line ) # replace + if applyRecs: + # fix captions and apply other latex replacements + for i in range(len(recs)): + line = recs[i].sub( rect[i], line ) # replace all fout.write(line) #print(line[:-1]) # debug