Controlling Shapes with Layers


Layers are essential in multiple-page drawings or diagrams that contain many shapes. Layers help you organize related shapes on a drawing page so that you can work with and view shapes according to their layer assignment. For example, you can create a detailed drawing that includes electrical outlets, computer networking details, furniture layouts, and more, and then use layers to display selected information. When you want to rearrange the furniture, you can hide electrical outlets and computer networking details. When you’re most interested in your drawing’s electrical outlets, you can hide everything else. Not only does this help you see the big picture electrically, but it keeps you from rearranging other objects accidentally, such as furniture, when you’re positioning those outlets. You can hide, lock, print, count, snap, or glue shapes based on their layer assignment.

About Layers

Layers might not be what you think they are based on your experience with other layout or design programs. Visio layers are not stacking order. Layers don’t control which shapes appear in front and in back. Layers don’t really work like stacks of transparencies. They’re more of a concept for grouping or cataloging shapes. Technically, a layer is a named category to which you can assign shapes. For example, you can create a Furniture layer in a floor plan. The layer doesn’t do or mean anything unless you assign a shape to it. Let’s say you assign all the desks and chairs to your Furniture layer, but not the walls and cubicle panels. Now the layer becomes useful. For example, you can hide all the shapes on the Furniture layer to make it easier to work with just the walls.

Besides hiding and showing shapes, layers can be used to protect your work. You can lock a layer so that none of the shapes assigned to it can be edited. Unlike other applications, Visio lets you assign a shape to more than one layer. Those cubicle panels can belong to both a Walls layer and a Moveable Furniture layer. Because layers are the property of a drawing page, in a multiple-page drawing, the layers you create for one page don’t appear on any other pages—but if you need them to, see “Using Layers in Multiple-Page Diagrams,” page 469.

Using Shapes with Preassigned Layers

You don’t have to create layers to take advantage of them. When you start a diagram with a Visio template, you might find that your drawing already includes layers. Many Visio masters are already assigned to layers, so when you drop them onto the page, the layer is added as well. For example, when you open the Office Layout template, the masters are already assigned to layers. As you drop instances of the masters, the layers are created automatically. A room shape is assigned to the Spaces layer; its dimension lines are assigned to the Dimensions layer; and the outline of the space is assigned to the Building Envelope layer. The Layer box on the Format Shapes toolbar displays the layer to which a selected shape is assigned, as Figure 16-37 shows. If the shape is assigned to more than one layer, Multiple Layers is displayed in the Layer box.

click to expand
Figure 16-37: In an office layout diagram, the Format Shapes toolbar displays the layers to which selected furniture shapes are assigned—in this case, the Movable Furnishings layer.

Follow these steps to select all the shapes on a layer:

  1. Choose Edit, Select By Type.

  2. In the Select By area, choose the Layer option.

    click to expand

  3. In the Layer list, select the layer that contains the shapes you want. To select more than one layer, press Ctrl+click. To select shapes that aren’t assigned to any layer, choose No Layer.

  4. Click OK.

    Visio selects the shapes assigned to the layer.

start sidebar
Layers for CAD Users

Layers in Visio differ from layers or levels in CAD programs in some key ways. Think of layers as an organizing principle rather than stacked sheets of paper or Mylar sheets on a drafting table. Because they’re used to organize, Visio layers don’t affect which shapes appear in front or in back. They can offer different views of a diagram inasmuch as you can hide and show shapes according to the layer they’re assigned to. Here are several basic truths about Visio layers that often surprise CAD users:

  • A shape can be assigned to more than one layer.

  • A shape can belong to no layer.

  • A Visio drawing can have no layers.

  • You can’t group layers. (Some CAD programs offer group layer management, where several layers can be given a group name.)

end sidebar

Viewing Layers in a Diagram in the Drawing Explorer

You can see all the pages in your diagram, including all the shapes and layers on each page, in the Drawing Explorer window. To display it, choose View, Drawing Explorer Window. To see details about pages and layers, double-click the Foreground Pages folder, and then double- click the page you’re currently working on (or Page-1 if you haven’t added or renamed any pages). Double-click the Layers folder. If nothing happens, your drawing contains no layers. Otherwise, Visio lists all the layers on the page. If you expand a layer, you can see all the shapes assigned to it, as Figure 16-38 shows.

click to expand
Figure 16-38: You can see all the layers on a page—as well as all the shapes assigned to that layer—in the Drawing Explorer window.

In the Drawing Explorer window, you can quickly make a layer visible or active: right-click the layer, and then select the option you want. You can also delete layers with this method (which does not delete the shapes on the layer). When you make a layer active, each shape you subsequently add to the diagram is assigned to that layer automatically.

Creating Layers in a Diagram

