Layers Overview
When creating complex graphics, it can be a challenge to keep track of all the graphic figures in the work area. Graphic figures get hidden under one another and selecting becomes difficult. Layers provide a way to manage the graphic figures that make up your graphic. Layers can be regarded as folders that contain graphic figures.
The structure of layers in your document can be as simple or complex as you want it to be. By default, all graphic figures are organized in a single, root layer. This layer is named Tgml and you cannot rename it. The TGML layer is always visible.
Layers have the same properties as Group elements: Opacity and Visibility. You can control these layer properties from the Properties pane.
Example: TGML layer and two additional layers
Layers are located on the TGML root level. New layers are added at the top of the work area (z-order, corresponding to the top of the tree), which means that the figures in the layer are displayed above (and possibly on top of) figures in previous layers. For more information, see the Figures section.
NOTE: To rearrange the order of the layers, you can select a layer in the Layers pane and click the Move up and Move down
buttons to move the layer upward or downward in the tree.
You manage layers in the Layers pane. From the Layers pane you can create, select and merge layers. You can also show, hide, duplicate, move, rename and delete all layers except the Tgml layer. You can copy graphic figures from one layer to another. To edit a layer and access all its contents, you have to make sure that the layer is selected. When you select one layer, all other layers become inaccessible. If you move the layers up or down, you change the stacking order of the graphic figures in the work area.
Example: TGML and two additional layers, the last (Layer 2; topmost) active
The display area of the Layers pane has the following columns:
- Buttons to select the active layer
- Thumbnail, showing the contents of a layer. For TGML the merged contents are displayed.
- The name of the layer, which can be edited (except for TGML)
- Checkbox to show/hide a layer
NOTE: You can edit the name in the Name box in the Properties pane. You can also edit the name in the tree structure in the Objects pane. You can show/hide layers during the design process, but also in run time, for example, through a signal bound to the Visibility property.
You typically use layers to create a background image, which lies inert during the remaining design work, or to create layers with information that is to be displayed only under certain conditions.