7.2. How To Select Objects

7.2.1. Selecting a Single Object

To select a single object, just click it with the mouse. Also, when an object is first placed on the canvas, it is automatically selected.

Once an object is selected, its handles are illuminated. For shapes, the handles are green points on its corners and sides. For a line, the handles are green or red at the ends, and orange in the middle. Once the object is selected, you may work with it as desired. To access the object's properties, you can double-click it or right-click and select Properties from the pop-up menu.

Figure 7.1. Selected Object

Selected Object

7.2.2. Deselecting Objects

You can deselect one or more selected objects by double-clicking on any empty space on the canvas or by selecting any other object. The handles will diObjects / Align Optionssappear, indicating that the object is no longer selected. Selecting the Layers option from the Diagram menu will also deselect all selected objects.

7.2.3. Selecting Multiple Objects

Multiple selection is useful when you want to apply the same operation to two or more objects. When selected, you may work with these objects as a set or individually. See the section Working With Selected Objects for more information.

Dia provides a number of ways to select multiple objects. These are outlined below. Note that either double-clicking on an empty region of the canvas or single-clicking on an unselected object deselects all selected objects.

7.2.3.1. Shift+Click Selection

A simple way to select two or more objects is to hold the Shift key down while clicking the objects with the mouse. The Shift+Click acts as a toggle. If you Shift+Click once, the object is selected. Shift+Click a second time to deselect the object.

[Tip]

You can combine Shift+Click with any of the other methods outlined below to either select an additional object or deselect a selected object.

[Note]

When you have a set of objects selected, it is still possible to resize or change the properties of one object without affected the other selected objects. See the section Working With Selected Objects for more information.

7.2.3.2. Select By Area

You can select all of the objects within a rectangular region of the screen by placing the mouse pointer to the upper left of the top-left object in the set and then dragging the mouse to a point below and to the right of the lower-right object in the set. A thin dashed rectangle will be drawn on the canvas as shown in the screenshot below. All objects that COMPLETELY FIT inside this rectangle are selected. Objects that are only partly inside the rectangle are not selected.

Figure 7.2. Select By Area Example

Select By Area Example

Only objects entirely inside rectangle are selected.


[Tip]

You can select multiple regions using select by area. Objects previously selected will continue to be selected as long as you don't deselect all (e.g., by double-clicking on an empty region of the canvas or by clicking on an unselected object without using the Shift key). As noted above, you can also use Shift+Click to select or deselect an individual object at any time.

[Tip]

Normally, selecting from top-left to bottom-right is the same as a "reverse drag" -- starting on the bottom-right and dragging toward the top-left. However, you can set an option in Dia that allows you to select objects that are only partially contained in the selection rectangle when you "reverse drag". See User Interface / Reverse Dragging for more information.

7.2.3.3. Select All

The Select menu shown below has six options for selecting multiple objects. The first option is All.

Figure 7.3. Select Menu

Select Menu

You can select all objects on the canvas using the SelectAll option or by pressing Ctrl+A. This selects all objects whether they are visible or not.

[Note]

As with any of the selection methods, if you are using layers, only objects in the current layer will be selected. See Managing Layers for more information on working with layers.

7.2.3.4. Select None

SelectNone option will deselect all objects. It has the same effect as double-clicking on a blank region of the canvas.

7.2.3.5. Select Invert

This option allows you to select all objects except for those currently selected. Say, for example, that you have 20 objects and wish to select all but two of them. You can do this by (1) selecting the two objects to be excluded and then (2) using the SelectInvert menu (or Ctrl+I). This will deselect the two currently-selected objects and select the 18 unselected objects.

[Tip]

Another way to do this is to SelectAll (or Ctrl+A) and then use Shift+Click to deselect the objects you don't need.

7.2.3.6. Select Transitive

Objects in Dia can be connected using lines. The Select Transitive and Select Connected options allow you to select objects based on how they are connected.

The Select Transitive option selects ALL objects connected directly or indirectly to the currently selected objects, no matter how many levels deep the connection might be. To use this, select one or more objects and then choose SelectTransitive. All objects connected to the initially selected objects will be added to the selected set.

7.2.3.7. Select Connected

This option is similar to Select Transitive except that it only adds objects that are immediately connected to an already-selected object. To use this option, first select one or more objects. Then choose SelectConnected. Any objects that are directly connected to the currently selected objects will be added to the selected set.

[Note]

The Select Connected option only goes out one level. For example, if box A is connected by a line to box B, and box A is selected, SelectConnected will only select the line, not box B. If you do SelectConnected a second time, then box B will also be connected.

You can use SelectTransitive to select all objects connected to the currently selected objects in one operation.

7.2.3.8. Select Same Type

This option allows you to select all objects that are the same type of object as one already selected. To use this option, select one or more objects and then choose the SelectSame Type option. All objects that are the same type as one of the previously selected objects will be added to the set of selected objects.

For example, if you want to select all of the Line objects on your diagram, select one Line object and then use SelectSame Type to select all other lines.

[Tip]

The menu choice SelectSame Type can be combined with the menu choice ObjectsGroup to quickly change one or more properties of all objects of one type on your diagram. See Changing Properties for a Group of Objects for more information.

[Note]

The object type must match exactly. For example, a Line object and a Zigzagline object are different types.