You can create your own layers to add to the ones Visio supplies or add layers to a drawing that doesn’t include them already. When you create a new layer, it is added to the current page only, not to other pages in your diagram. You can define new layers as you insert new pages into a diagram. Or, you can just copy shapes with layer assignments from one page to the new page—when you paste the shape, any layers it’s assigned to are added to the new page. Visio is smart enough to know if the page already has a layer with the same name and adds the shape to the existing layer.

Follow these steps to create a new layer:

  1. Choose View, Layer Properties. Or click the Layer Properties button on the View toolbar.

    click to expand

  2. Click New to open the New Layer dialog box.

  3. In the Layer Name box, type a name for the new layer, and then click OK.

  4. In the Layer Properties dialog box, select the options you want for the new layer, and then click OK.

    For example, if you select Active, all shapes you subsequently add to the diagram are assigned to the new layer automatically (until you designate a different active layer.)

start sidebar
Inside Out
Deleting empty layers

The Remove Unreferenced Layers check box in the Layer Properties dialog box is a quick way to delete layers to which no shapes are assigned. This option is primarily intended to help you clean up your drawing files.

end sidebar

Assigning Shapes to Layers

Of course, layers are only useful if some shapes have been assigned to them. You can assign a shape to more than one layer, or you can leave a shape unassigned. To assign an individual shape to a layer or layers, follow these steps:

  1. Select a shape, and then choose Format, Layer.

  2. Click the layers you want to assign to the shape. Press the Ctrl key as you click to select multiple layers.

  3. Click OK.

If the Format Shapes toolbar is visible, you can select a shape, and then select a layer from the drop-down list in the Layer box.

Note

You can’t add shapes to a locked layer. A layer is locked when you select the Lock option in the Layer Properties dialog box (choose View, Layer Properties).

Assigning Visio Masters to Different Layers

Many master shapes are already assigned to layers, but you can change those assignments. This is worth doing if you frequently use shapes from a Visio stencil that are preassigned to layers you don’t use. For example, if you find yourself creating the same new layer every time you start a new office layout, consider adding your shape to a custom stencil. Let’s say you always assign panel shapes to a Cubicle layer. You can save your edited panel shape on a custom stencil, effectively creating a new master panel shape with your Cubicle layer. Every time you add that shape to a drawing page in the future, the Cubicle layer is added to the page.

As an alternative, you can edit one of the existing masters to reassign its layers. To do this, right-click a stencil title bar, choose Edit, and then edit any of the master shapes. You can then save your changes as a new stencil or with the original stencil. Note that in Visio 2003, you can only edit stencils that you have created (custom stencils). You cannot edit the stencils that ship with the software. To create a custom stencil, click the Shapes button on the Standard toolbar, and then select New Stencil. On the other hand, you can also choose Files, Shapes, New Stencil.

When you edit a master shape, Visio opens a master drawing page and displays all the commands that apply, including Format, Layers (where you can assign the master to a new layer) and View, Layer Properties (where you can rename an existing layer). Editing masters is just like editing shapes once you’re working in the master drawing window.

Cross-Reference

For details about how to open stencils and edit masters, see “Creating a New Stencil,” page 625.

Assigning Groups to Layers

To assign a group to a layer, first group the shapes and then choose Format, Layer and select the layer to which you want to assign the group. All of the group members are assigned to the new layer, and their previous layer assignments are canceled. If you want the individual shapes to retain their current layer assignments, select the Preserve Group Member Layers check box in the Layer dialog box. For example, you might group a prep cart and a microwave oven and then assign the group to the Kitchen layer but also want the prep cart to remain on the Furniture layer and the microwave on the Appliances layer.

Working with Active Layers

If you add a shape that doesn’t already have a predefined layer assignment to a page, the shape is assigned to the active layer automatically. By making a layer active, you can quickly add shapes to a diagram and assign them to a layer all at once.

Note

Make a layer active If you keep the Drawing Explorer window open (choose View, Drawing Explorer Window) when you’re working in a drawing with layers, you can quickly select the active layer by right- clicking a layer in the Drawing Explorer window, and then choosing Active.

To specify the active layer, choose View, Layer Properties, and then click in the Active column of each layer that you want to make active, as Figure 16-39 shows.

click to expand
Figure 16-39: Click in a layer’s Active column to make it the active layer. More than one layer can be active at a time. You can’t make a locked layer the active layer.

start sidebar
Inside Out
Working with the active layer

When you’re working with active layers, remember to reset the active layer as you work so that new shapes are added to the appropriate layer. For example, before adding electrical outlet shapes to a drawing of an office layout, make the Power/Comm layer active.

