From what you describe, it is probably a real mess under the skin; I've seen files like that.
The traditional "dynamite" approach to fix this is to copy all the text into a plain text editor to remove ALL the formatting. (Just using "remove formatting" in either Word or Writer is not guaranteed to get it all.) Then open the text file back in your word processor and re-format using styles.
Unfortunately, this will blow away italics, and that can be a real pain to put back in if they are used a lot. I found a work-around for this that I used on a book or two with good results. It's a nasty thing, but for what it's worth, I'll add it. I used Writer, but something similar could be done with Word:
1. Save the file as html.
2. Open the html file in a text editor (like gedit--any good text-only editor).
3. Identify all the code indicating italics. There may be several types of coding.
4. Use Search & Replace to replace all that code with some unused text marker. I think used #i for italics start and #/i for italics end. Save the html file.
5. Now open that html file again in the word processor. The text markers you put in will show up as text and no italics will appear.
6. NOW remove all formatting (select all and Ctrl-M for Writer). (Some odd things might be left behind that you will later have to fix by hand, but probably not much.)
7. Save the result again as an html file, and open it in the text editor.
8. Use search and replace to turn #i into <i> and #/i into </i>.
9. Now open the result back in the word processor. Italics should re-appear.
10. Now you can save it as docx or odt, and reformat paragraphs, headings, and so on, using styles.
As I said, it's ugly, but worth it if you have hundreds and hundreds of instances of italics.
Last edited by retiredbiker; 05-09-2021 at 11:29 AM.
|