Filling Rotated Field Reduces Font Size

I have a form with a page that has no rotation. The page has 2 fields, one is not rotated and the other is on270. When the field that is on270 is populated, the font size is reduced to the point that it is not readable. It’s as if the measurement on the textbox with is being taken left to right without considering the field is rotated. I have created a sample project to illustrate the issue.

@Johnwpowellryan

Could you please attach the sample project with your post so that we can use to it test the scenario in our environment and address it accordingly?

RotatedFields.zip (55.3 KB)
Sample project attached

I found a workaround. If you set the rotated field to multi-line, it will not reduce the font size

1 Like

@Johnwpowellryan

It is nice to know that you were able to sort your issue out. Please keep using our API and feel free to create a new topic in case you face any issues.

This really is a defect and should be fixed. While the workaround does get it going, we cannot go and update all our PDF’s to accommodate this.

Unfortunately, this is a showstopper for us while evaluating this tool.

@alistairw

Can you please share your sample PDF document along with the code snippet that you are using? We will test the scenario in our environment and address it accordingly.

Are you able to use the RotatedFields.zip sample provided by the original poster?

@alistairw

Yes, we were able to use that project. Following code snippet was used in that project;

using (var stream = assembly.GetManifestResourceStream($"{assembly.GetName().Name}.Form.pdf"))
{
 using (var pdf = new Aspose.Pdf.Facades.Form(stream))
 {
  pdf.Document.Form.XFA["topmostSubform[0].Page1[0].Horizontal[0]"] = "Horizontal Field Test";
  pdf.Document.Form.XFA["topmostSubform[0].Page1[0].Vertical[0]"] = "Vertical Field Test";
  pdf.Save("Result.pdf");
 }
}

Are you using the same code snippet? If you are from the same team as @Johnwpowellryan, we can continue with the same file provided in the .zip archive. In case your issue is related to different PDF file, we request you share that with us as we log and investigate the issue from the perspective of specific PDF document.