Don’t bother to specify an active layer if you’re only using Visio master shapes, such as those on the Walls, Doors And Windows stencil. They’re already assigned to the correct layer anyway. If you don’t specify an active layer, new shapes are not assigned to any layer unless you’re using a master shape with a built-in layer assignment.

end sidebar

Using Layers to Protect, Hide, and Organize Shapes

After you have assigned shapes to a layer, you can work with them as a group. You can lock them against editing, hide them temporarily from view, set entire layers to not print, and determine whether other shapes can snap or be glued to them. For example, while you’re adding furniture to an office layout, you might want to disable snapping for all the shapes on the Power/Comm layer so that desks don’t snap to electrical outlets. Then, you can disable printing for all the shapes on the Furniture layer to print a copy of the diagram that shows only the walls and wiring.

To specify options for each layer, you must work in the Layer Properties dialog box, as shown in Figure 16-40. You can open the Layer Properties dialog box in several different ways, depending on which windows and toolbars are available:

  • Choose View, Layer Properties.

  • Click the Layer Properties button on the View toolbar.

  • Right-click the Layers folder in the Drawing Explorer window, and then choose Layer Properties.

    click to expand
    Figure 16-40: To work with all the shapes assigned to a layer, choose View, Layer Properties, and then click in a column to enable an action, such as Snap, for a layer.

    Tip

    To count the number of shapes assigned to a specific layer, click the # button to the right of the Name column.

Table 16-7 describes the options that are available for shapes assigned to layers.

Table 16-7: Options for Layer Properties

Option

Description

Visible

When checked, all the shapes assigned to the layer are displayed. Clear to temporarily hide shapes.

Print

When checked, shapes assigned to the layer appear when you print the page. When cleared, shapes assigned to the layer don’t print, a useful technique when you want to print different parts of a drawing for different audiences. If a shape is assigned to multiple layers, you must cancel the Print option for every layer the shape is assigned to for the behavior to work.

Active

When checked, makes the layer the active layer. For details, see the previous section, “Working with Active Layers.”

Lock

When checked, shapes assigned to the layer cannot be selected, moved, or edited, and the layer cannot be set as Active. You cannot add shapes to a locked layer.

Snap

When checked, you can snap shapes to the shapes assigned to the layer. When cleared, the shapes assigned to the layer cannot be the target of snapping, although the shapes themselves still snap. If a shape is assigned to multiple layers, you must cancel the Snap option for every layer the shape is assigned to for the behavior to work.

Glue

When checked, you can glue shapes to the shapes assigned to the layer. When cleared, the shapes assigned to the layer cannot receive connections (that is, other shapes cannot be glued to them), but any connectors on the layer can still connect and glue to other shapes. If a shape is assigned to multiple layers, you must cancel the Glue option for every layer the shape is assigned to for the behavior to work.

Color

When checked, the Layer Color list box appears in the Layer Properties dialog box, and all shapes assigned to the layer are highlighted in the selected color. Each layer for which this option is selected can be displayed in a different color. The color temporarily overrides the shape’s original color. If a shape is assigned to multiple layers, it always appears in its original color unless you specify the same color for each layer to which the shape is assigned.

start sidebar
Inside Out
Nonprinting or locked layers

If your drawing includes nonprinting or locked layers, enable the Color option for those layers, and then choose a color (for example, gray for nonprinting layers and red for locked layers). That way, you’ll have a visual reminder on the page that the shapes have special attributes.

end sidebar

Using Layers in Multiple-Page Diagrams

In many diagram types with multiple pages, a repeating element can appear on all pages. Maybe it’s something as simple as a corporate logo or title block. You can place such elements on a background page and then assign that background to every foreground page on which you want it to appear. In technical drawings, you can get even fancier with background pages and use them to organize, hide, and reveal elements on multiple-page diagrams. To do this, you assign background shapes to layers. Because a background can be shared by more than one page, so, too, can its layers—this is a critical point, because layers can’t be used on more than one page.

For example, in an office layout where the same room outline is used on multiple pages, you can put the walls and moveable panels on the background, and then use different foreground pages to display furniture layouts, electrical wiring, network cabling, and so on. If you assign the wall shapes to one layer on the background and the panels to another, you can hide the moveable panels on all the pages that display the background whenever you need to see only structural elements.

You can also use background layers as a way to protect information that shouldn’t be modified, such as the project’s permit number or a company logo. To do this, create a new layer (for example, the Permanent layer), assign these shapes to the layer, and then lock the layer with the Layer Properties command on the View menu. You can then pass the file to others without risk.




Microsoft Office Visio 2003 Inside Out
Microsoft Office Visio 2003 Inside Out (Inside Out (Microsoft))
ISBN: 0735615160
EAN: 2147483647
Year: 2003
Pages: 209

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net