I used Aspose Pdf version 17.2 for converting pdf with some text upside-down inside to html with embeded all resource. But the text in HTML can not display correctly.
using (Document pdfDocument = new Document(source))
{
// Instantiate HTML Save options object
HtmlSaveOptions saveOptions = new HtmlSaveOptions();
// Enable option to embed all resources inside the HTML
saveOptions.PartsEmbeddingMode = HtmlSaveOptions.PartsEmbeddingModes.EmbedAllIntoHtml;
// This is just optimization for IE and can be omitted
saveOptions.LettersPositioningMethod =
HtmlSaveOptions.LettersPositioningMethods.UseEmUnitsAndCompensationOfRoundingErrorsInCss;
saveOptions.RasterImagesSavingMode =
HtmlSaveOptions.RasterImagesSavingModes.AsEmbeddedPartsOfPngPageBackground;
saveOptions.FontSavingMode = HtmlSaveOptions.FontSavingModes.SaveInAllFormats;
saveOptions.FixedLayout = true;
saveOptions.PageBorderIfAny = new SaveOptions.BorderInfo(new SaveOptions.BorderPartStyle
{
LineType = SaveOptions.HtmlBorderLineType.Solid,
Color = System.Drawing.Color.Gray,
WidthInPoints = 1
});
pdfDocument.Save(singleHtmlFileName, saveOptions);
}
image.png (30.6 KB)
pastedImage (1).png (82.2 KB)
Could you help me to fix it ?
Thanks.