Hello everyone
I need to create a font sample of all activated fonts in Illustrator CS3.
Any help will be appreciated.
Thanks
Kostas
Browser: Safari 523.12.2
Operating System: Mac OS X (10.5)
Hello everyone
I need to create a font sample of all activated fonts in Illustrator CS3.
Any help will be appreciated.
Thanks
Kostas
Browser: Safari 523.12.2
Operating System: Mac OS X (10.5)
Hi
Not sure if this is exactly what your after, I didn’t write it
and i’m not sure where i got it from.
But hope it helps:
tell application "Adobe Illustrator"
activate
make new document
set fontcount to count text fonts
set x to 1
set startx to 10
set starty to (height of document 1) - 10
repeat with i from 1 to fontcount
make new text frame in document 1
set fontname to name of text font i
try
if fontname is not name of text font (i + 1) then
set posx to startx
set posy to starty - (x * 15)
make new text frame in document 1 with properties {contents:fontname, position:{posx, posy}}
set the text font of text of the result to text font i
set x to x + 1
if x > 50 then
set startx to startx + 220
set starty to (height of document 1) - 10
set x to 1
end if
end if
end try
end repeat
end tell
Thank you for your reply, but the script you provided results only with the name of the Font. I need the name of the font, and a sample text below.
Thanks again
Kostas
Hi
Thats strange when run on my machine it creates the name of the font in the actual typeface.
Sorry, stupid of me. It does creates the font in the actual typeface, but I also need a sample text below.
Thanks
K
Hi
Does this work for you?
tell application "Adobe Illustrator"
activate
make new document
set fontcount to count text fonts
set x to 1
set startx to 10
set starty to (height of document 1) - 5
repeat with i from 1 to fontcount
make new text frame in document 1
set fontname to name of text font i
try
if fontname is not name of text font (i + 1) then
set posx to startx
set posy to starty - (x * 15)
set thetext to make new text frame in document 1 with properties {contents:fontname & return & "Sample text", position:{posx, posy}}
set the text font of text of the result to text font i
set x to x + 1
if x > 50 then
set startx to startx + 150
set starty to (height of document 1) - 5
set x to 1
end if
end if
tell thetext
tell paragraphs 1 thru 2
set the size to 6
end tell
end tell
end try
end repeat
end tell
Î¥es it does.
Thank you very much!