Understanding Text, Line, and Fill Styles

If you’ve used styles in Microsoft Office Word to format documents, you understand what a time-saver they can be. You select some text, choose a style from the style list on the toolbar, and you’re done. Styles in Visio 2007 work in much the same way to give shapes a consistent look and make them easier to revise. However, in Visio 2007, you can apply styles to shapes as well as text. That difference makes Visio 2007 styles unique.

Think of a Visio 2007 style as a collection of text, line, and fill formats that have a name. For example, the Flow Normal style is applied to flowchart shapes to provide a consistent look. What the Flow Normal style actually applies is 8-point Arial text with 2-point margins, a black border with a specified thickness (line weight) around shapes, and solid white fill color in shapes. All Visio 2007 templates come with some styles built in. You can see the styles in the Style drop-down list on the Formatting toolbar, as Figure 23-1 shows. (To add the Style drop-down list to the Formatting toolbar, choose View, Toolbars, Customize and select the Commands tab; in the Categories section click Format Shape, then scroll down through the Commands list and drag the Style drop-down list—not the Style... button—from the Commands list to your toolbar.) The five styles that are always present are Guide, Normal, None, Text Only, and No Style.

Figure 23-1. The Style list on the Formatting toolbar displays all the built-in styles that come with a template; styles from the Basic Flowchart template are shown here.


Applying Styles from the Style Lists

Visio 2007 lists all styles in the Style list on the Formatting toolbar regardless of whether they apply a line, fill, or text format. However, you can also include style lists on the Format Text toolbar and Format Shape toolbar. You can display these toolbars by choosing View, Toolbars as Figure 23-2 shows. To put the Text Style, Line Style, or Fill Style drop-down lists on the Format Shape toolbar, choose View, Toolbars, Customize and select the Commands tab; in the Categories section click Format Shape, then scroll down through the Commands list and drag the Text Style, Line Style, or Fill Style drop-down lists from the Commands list to your toolbar. You can also apply themes using the Theme button on the Format menu. Unnecessary redundancy? As it turns out, there’s a method to this madness. Depending on which style list you work from, different formats can be applied, which matters when a single style specifies text, line, and fill attributes, and you want to apply only one set of attributes.

Figure 23-2. For quick access to line and fill styles, you can display the Format Shape toolbar (top). To apply text styles, display the Format Text toolbar (bottom). Style drop-down lists have been added to the Format Shape toolbar as described in the text.


For example, the Flow Normal style appears in Text Style, Line Style, and Fill Style lists, as Figure 23-3 shows. There is only one Flow Normal style, but its effects can differ depending on the list from which you select the style. Weird? Maybe, but it gives you flexibility. Here’s how it works:

Figure 23-3. A Visio 2007 style can appear in the Text Style, Line Style, and Fill Style lists. The list’s appearance shows you whether the style applies a text (left), line (center), or fill format.


  • Text Style If you apply a style from this list, and the style also specifies line and fill attributes, Visio 2007 asks you whether you want to apply the line and fill formats.

  • Line Style If you apply a style from this list, and the style also specifies text and fill attributes, Visio 2007 asks you whether you want to apply the text and fill formats.

  • Fill Style If you apply a style from this list, and the style also specifies text and line attributes, Visio 2007 asks you whether you want to apply the text and line formats.

Note

Visio 2007 also includes a Style list, but a better method of applying a style to all aspects of a shape is to use themes. You can access themes by clicking Format, Theme, or clicking the Theme button on the Formatting Toolbar.


Knowing how the style toolbars work will help prevent style mishaps. However, it’s hard to tell from the style name alone which type of formatting will be applied. Visio 2007 helps you out with a message, as Figure 23-4 shows. When Visio 2007 asks, “Do you want to apply all of the included formatting?” you have two choices, and both result in something being formatted:

Figure 23-4. If you select a style from the Fill Style list, Visio 2007 prompts you before applying the style’s line and text formats to the shape.


  • Click Yes to apply all formatting to the shape (and risk the possibility of unexpected behavior, such as a solid black shape).

  • Click No to apply formatting for the single attribute identified by the name of the style list. That is, if you click the style in the Line Styles list, choosing No applies only the line attributes of the style.

With either option, some formatting will be applied. You can’t cancel the action, but you can click Ctrl+Z to undo the results.

Checking a Style’s Attributes

To tell how many attributes a style applies, choose Format, Define Styles. (You must be in Developer Mode. Choose Tools, Options, select the Advanced tab, and turn on the Run In Developer Mode check box.) In the Style list, select the style you’re interested in. In the Includes area, you’ll see a check mark beside each attribute that the style formats.


Troubleshooting: Nothing happens when a style is applied to a shape

If you select a shape and apply a style, and nothing happens, the shape might be locked or guarded. Some shapes include built-in protections that prevent you from formatting them when the format might disrupt the shape’s smart behavior. Sometimes you can work around these protections, and sometimes you can’t. For details, see the section titled “Formatting Locked Shapes” later in this chapter.


Formatting Versus Applying Styles

For most people, the difference between applying a theme, applying a style, or manually formatting a shape is really just the command they use. For Visio 2007, the difference between manual formats and those applied by a style or theme is in how the change is stored. Now we’re talking file mechanics, and this is an interesting topic only if you plan to design your own templates or want to understand how actions on the drawing page affect shape formats. The Visio 2007 term for the formats you apply manually is local formatting—“local” because the changes affect settings that Visio 2007 saves with each shape. You apply a local format when you select a shape and use a toolbar button or command on the Format menu to change the appearance of text, line, or fill. In contrast, a theme or style applies a global format, because Visio 2007 stores all the style definitions for a diagram in one place—that is, globally. If you’re working with a diagram that contains many shapes, you’ll get better performance if you use themes rather than local formatting to format your shapes.

Troubleshooting: When you copy shapes to another Visio 2007 drawing file, their formatting changes

If you created or edited themes (or styles for that matter) in your Visio 2007 diagram, and then copied it, or parts of it, to another Visio 2007 diagram, formats specified for the new diagram can override those in your shapes. This happens when the destination diagram has a style of the same name as the one you used to format your shapes. If the style in the new diagram is defined to format shapes differently, its styles will be applied to your shapes. To avoid reformatting, you can redefine your styles in the original Visio 2007 diagram to match those of the target diagram, or you can rename your Visio 2007 styles so that your style will be used. For details, see the section titled “Creating and Editing Styles” later in this chapter.


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset