Hello,
in this post “Conversion produces different PDF on different platform” a new property has been introduced for the folder where Aspose.Cells searches for fonts.
Is there something similar for other components of Aspose.Total? In particular, I need a similar mechanism for Aspose.Words, but it would be useful to have it for other components as well.
Hi Mario,
Document.getLocalFontPath () // shows the system folder in which project will
look for fonts.<o:p></o:p>
Document.setLocalFontPath (String) // Setting font path to custom folder
//adding a new font path
String path = "c:\\fonts\\";
com.aspose.pdf.Document.addLocalFontPath(path);
The following code snippet to set font path if there are more than one font path.
//geting the list for standard font directories in different OS
java.util.List list = com.aspose.pdf.Document.getLocalFontPaths();
//seting the user list for standard font directories
list.add("c:\\fonts2\\");
list.add("c:\\fonts3\\");
com.aspose.pdf.Document.setLocalFontPaths(list);
//Restoring list for standard font directories by default.
com.aspose.pdf.Document.restoreLocalFontPath();
Hello,
sorry for answering only now, I was busy on other tasks.
Your suggestion seems to work satisfactorily.
Thanks!
Hi Mario,