Copy link to clipboard
Copied
Hi,
In my document there is no fonts missing as manual. But when i get font list using code, its showing missing font.
Code:
var usedFonts = app.activeDocument.fonts;
var myArray = [];
for(var i = 0; i < usedFonts.length; i++){
if(usedFonts.status == FontStatus.NOT_AVAILABLE){
myArray.push(usedFonts.name);
}
}
if (myArray.length != 0) {
alert('Document contains missing fonts. Job aborted!\r' + 'Unavailable fonts:\r' + myArray.join('\r'));
exit();
}
If i use FontStatus.INSTALLED (ie., not installed) the same result i get. I dono why??
Copy link to clipboard
Copied
Hi Sudha,
do a list of all fonts with name, status and location you get with usedFont and compare that list to the one you see in Find Font.
Maybe both lists are different.
Regards,
Uwe
Copy link to clipboard
Copied
Hi,
When finding location of the fonts, its throwing error. When I check it manually, extension of the font is .dfont.
I am using this code to get missing font till now but now raising some questions. Which case to use to missing fonts.
In scripting, it has multiple options (not availabe, substitued, installed etc..) which one to use to get missing font??
Copy link to clipboard
Copied
Hi Sudha,
ah, a .dfont is used!
For any publication never use a .dfont .
That's a Mac OS X system font resource and cannot be transferred to Windows.
Regards,
Uwe
Copy link to clipboard
Copied
Hi,
In this case wat do to?? ie., how to handle this??
In that document, this fonts creates this issue...
Copy link to clipboard
Copied
Hi Sudha,
it would be best if the creator of the document would handle this and not using a .dfont.
You could try your best and substitute the font with something reasonable. But that should be communicated with the customer and the creator of the document. I see no automated solution.
Regards,
Uwe
Copy link to clipboard
Copied
The other way would to proceed on Mac OS X. By using a .dfont the creator of the document tied the document to Mac OS X. I see no legal way to transfer a .dfont to Windows.
Regards,
Uwe
Copy link to clipboard
Copied
Ok thank you...
Can you pls clarrify this?? What option is correct to check missing font in document??
I have used not installed to get missing font... but when i search in forum, not available is used to get missing fonts. Also marked correct answer but i think i get some error in that ... So i am very confused... Can you pls clarify this??