What you have observed is correct: If more than half the text in the
paragraph has been applied bold, italics, underline or other types of direct
formatting, this formatting is overridden when you apply a style, otherwise
the direct formatting is preserved. See:
http://www.shaunakelly.com/word/stylesoverridedirectformatting/index.html
You could do as follows:
Highlight color is not overridden when you apply a style no matter the
amount of text highlighted in a paragraph. You can take advantage of this:
1. In the highlight icon, select a color that has not been used in the
document.
2. In the Find and Replace dialog (Ctrl+H), make sure the “Find what†and
“Replace with†fields are empty.
3. Click in the “Find what†field and press Ctrl+B (shortcut for Bold) –
make sure that “Font: Bold†is shown as the only format below the field.
3. Click in the “Replace with†field. Click the “More†button. Then select
Format > Highlight – make sure that “Font: Highlight†is shown as the only
format below the field.
4. Click “Replace Allâ€.
Now all your bold text should be formatted with the selected highlight color
(the bold formatting has not been removed).
Repeat the steps above for italic and underline (first select a unique
highlight color for each).
Now you can reformat your document. The highlight colors will remain. When
finished, use the “Find and Replace†dialog box to find the highlighted text
one bit at a time:
You could split the replacement in two steps: If the bold, italic or
underline is still there (because less than half the paragraph had direct
formatting or because of a bold style), you could start searching for text
that is “Font: Bold, Highlightâ€. Replace with “Font Bold, Not Highlightâ€
(select Highlight twice to display “Not Highlight†– first click “No
Formatting†to clear all formatting if needed). Click “Replace Allâ€. Repeat
for italic and underline.
Now you must apply bold, italic and underline to the text that is still
highlighted. In Find and Replace, you must find “Highlight†format and
replace with format “Font: Bold, Not Highlightâ€. Since the dialog box does
not distinguish between different highlight colors, you need to step through
the highlighted pieces one by one using the “Find Next†button and determine
whether to replace the found formatting with bold or not. Repeat for the
other two colors.
Note that it would be possible to write two macros that could do all the
above automatically – one for the preparation and one to reapply the
formatting.
Also note that if part of the text has e.g. both bold and italic applied,
you would need more variations of the highlight colors to keep track of this.
--
Regards
Lene Fredborg - Microsoft MVP (Word)
DocTools - Denmark
www.thedoctools.com
Document automation - add-ins, macros and templates for Microsoft Word