Copy link to clipboard
Copied
Hi all, I have an InDesign document that is all in UK English, and I need to make a US version.
What's the best way to do this please? I've changed the Paragraph and Text styles to English: USA, but it isn't flagging up with the usual red underline existing text to change to US. Such as "colour" and "organisation"...
Any help much appreciated. Thanks.
Copy link to clipboard
Copied
Once you have changed the Language of the text in the docuement, run the spell-check.
Copy link to clipboard
Copied
Yes, that's doable, am looking for a quicker way to do this though, thanks for the tip though 🙂
Copy link to clipboard
Copied
Language is a character level attribute—you could have two languages inside of a single word. If you are on OSX this AppleScript should get everthing:
set lang to "English: USA"
tell application id "com.adobe.indesign"
set pstyles to all paragraph styles of active document
repeat with i from 1 to number of items in pstyles
try
set applied language of item i of pstyles to lang
end try
end repeat
set cstyles to all character styles of active document
repeat with i from 1 to number of items in cstyles
try
set applied language of item i of cstyles to lang
end try
end repeat
try
set applied language of every paragraph of every story of active document to lang
end try
try
set applied language of every paragraph of every cell of every table of every story of active document to lang
end try
end tell
Copy link to clipboard
Copied
Damn, I'm using PC !
Copy link to clipboard
Copied
Here‘s a JS version
var theLanguage = "English: USA";
var pStyles = app.activeDocument.allParagraphStyles;
var cStyles = app.activeDocument.allCharacterStyles;
var pg = app.activeDocument.pages;
for (var j=pStyles.length-1; j > 0; j--){
pStyles[j].appliedLanguage = theLanguage;
}
for (var k=cStyles.length-1; k > 0; k--){
cStyles[k].appliedLanguage = theLanguage;
}
for (var i = pg.length-1; i >= 0; i--) {
for (var h = 0; h <= pg[i].textFrames.length-1; h++) {
app.activeDocument.pages[i].textFrames[h].parentStory.appliedLanguage = theLanguage;
if (app.activeDocument.pages[i].textFrames[h].tables.length != 0) {
for (var q = app.activeDocument.pages[i].textFrames[h].tables.length-1; q >= 0; q--){
app.activeDocument.pages[i].textFrames[h].tables[q].cells.everyItem().texts.everyItem().appliedLanguage = theLanguage;
}
}
}
}
Copy link to clipboard
Copied
Tried, saving this to a JS file, can see it in the Scripts folder in InDesign, but it's showing errors.
Copy link to clipboard
Copied
Hi there,
Thanks for reaching out. I found a similar discussion on the community, please refer to the below discussion:
https://community.adobe.com/t5/indesign/change-spelling-of-uk-document-to-us-english/td-p/10187461
Regards
Rishabh
Copy link to clipboard
Copied
I've changed the Paragraph and Text styles to English: USA, but it isn't flagging up with the usual red underline existing text to change to US. Such as "colour" and "organisation"...
Is it flagging any misspelled words? The red/green squiggles are visible when Dynamic Spelling is enabled under Edit > Spelling, and it is not on as a default. If the paragraphs have been assigned US English and Dynamic Spelling is enabled and if you are in View > Screen Mode > Normal, those words should be flagged.
~Barb
Copy link to clipboard
Copied
Hi, thanks for the response.
I have Dynamic on already and certain words are highlighted in red, just not the UK/US ones.
Copy link to clipboard
Copied
Go to Edit > Spelling > User Dictionary
~ Jane
Copy link to clipboard
Copied
Thanks Jane-e, appreciating all your help here 🙂
Copy link to clipboard
Copied
I've changed the Paragraph and Text styles to English: USA,
To make sure that all text in the document is changed, use Find/Change (GREP). Put just a Period in the Find field and $0 in the Change to field. In the Change format, choose Advanced Character Fomats, adn choose English : USA
This will find every bit of text in your docuement and change its language to US English
Copy link to clipboard
Copied
This seems good, just a quick question - What do I put in the 'Find what:' field ?
thanks
Copy link to clipboard
Copied
The period [ . ] is a wildcard for "Any Character".
Copy link to clipboard
Copied
ah great, thank you 🙂
Copy link to clipboard
Copied
It's still missing out words even with the GREP info in, very strange.
Copy link to clipboard
Copied
In addition to what's been said, you will need to read the document after you have run spell check. There are some words that the Brits use that will be spelled correctly but will be the wrong word in American English.
A few examples:
These are just a few (very few) of the words that won't make sense in American English.
~ Jane
Copy link to clipboard
Copied
Also
• Lift (elevator)
• Boot (car trunk)
Copy link to clipboard
Copied
And a few more that won't be found by Spell Check:
Copy link to clipboard
Copied
Hi Rob,
you assigned the name of a language to appliedLanguage wheras you need an [object LanguageWithVendors].
One could handle this easily if Robtowler, our OP, is selecting a character with US English applied for language and work like that:
// Select one single character with the language you like to use:
var theLanguage = app.selection[0].appliedLanguage;
The rest of the code should work like intended.
Regards,
Uwe Laubender
( ACP )
Copy link to clipboard
Copied
Thanks
Find more inspiration, events, and resources on the new Adobe Community
Explore Now