Hi team,
When signing a file with a visual signature and ShrinkTextOnOverflow = true, I populate only the Name and Date fields. I would like the signer’s name to be added on a new line between the NameLabel and DateLabel fields.
Currently, when they are on the same line and the field width is smaller, the signer’s name becomes very difficult to read.
As a workaround, I tried adding “\n” to the NameLabel. Surprisingly, it works sometimes, but quite often it breaks. Instead of wrapping to a second line, the text stays on a single line, and the newline character is replaced by a “square box” symbol (unrecognized glyph). I have also tried using Environment.NewLine, but the result is the same—just a square box.
Do you have any recommendations or ideas on how to achieve this reliably? The goal is to keep the text auto-scaled/fitted to the field width, while ensuring the signer’s name always wraps to a new line cleanly.
Here is a code snippet for context:
// …
var signatureField = document.Form.Fields.AddSignature(document.Pages[0], 300, 500, 250, 100);
var signatureAppearance = signatureField.Appearance;
signatureAppearance.ShrinkTextOnOverflow = true;
signatureAppearance.NameLabel = signatureAppearance.NameLabel + “\n”;
signatureAppearance.DateFormat = “dd.MM.yyyy HH:mm:ss zzz”;
// …
Best regards