From 910b78bf7c4c663adad3a7ae030d6a084bc0cd90 Mon Sep 17 00:00:00 2001 From: Ariel Sosnovsky Date: Sun, 28 Oct 2018 13:44:30 -0400 Subject: [PATCH] - added some typing --- pdfmajor/interpreter/PDFPageInterpreter.py | 4 ++-- pdfmajor/interpreter/PDFTextState.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/pdfmajor/interpreter/PDFPageInterpreter.py b/pdfmajor/interpreter/PDFPageInterpreter.py index ee78321..a3eb121 100644 --- a/pdfmajor/interpreter/PDFPageInterpreter.py +++ b/pdfmajor/interpreter/PDFPageInterpreter.py @@ -493,12 +493,12 @@ class PDFPageInterpreter(object): return # show-pos - def do_TJ(self, seq): + def do_TJ(self, seq: bytearray): if self.textstate.font is None: if settings.STRICT: raise PDFInterpreterError('No font specified!') return - self.device.render_string(self.textstate, seq, self.ncs, self.graphicstate.copy()) + self.device.render_string(self.textstate.copy(), seq, self.ncs, self.graphicstate.copy()) return # show diff --git a/pdfmajor/interpreter/PDFTextState.py b/pdfmajor/interpreter/PDFTextState.py index 6dcbc37..ed084c5 100644 --- a/pdfmajor/interpreter/PDFTextState.py +++ b/pdfmajor/interpreter/PDFTextState.py @@ -45,4 +45,4 @@ class PDFTextState(object): def reset(self): self.matrix = MATRIX_IDENTITY self.linematrix = (0, 0) - return + return \ No newline at end of file