# Line definitions Line definitions describe the types of lines that appear in each cross-section. There are two categories: **measured line definitions** for surveyed data, and **template line definitions** for design profiles. Both are configured per tunnel -- each alignment has its own independent set. Line definitions are managed in the **Tunnel Settings** dialog, accessible from the ribbon. ## Measured line definitions Measured line definitions (`TSectionLineDefinition`) describe the types of surveyed lines recorded at each section. Common examples include "Excavation", "Final Lining", and "Shotcrete". Each measured line definition has the following properties: | Property | Description | |---|---| | **Name** | Identifier for the line type (e.g., "Excavation") | | **Layer** | CAD layer assignment for display | | **Color** | Display color of the line | | **Style** | Section line style, selected from the SectionLineStyleLibrary | | **Closed** | Whether the polyline is drawn as a closed polygon | | **Draw** | Whether to render this line on the canvas | | **Deviation Line** | If checked, this line is used for deviation analysis against the template | ```{note} Only one measured line should typically be marked as the **Deviation Line**. This is the line compared against the template when computing deviations and generating clearance reports. ``` ## Template line definitions Template line definitions (`TTemplateLineDefinition`) describe the types of theoretical/design profiles. These represent the intended tunnel geometry at each section. Template line definitions share the same properties as measured line definitions: | Property | Description | |---|---| | **Name** | Identifier for the template line type | | **Layer** | CAD layer assignment | | **Color** | Display color | | **Style** | Section line style from the style library | | **Closed** | Whether to draw as a closed polygon | | **Draw** | Whether to render this line | ## How line definitions relate to sections Each cross-section contains one `TSectionLineData` entry per line definition. This means: - When you add a new line definition, every existing section gains an empty line data slot for that definition. - When you add a new section, it automatically gets one line data entry per existing line definition. The line data itself is a polyline -- an ordered array of 3D points with optional bulge values for arcs. ```{tip} Plan your line definitions before importing survey data. Having the correct definitions in place ensures that imported points map to the right line types. ``` ## Configuring line definitions 1. Open **Tunnel Settings** from the ribbon. 2. Select the **Line Definitions** tab for measured lines, or the **Template Lines** tab for template lines. 3. Add, edit, or remove definitions as needed. 4. Click **OK** to apply. ```{warning} Removing a line definition deletes all associated line data from every section in the tunnel. This action cannot be undone. ```