PDFRasterizer.NET 4.0 is now available. Supports .NET Core. Renders pixel-perfectly.

Font mapping

If you have a PDF document which uses non-embedded fonts, you can specify your own font substitution map to specify which fonts need to be used. Simply create a new RenderSettings object and add your substitution to it and use the object when rendering your document.

Page page = document.Pages[0];

// get a bitmap 4 time the size of the page. This is 288 DPI, almost 300
Bitmap bmp = new Bitmap((int) page.Width * 4, (int) page.Height * 4);
using (Graphics graphics = Graphics.FromImage(bmp))
{
   graphics.ScaleTransform(4.0f, 4.0f);
   renderSettings = new RenderSettings();
   renderSettings.TextSettings.FontSubstitutionMap.Add("TallComponents Demo Font", "ariali.ttf");
   page.Draw(graphics, renderSettings);
}
Download PDFRasterizer.NET 3.0
We will send you a download link

  • This field is for validation purposes and should be left unchanged.
Why do we ask your email address?
We send tips that speed up your evaluation
We let you know about bug fixes
You can always unsubscribe with one click
We never share your address with a 3rd party
Thank you for your download

We have sent an email with a download link.