Dear Aspose-team!
Using Aspose.Words 9.1.0.0, one of our customer ran into a problem.
Although the original font DIN-Light is installed on the system, text inserted with Aspose.Words is changed to DIN-Regular.
Please find attached the template TMP.doc and the text module TXT.doc.
The text module is inserted into the template’s bookmark C5194Mod000000010000323R0000000006 by using the following insertion logic:
foreach (Node txmNode in txmSection.Body.ChildNodes)
{
...
Node tempTextModuleNode = wordDoc.ImportNode(txmNode, true,
ImportFormatMode.KeepSourceFormatting);
...
if (tempTextModuleNode is Paragraph)
{
Paragraph tempTextModuleParagraph = (Paragraph)tempTextModuleNode;
...
while (tempTextModuleParagraph.HasChildNodes)
{
currentInsertionNode = tempTextModuleParagraph.FirstChild;
documentBuilder.InsertNode(currentInsertionNode);
...
}
...
}
One idea:
Please take a detailed look at TMP.doc:
- Zoom it to 400%
- move to bookmark C5164Mod000000010000320R0000000005
Directly above the bookmark, you’ll find a section that is just 1 pt. high. It has custom style “fmtStd” while the TXM has style Standard.
Perhaps these different styles are in conflict and cause inconsistent documents (just an idea).
Please let me know if you require further information. Unfortunately, I cannot pass the original rendered document because it contains customer data.
Thank you very much for your help,
cheers,
Stephan