5

In a sample document, there are a bunch of styles (in Garamond) based on Plain Text (Courier). I would like to change those styles to another font (Georgia, for example).

Since the styles in question are in Garamond but all based on Courier (from Plain Text) i would guess that each of the styles has had their fonts changed individually. Which makes me think i have to change each to the new font individually.

But... that can't be the only way to do this, right? There must be a way to make a wholesale font change to a group of styles like this. Or is there maybe something missing from my picture of how styles work.

If it matters, i'm using Word 2007.

Edit: I am not asking about replacing fonts with Control-H, unless you have a way to subsequently apply those changes to the affected styles.

Preferably the solution would be one that i could later explain to less-technical users how to do the same. So while the VBA solution might solve the problem for me this time, it is limited to script-savvy users.

3 Answers 3

1

I think the only way of redefining propeties of a large set of styles in one go would be to automate using VBA.

What I would do here instead is redefine an underlying style (probably Normal rather than Plain Text, as Normal is the default for new text in a blank document) with the base properties of your document's text (language, Garamond font, size, line spacing and perhaps paragraph spacing) and change the other styles to be based on that.

This will give you more maintainable set of styles in the longer run.

If all your headings are going to be a different font, say Helvetica, you might want to set say Heading 6 as that font and base all other headings on that, but I don't think there's much need to use a much more complex model of 'inheritance'.

5
  • Redefining underlying styles won't work, because only one or two are based on Normal. The rest are based on Plain Text with a font applied on top of it. VBA sounds plausible, though it isn't my preferred approach; if it comes up again, i'd like to be able to describe the "how-to" to less technical users.
    – b w
    Nov 23, 2009 at 11:10
  • Sure - this was a longer term solution.
    – e100
    Nov 23, 2009 at 15:22
  • Accepting for VBA automation solution. Looks like the only way.
    – b w
    Feb 3, 2010 at 17:52
  • @bw: did you find a solution? Could you share the VBA code for that task? Jan 3, 2019 at 17:33
  • @ThomasWeller, wow, had to re-read all this. I think i gave up on this one. If i was going to attempt to solve this (assuming it's still an issue) today, i'd probably choose something along the lines off what AdamV suggested.
    – b w
    Jan 17, 2019 at 16:33
2

To wholesale replace fonts in Word :

  • Open the Replace dialog
  • Click inside the "Find what" field (but don't type any search string)
  • Click on the More button
  • Click on the Format button and choose Font
  • Choose your font name (you may also set style and size for finer control)
  • Click OK
  • Click inside Replace with (but don't type any search string)
  • Repeat the process for choosing the replacement font
  • Click Find Next plus Replace or click Replace All, to execute the replacement.
3
  • That doesn't work for me: "0 replacements." Besides, it doesn't address swapping fonts in styles, which is what i want to do. I want the fonts in the styles to be changed.
    – b w
    Nov 23, 2009 at 10:56
  • "0 replacements" is because you're using the fonts implicitly thru styles, so the above technique doesn't apply to your problem.
    – harrymc
    Nov 23, 2009 at 11:04
  • Right. The original question was about changing fonts in styles.
    – b w
    Nov 23, 2009 at 11:26
1

If the inheritance from one style to another has been overridden explicitly with a different font in each one, you are stuck with changing it back in each one. However, if this is a .dotx template, you could do this with some find-and-replace in the xml of the file which will probably be quicker than figuring out a way to do this with VBA.

Best book for any of this kind of work when busting open the 2007 file formats is Advanced Office Documents 2007 edition by Stephanie Krieger

Aside: while it won't help reduce the effort this time round, the 'right' way to change these will be to choose or create a theme font set, with your chosen font for headings and for body text. Then in your styles choose 'Georgia (Headings)" or "Comic Sans (Body)" rather than the font face by itself. For lower-level styles base them on a previous one ideally (eg Heading 2 from Heading 1). Selecting the 'theme' fonts rather than explicit choices means that future changes are made far simpler by just changing the font set.

PS: please please please don't use Comic Sans for your body text.

2
  • How would i edit the dotx file to get at the XML? I've opened in VS2008, Ultraedit, and Notepad++ but it's not straight XML or it's encoded weird. Suggestions? I'll look into the theme font sets.
    – b w
    Nov 23, 2009 at 11:22
  • It's a zip file, so the first step is to rename it to add ".zip" so Windows will recognise it. Don't unzip / extract files as this won't work. Simply browse inside, take out the files you need (copy them out and paste elsewhere). Edit them, then copy and paste them back in, say yes to the prompt to overwrite. Rename to drop the .zip, job done.
    – AdamV
    Nov 24, 2009 at 21:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .