bjoern hassler wrote:
I've been handed a document that has no styles defined at all. All styling is done the local character styles ("overrides") ...
If it were only bold, italics etc., you could use my preptext:
But it sounds like font names and sizes are also overridden. Is that correct? Is everything basically "No style, + Arial Bold + size: 24 + Leading 28"? If so, you need to distinguish between creating new paragraph and character styles. That is way more tricky because this manual formatting may not be applied to an entire paragraph, even though it should (a well known fault is to not include the final hard return).
The auto-char styles script tries to be semi-intelligent: It ignores the underlying paragraph style completely. Instead, for each paragraph, it checks which is the longest continuous run of formatting in that paragraph (textStyleRange). That formatting is considered the "underlying formatting of the paragraph", and any other formatting in that paragraph is considered an override, and has an appropriate character created (if necessary) and applied to it.
The only exception to that is "italics", which is always considered an override, even there is more italics than regular in the paragraph (something that can happen in a bibliography entry, for instance).
So, for instance, with the formatting you give as an example ("No style, + Arial Bold + size: 24 + Leading 28"), where everything but the final paragraph return has that applied, Auto-Char Styles will not apply a character style to most of the text, and apply an appropriate char style to the final enter only.
That way, "all" that remains is to go through the document creating and applying paragraph styles as necessary, knowing that all local overrides have been styled with an appropriate char style.
Thanks both for comments!
Yes, it's more than the italics/bold, but different size and colour as well.
I've tried auto-char styles, but for my documents, it
(1) Produces only character styles, no paragraph styles
(2) The character styles aren't applied to the characters, i.e. in the text still shows as "[None]".
Any further thoughts?
Ah - it's also possible that I misunderstood - auto-char style does not pick up the "dominant" style - but only the overrides, that makes sense!
(1) Correct: It produces only character styles, as the name suggests!
(2) Also true: As you write below, it only marks the changes from the
"dominant" formatting in each paragraph.
You might want to check out Power Styles, which is part of Blatner Tools, sold by DTP Tools. They are in the process of changing to a cloud subscription system, and they have a free pre-relase which you can download here. Details about Power Styles here. I've never used this plugin, but as far as I can tell, it might be exactly what you need.
Edit: The pre-release is only for CC and CC 2014, but I think you can get a trial version of Blatner Tools for earlier versions.
I guess I would need something that makes the same decision (para vs. character), but does also create the para styles!
This script Create Character and Paragraph Styles Automatically | Erica Gamet | InDesign Trainer and Speaker | Denver and Boulder, C… created some para styles for me, so perhaps I can use both in conjunction.
There also this
and the above metioned http://indesignsecrets.com/perfectpreptext-a-smart-way-to-style-local-formatting.php.
PwerStyles can produce both character and para styles. I've just run the respective tools, and it created a bunch of styles, so that seems to work!