@cgitechs Thank you for additional information. Unfortunately, I cannot reproduce the problem on my side. Here is document produced on my side using the latest 22.9 version of Aspose.Words: out.pdf (19.8 KB)
The problem might occur because Aspose.Words cannot find the fonts used in your document. Could you please ty implementing IWarningCallback to check whether Aspose.Words substitutes the fonts? This might give you a hint what the problem is.
I’ll Implement the IWarningCallback in a moment. Please see the attached image from opening the document in Word, the character should be a 3 layer character, but as you can see in your example, the top of the characters are overlapping.
Import of element \uc is not supported in Rtf by Aspose.Words.
Import of element * is not supported in Rtf by Aspose.Words.
Import of element \defpap is not supported in Rtf by Aspose.Words.
Import of element \additive is not supported in Rtf by Aspose.Words.
Import of element \uc is not supported in Rtf by Aspose.Words.
Transparency does not conform to PDF/A standard and has been removed.
This only appears to work if I have installed the arial-unicode-ms.ttf font in my C:\Windows\Fonts. Can you confirm it works with some other font? I have attached my program with the IWarningCallback that outputs “Arial Unicode MS font is used in the document. Line spacing could be rendered differently.” when I have the arial-unicode-ms.ttf font installed.AsposeTesting.zip (129.5 KB)
I was about to get the font to display by adding the below “foreach (Aspose.Words.Run run in doc.GetChildNodes(Aspose…” code. However, I’m not quite sure what it is doing to why it works. The run.Font.Name value is already set to Tahoma when I hit that line of code. I’m not sure what setting the value back to “Tahoma” actually does.
FontSubstitutionWarningCollector callback = new FontSubstitutionWarningCollector();
Document doc = new Document(@"..\..\in.rtf");
doc.WarningCallback = callback;
doc.LayoutOptions.TextShaperFactory = Aspose.Words.Shaping.HarfBuzz.HarfBuzzTextShaperFactory.Instance;
foreach (Aspose.Words.Run run in doc.GetChildNodes(Aspose.Words.NodeType.Run, true).OfType<Aspose.Words.Run>())
{
//3584,3711
if (run.Text.Any(a => a >= 3584 && a <= 3711))
{
run.Font.Name = "Tahoma";
break;
}
}
doc.Save(@"..\..\out.pdf");
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.
Sets consent for personalized advertising.
Cookie Notice
To provide you with the best experience, we use cookies for personalization, analytics, and ads. By using our site, you agree to our cookie policy.
More info
Enables storage, such as cookies, related to analytics.
Enables storage, such as cookies, related to advertising.
Sets consent for sending user data to Google for online advertising purposes.