Guide11 min readApplies to Trakisilo 2.1.18

Diagrams, visual canvas, and math

The complete visual diagram editor — templates, shapes, connectors, styling, layout, keyboard sheet — plus mermaid, AsciiMath, inline math, and paste-to-diagram.

Trakisilo has three diagram and formula systems that all render live inside the shared editor: the drag-and-drop visual canvas, text-driven mermaid diagrams, and AsciiMath formulas — block-level or inline inside sentences. All of them render with the app theme, and right-click → Copy image copies a PNG of any rendered diagram.

Visual diagram editor

/visual inserts a canvas diagram and opens the editor directly. The canvas is a real node-and-edge editor: boxes, arrows, containers, labels, auto-layout, and per-object styling — no source text required.

Starting: templates or blank

The template picker offers Hub and spoke, Flowchart, Org chart, Network topology, Multi-step process, and Sequence — each seeds a working diagram you can reshape. Starting blank drops a starter box already in typing mode, and Tab adds the next connected box, so a quick flow can be typed without touching the mouse.

Adding shapes

Three ways to add a shape:

  1. Click a palette shape — it lands connected beside the current selection.
  2. Drag a palette shape onto the canvas where you want it.
  3. Double-click empty canvas for a box.

The palette carries eight shapes: Rounded, Rectangle, Ellipse, Diamond, Database (cylinder), Step, Container (a dashed grouping box), and plain Text. Type directly into a selected box — Enter adds a new line inside it, and ⌘⏎ or clicking away commits.

Connecting boxes

Hover a box and its + dots appear with a ghost preview. Click a dot to spawn a connected copy of the box, or drag the dot onto another box to draw an arrow — dropping on empty canvas opens a shape picker for the new endpoint.

The palette's Arrow button opens a flyout of connector presets. Pick one, then drag between boxes:

PresetStyle
ArrowElbow connector, arrowhead at the end.
Both endsElbow connector, arrowheads at both ends.
LineElbow connector, no heads.
StraightStraight connector, arrowhead at the end.
CurvedCurved connector, arrowhead at the end.

Edges stay editable after drawing: grab a line anywhere and pull to bend it, drag an endpoint dot onto any box to reconnect it, double-click the line to label it, or insert a box mid-arrow to split a long edge into a step.

Styling shapes and connectors

Selecting a line gives a floating bar with connector-type buttons (straight, elbow, curved), head presets (none, end, start, both), color, and line style; its ⋯ row adds per-end head shapes, thickness, and dotted lines.

The compact style bar anchors beside a selected shape with shape, fill, and text controls; its ⋯ popover covers opacity, border, and alignment. Colors come from the diagram palette — blue, green, amber, red, purple, teal, neutral — so diagrams always render correctly in both app themes.

Layout and direction controls auto-arrange the graph when manual placement has done its job. Rendered diagrams appear inline in the document with the app theme — there is no separate export step.

Canvas keyboard sheet

Press ? inside the editor for this sheet:

KeysAction
TypeEdit the selected box.
TabAdd the next connected box.
Enter / ⌘⏎Edit label / commit editing.
⌘Z / ⇧⌘ZUndo / redo.
⌘C ⌘V ⌘X ⌘DCopy, paste, cut, duplicate.
⌘A / ⌫Select all / delete selection.
ArrowsNudge 1px — hold ⇧ for 10px.
⌥dragDuplicate-drag a copy.
⇧dragMarquee-select multiple objects.
EscBack / close the editor.

Mermaid diagrams

/diagram inserts a mermaid block and shows a picker of diagram types — flowchart, sequence, gantt, mindmap, pie, ER, state, journey, timeline — each seeding working syntax you can edit rather than a blank box. The diagram renders live as you type, and the language picker on a code block can turn existing mermaid source into a rendered diagram too.

The ? chip on the block opens a tabbed syntax-hints popup covering the template groups; click any snippet to insert it at the caret. Mermaid only loads when a diagram actually exists, so documents without diagrams pay nothing for it.

Paste-to-diagram. Pasting mermaid source offers Insert as diagram? — one click renders it. Pasted ASCII sequence diagrams also render as mermaid automatically; ASCII graph art becomes an editable visual diagram instead. See smart paste.

AsciiMath formulas

/asciimath inserts a display-formula block with a starter picker — quadratic, sum, integral, limit, derivative, matrix, piecewise — each seeding working syntax. The same ? chip opens the syntax cheatsheet, grouped into tabs covering sub/superscripts, fractions and roots, relations, Greek letters, operators, and brackets; click a snippet to insert it at the caret.

Inline math

For a formula inside a sentence, a list item, or a table cell, use an inline math chip: type $x^2$ directly, use /math, or select text and click the √x button. Inline chips flow with the text instead of breaking the paragraph.

Where diagrams can live

  • Diagrams drop inside bullet items, numbered items, and table cells — they land under the item's or cell's text, never replacing it.
  • Visual diagrams from pasted ASCII art remain fully editable in the canvas editor.
  • Exported standalone HTML keeps diagrams, math, and images intact — no app needed to view them.
  • Right-click any rendered canvas or mermaid diagram → Copy image for a PNG you can paste anywhere.