Text letters half-cutted

Hi,

I’ve changed Aspose.Pdf.Kit version from 2.6.3 to 3.1.0.

After running the our same application that uses Aspose, the text letters now appear cutted: The upper half of the letter has been cutted.

See text on top of attached PDF file.

Regards.

Hello Emilio,

We apologies for the inconvenience. Can you please explain us the scenario in which you are using Aspose.Pdf.Kit and also if its convenient for you, can you please share the code with us, so that we can test the scenario at our end.

Hi,

It happens with simplest functionality of adding text (see result in attached file Jandernauer2.pdf):

string testFileFullPath = testFilePath + “Empty.pdf”;

FileStream renderedStream = new FileStream(testFileFullPath, FileMode.Open,
FileAccess.ReadWrite);

// … then I basically add text to opende Pdf file with next code:

UseLicense();
MemoryStream resultStream = new MemoryStream();
// Class from Aspose.Pdf.Kit package.
// Represents a class for adding texts and images on the pages
// of existing Pdf file.
PdfFileMend pdfMend = new PdfFileMend(Pdf, resultStream);
string[] lines = text.Split(’\n’);
FormattedText ext = GetFormattedText(lines[0].Trim(), isBold);
for (int i = 1; i < lines.Length; i++)
{
ext.AddNewLineText(lines[i].Trim());
}
// Add text to the PDF at the given coordinates
//pdfMend.AddText(ext, (int)pageNumber, x, y);
Boolean textAdded = pdfMend.AddText(ext, (int)pageNumber, x * MMs_to_POINTs, y * MMs_to_POINTs);
pdfMend.Close();
UpdatePDF(resultStream);
// … then I read all the bytes of the PDF stream, and save it to file
FileStream file = File.OpenWrite(“JanderNauer2.pdf”);
// this function read all bytes of a stream:
byte[] arr = PDFRender.ReadFully(resultStream, 0);
file.Write(arr, 0, arr.Length);
file.Flush();
file.Close();

Regards.

Hi,

It has been logged as PdfKitNet-5408 in our issue tracking system. We'll try to resolve it ASAP.

Thanks,

Hi,

The issue is resolved, please download and try the attachment 'Aspose.Pdf.Kit.dll' in thread <A href="https://forum.aspose.com/t/126657</A>.</P> <P>Thanks,</P>

Hello,

The problem is solved for the several tests that I have made.

Good job :slight_smile: