Script for finding double-applied italics
I'm in need of a script to try and solve a worfklow issue. We work with tagged text files poured into InDesign, in which editors tag what should be italic for emphasis or grammar (like a book title). However, if a designer chooses to set the containing paragraph style as italic, those italic tagged words need to be retagged as a roman style. This is hard to catch in every instance in a long document. The current workflow is to do a Find/Change for every word with an italic character style contained within the paragraph style that was defined as italic, but it has to be done for each paragraph style because you can't search for more than one paragraph style at a time. I thought there has to be a way to script this, but I'm not great at scripting.
This is basically what I would need:
If [character style: ITAL] is found in [Any Paragraph Style] that has [Italic] defined in Font Style, then replace [character style: ITAL] with [character style: roman]
Would anyone have any ideas on how to script this? Any help would be appreciated.
