Therion th2 Visual EditorA VS Code extension for editing Therion cave-drawing files (
FeaturesVisual
|
| Button | Action |
|---|---|
| Canvas | Visual editor (default) |
| Text | Built-in VS Code text editor |
| Split | Canvas and text editor side by side |
Drawing Tools
| Tool | Key | Description |
|---|---|---|
| Select | V |
Click to select; drag to move; Shift+click or drag empty space for multi-select |
| Point | P |
Click to place; type defaults to station (auto-incremented) |
| Line | L |
Click vertices; double-click or Enter to finish; Escape cancels |
| Area | A |
Click existing closed lines to define the boundary; press Enter to finish |
Line drawing tips:
- Drag while placing a vertex to pull out Bezier handles.
- Approach the first vertex to snap-close the line automatically.
- Alt+click a segment to insert a vertex; select a vertex and press Delete to remove it.
Properties Panel
Selecting an object opens its properties on the right:
- Points — type, subtype, name (station), text (label/remark), orientation (drag the on-canvas handle), alignment, scale, value, and more.
- Lines — type, subtype, id, close/reverse toggles, outline, altitude, gradient, direction, and other type-specific options; vertex panel when a vertex is selected.
- Areas — type and referenced line IDs.
- Scraps (when nothing is selected) — name, projection, flip, scale, object count, sketches list, and author/copyright entries.
A Custom Options section at the bottom of the panel lets you add, edit, or delete arbitrary -key value pairs for any object.
An Attributes section handles -attr name value entries on points, lines, areas, and scraps.
Background Images
Click + Add Image in the Background Images panel to attach a scan to the current scrap. Then:
- Toggle the global Bg button or individual ●/○ buttons to show/hide images.
- Drag the opacity slider to dim the background while tracing.
- Edit the X / Y fields to reposition an image.
Keyboard Shortcuts
| Key | Action |
|---|---|
V |
Select tool |
P |
Point tool |
L |
Line tool |
A |
Area tool |
Delete / Backspace |
Delete selected object(s) |
Escape |
Cancel drawing / clear selection |
Ctrl+Z / ⌘Z |
Undo |
Ctrl+Y / ⌘Y |
Redo |
Alt+click |
Insert vertex on a line segment |
Supported File Formats
| Extension | Handler |
|---|---|
.th2 |
Visual canvas editor (read/write) |
.3d |
3D cave viewer (read-only) |
.lox |
3D cave viewer (read-only) |
Requirements
- VS Code 1.85 or later.
- No external tooling required — the extension bundles everything it needs.
Known Limitations
- The canvas renders points as simple circles and lines as Bezier paths; it does not reproduce Therion's full MetaPost symbol library.
- The parser handles
scrap,point,line, andareadirectives. Other Therion directives (centerline,map,surface, …) are preserved verbatim but not editable in the canvas.
License
ISC — see LICENSE.
