From 41ba98ee91ec6f10b4ac8ed48a5b723f1eca9914 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Julien=20Fastr=C3=A9?= Date: Tue, 3 Sep 2024 14:33:45 +0200 Subject: [PATCH] Fix signature box placement calculation Adjusted the calculation of the signature box's bottom boundary to subtract the height instead of adding it. This change ensures that the signature is placed correctly within the designated zone on the PDF. --- pythonProject/worker.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pythonProject/worker.py b/pythonProject/worker.py index 0c1b651..835a8f3 100644 --- a/pythonProject/worker.py +++ b/pythonProject/worker.py @@ -42,7 +42,7 @@ def on_message(channel, method_frame, header_frame, body): try: box_place = (body_content['signatureZone']['x'], body_content['signatureZone']['y'], body_content['signatureZone']['x'] + body_content['signatureZone']['width'], - body_content['signatureZone']['y'] + body_content['signatureZone']['height']) + body_content['signatureZone']['y'] - body_content['signatureZone']['height']) LOGGER.debug("will try signature") signed = orchestrator.sign(reason=body_content['reason'], signature_index=body_content['signatureZoneIndex'], box_place=box_place, on_page=body_content['signatureZone']['PDFPage']['index'],