Hi!
I am currently evaluating the possibility to use the SystemFontsNativeRendering RenderingOption of Aspose.PDF. However, in the following scenario Aspose.PDF 8.3.0 generates distorted output:
1. Create a landscape PDF using MS Word 2007.
2. Rotate it using Aspose.PDF PageEditor.
3. Convert it to Postscript using Aspose.PDF PdfViewer using the SystemFontsNativeRendering RenderingOption.
To reproduce the problem, please consider the following example code and the attached PDF:
static void Main (string[] args)
{
SetLicense ();
var inputPath = @"…\SimpleLandscapeWord.pdf";
var outputPath = @"…\SimpleLandscapeWord.ps";
FontRepository.Substitutions.Add (new SystemFontsSubstitution (SubstitutionFontCategories.AllEmbeddedFonts));
using (var pageEditor = new PdfPageEditor())
using (var viewer = new PdfViewer ())
using (var editorStream = new MemoryStream())
{
pageEditor.BindPdf (inputPath);
pageEditor.Rotation = 90;
pageEditor.Save(editorStream);
viewer.BindPdf (editorStream);
viewer.RenderingOptions.SystemFontsNativeRendering = true;
var printerSettings = new PrinterSettings { PrintFileName = outputPath, PrintToFile = true, PrinterName = “PdfToPostscriptConverter” };
var pageSettings = new PageSettings
{
PaperSize = new PaperSize (“A4”, 827, 1170),
Margins = new Margins (0, 0, 0, 0),
PrinterSettings = printerSettings
};
viewer.PrintDocumentWithSettings (pageSettings, printerSettings);
viewer.Close ();
}
}
Kind regards,
Thomas