Question Details

No question body available.

Tags

c# pdf pdfpig

Answers (1)

Accepted Answer Available
Accepted Answer
February 3, 2026 Score: 8 Rep: 153 Quality: Expert Completeness: 80%

I am using SlapKit but it's compatible with PdfPig so it should be the same.

Even using Letter, start and end baseline's won't be enough if you want to get precise with ascent's and descent's. You will have to go for the Letter's GlyphRectangle part. I just went with fontsize: 6 and line height: 6 because you didn't say what were your sizes.

Here is the G and its glyph rectangle:

enter image description here

Same with y and its glyph rectangle,y was the closest to the bottom line.

Look at the difference in bottom's between them. Nearly 30%.

enter image description here

Just for information, here is how their Letter EndBaseLine's look. My second suggestion would be if you can do it, play around with line heights according to font sizes. Maybe do them 20%-30% bigger according to the fonts that are entered and don't let the users choose them ?

enter image description here