Free Support Forum - groupdocs.com

Signature gets distorted when inserting

We are experiencing an issue with certain documents, which strangely doesn’t occur all the time, just in some specific cases.
For these documents, after drawing a signature and placing it in a document, it ends up in a position below than where it was expected, and also with a size about 15-20% bigger.

Just after drawing it and previewing the document, it actually looks good and in the correct place. But after we call the SignatureHandler.Sign method, it stamps the signature in the pdf and the image ends up being modified as mentioned before.

We are wondering what might be the cause for this, and want to know if it might be related to one of the known issues mentioned here: https://docs.groupdocs.com/signature/net/net-standard-2-0-api-limitations/, or is that just for Text Signatures only?

Something that might be important, is that when saving that pdf in word as a docx and then saving it back as pdf, if that document is used in that way that I mentioned, the issue doesn’t happen anymore. So imagine that it has something to do with the document itself, we just cannot figure out what specifically.

distorted signing box 2.jpg (27.5 KB)
distorted signing box 1.jpg (72.6 KB)

@nicolas.darriulat

Could you please mention the API version (e.g. 19.10, 21.10) that you are using in the project? Also, share the problematic file and sample code. We’ll then look into this issue.

Hello @Atir_Tahir ,

It happens in version 19.5.0.0 of Group Docs signature (see image below from the SignatureHandler class which belongs to that package).

image.png (78.9 KB)

And here is a sample code that calls the SignatureHandler.Sign method (the circled line is the one that distorts the document boxes):

image.png (32.2 KB)

Unfortunately, I cannot provide you with the problematic file because it contains confidential data from a user.
Is there any property from the document that we could take a look at in order to understand if there’s anything different in that case?

@nicolas.darriulat

Could you please try this open-source UI project and let us know if you face same issue in it? This showcase project is based on GroupDocs.Signature for .NET 20.x.