Copy link to clipboard
Copied
Hello all you clever guys
Im trying to make a script which sets some specific values for my letter and word spacing and glyph scaling.
But i dont want to apply it to a paragraph style. Im trying to set it default/general rule for paragraph styles, which haven't been created yet.
I found soooo many different post and threads, but only how to apply it to an existing style.
Can you guys help me?
You need text defaults for that. Realize, that your standard paragraph (don’t use basic paragraph in any case) has a plus-symbol after his name and that your settings can easily be overwritten. So I would think, that this is not the best workaround for setting defaults!
app.documents[0].textDefaults.minimumWordSpacing = 70;
–Kai
Copy link to clipboard
Copied
You can set this per document or at the App level.
Set Basic Paragraph to have those values. Set a shortcut key to Basic Paragraph. When you open any new doc, it begins with those values.
It's (virtually) the same as having a script that toggles it on, except writing a script would take you more time. The ONLY advantage in having it in script form is when you are in any Style you can toggle that on and create an override.
Copy link to clipboard
Copied
This is only a part of a bigger script, everything else is working fine.
How would the code look then? i feel like i tried everything like
app.activeDocument.minimumWordSpacing = 70;
app.minimumWordSpacing = 70;
and i can't use app.activeDocument.paragraphStyle.minimumWordSpacing = 70;
it seems i can't find a way to target it :s
Copy link to clipboard
Copied
You need text defaults for that. Realize, that your standard paragraph (don’t use basic paragraph in any case) has a plus-symbol after his name and that your settings can easily be overwritten. So I would think, that this is not the best workaround for setting defaults!
app.documents[0].textDefaults.minimumWordSpacing = 70;
–Kai
Copy link to clipboard
Copied
I understand that this can be overwritten and agree that this is a "bad" workaround.
Nevertheless i still want to see it through.
changed your code to this and now i works. Thanks dude
Copy link to clipboard
Copied
Fantastic. App-level default.
Copy link to clipboard
Copied
Jeppe, this will surely work on document level too.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now