I must be silly but I have searched the web for hours and could not find a solution to my "simple" problem:
I would like a script to do this:
1. set font (eg MT Extra)
2. insert a character based on unicode (eg F080)
3.revert font to previous font
This vould allow me to insert any character of any font and then continue typing my text with the regular font.
Thank you for our help
For something basic like this you should check out the documentation that comes with ESTK, under the Help menu. "Adobe Intro to Scripting" is a good place to start.
Anyway, assuming you've got your text cursor blinking in some text, try this:
myIP = app.selection;
myIP.contents = "\uf080";
myIP.appliedFont = "MT Extra";
Thank you for your advice.
I started to read the documentation and used a part of your code and I was able to reach my goal. I had never used java script before so it took quite a lot of time but I am happy now.