Highlighted

Finding fonts status, and Link (Placed item) status in Illustrator document

Community Beginner ,
Oct 23, 2020

Copy link to clipboard

Copied

Hi

I am trying to get the below details as report from Illustrator, but these are all working in InDesign application, but I am unable to get the below details in illustrator. Can you please check and help me out from this?

1. List of fonts and fonts status (missing, installed, etc.) in particular document. Below coding is for InDesign.

var myDoc = app.activeDocument;

var fontList = myDoc.fonts;

for(var i=0; i<fontList.length;i++) {

alert(fontList[i].name+" Status is "+fontList[i].status);
}

2. Images (PlaceItems [ai,psd,tif,jpg,PDF]) status (linked, missing, etc), and its scaling details (X and Y).

TOPICS
Scripting

Views

42

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more

Finding fonts status, and Link (Placed item) status in Illustrator document

Community Beginner ,
Oct 23, 2020

Copy link to clipboard

Copied

Hi

I am trying to get the below details as report from Illustrator, but these are all working in InDesign application, but I am unable to get the below details in illustrator. Can you please check and help me out from this?

1. List of fonts and fonts status (missing, installed, etc.) in particular document. Below coding is for InDesign.

var myDoc = app.activeDocument;

var fontList = myDoc.fonts;

for(var i=0; i<fontList.length;i++) {

alert(fontList[i].name+" Status is "+fontList[i].status);
}

2. Images (PlaceItems [ai,psd,tif,jpg,PDF]) status (linked, missing, etc), and its scaling details (X and Y).

TOPICS
Scripting

Views

43

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Oct 23, 2020 0
Adobe Community Professional ,
Oct 23, 2020

Copy link to clipboard

Copied

InDesign Script won't work in Illustrator, both applications have their own scripting api. They're not compatible with each other.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 2
Community Beginner ,
Oct 23, 2020

Copy link to clipboard

Copied

Thanks for the replies. Actually, I too know that, if you know about
equivalent illustrator coding, then can you please guide me? I am
struggling to where am I get that script API. It's more useful if you share
the link for illustrator script API.

Thanks

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 0
Adobe Community Professional ,
Oct 23, 2020

Copy link to clipboard

Copied

Hi,

Below is the link where you have read about script API. 

https://illustrator-scripting-guide.readthedocs.io/

Best regards

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 0
Asuvath LATEST
Community Beginner ,
Oct 23, 2020

Copy link to clipboard

Copied

Thanks. I am looking there, and check whether am I get solution for my issues.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 0
Adobe Community Professional ,
Oct 23, 2020

Copy link to clipboard

Copied

Hi,

You will get list of fonts in Illustrator using

 

app.textFonts

 

Following snippet will give list all list of fonts

 

var fontList = app.textFonts;

for (var i = 0; i < fontList.length; i++) {
    $.writeln(fontList[i].name);
}

 

For placedItems in Illustrator (Links in Indesign), you can access placedItmes as

var placedItems = app.activeDocument.placedItems;

 

This will return all placedItems exists in the document. You can read about this more from the following link

https://illustrator-scripting-guide.readthedocs.io/jsobjref/PlacedItem/?highlight=placedItems

 

 

Best regards

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 3
Community Beginner ,
Oct 23, 2020

Copy link to clipboard

Copied

Hi,

Thanks for reply.

Actually I need the font report and it's status (missing status) for
active document only, not for whole illustrator fonts. The code
app.textFonts give whole illustrator fonts. I need only the fonts list that
shows as in find font menu in active document alone. Like how will get it
from InDesign.


Regarding the links, I can get links name. But I need the details for how
do I get missing links report and scaling details for all the images which
are all in the active document.

Can you please check and help me?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
Reply
Loading...
Oct 23, 2020 0
Resources