Lila Modeler v1.0.0-beta.26 ES GitHub
Docs›Guides›Keyboard shortcuts

Keyboard shortcuts

Lila Modeler has one shortcut map (apps/web/src/atajos.ts): the keyboard, the tooltips, the native menu of the desktop app and this page all come from it, and a test fails if this page misses one of its keys. On Windows and Linux, Ctrl takes the place of ⌘.

Shortcuts without ⌘/Ctrl (F2, F6, Esc, the align keys) do nothing while you type in a field or edit a label, and, apart from the File menu of the desktop app's native menu bar (Print excepted), no shortcut reaches the app while a dialog (Settings, the command palette, a confirmation) is open. In a browser, ⌘O, ⌘S, ⇧⌘S and ⌘P do nothing while the command palette or Settings is open: they no longer fall through to the browser's own «Open file», «Save page as» and «Print».

File

Action macOS Windows / Linux
New project ¹ ⌘N Ctrl+N
Open project ⌘O Ctrl+O
Save project ⌘S Ctrl+S
Save as ⇧⌘S Ctrl+Shift+S
Print the diagram ² ⌘P Ctrl+P
Settings ¹ ⌘, Ctrl+,
Action macOS Windows / Linux
Command palette ⌘K Ctrl+K

In the palette ↑/↓ move, Enter picks, and Esc closes it and gives the focus back to where it was — to a text field with the caret where you left it. Tab does not leave the palette: like any modal dialog, it keeps the focus in its field until it closes.

Modes

Action macOS Windows / Linux
Model ¹ ⌘1 Ctrl+1
Simulate ¹ ⌘2 Ctrl+2
Results ¹ ⌘3 Ctrl+3

The number keys are read by position, so they work on any keyboard layout. Switching modes from the keyboard is a desktop-app feature: in a browser these keys switch the browser's tabs, so the web app leaves them alone — click a mode tab or use the command palette (⌘K) instead.

There are three modes. Comparing scenarios and replaying the tokens live in Results: «Compare with…» in its bar, and the tokens play on the same map as the heat map. Validate paths (the token walk that checks the routes, not the simulation) is a Model tool: the button over the canvas, or «Validate paths» in ⌘K.

Simulation

Action macOS Windows / Linux
Run simulation ⌘↩ Ctrl+Enter
Cancel the run (only while it runs) Esc Esc
Simulate panel: open step 1–6 (Arrivals, Times, Routes, Resources, Calendars, Run) ⌥1 ⌥2 ⌥3 ⌥4 ⌥5 ⌥6 Alt+1 Alt+2 Alt+3 Alt+4 Alt+5 Alt+6
Simulate panel: clear the selection (when no run is in flight) Esc Esc
Play or pause the tokens (Results only) Space Space

In Simulate, ←/→ move between the step tabs of the bar under the top bar when one of them has the focus (Home/End jump to the first and last), and Alt+1…6 work in the detached window too, and from Model or Results — or from the main window while the panel is detached — they switch to Simulate on that step; neither they nor Esc act while you type in a field. «▶ Simulate» (the top bar's, the one of the detached panel window, the last step's and ⌘↩) takes you to the first error instead of running while the scenario has one — the top bar's button shows how many; warnings («! n» on a step) do not stop it.

Space does nothing while you type in a field or when a button has the focus (there it presses the button).

Canvas

With the canvas focused (click on it first):

Action macOS Windows / Linux
Zoom in ⌘+ Ctrl++
Zoom out ⌘− Ctrl+-
Fit the diagram ⌘0 Ctrl+0
Rename the selected element F2 F2
Undo ⌘Z Ctrl+Z
Redo ⇧⌘Z Ctrl+Y
Delete the selection ⌫ Del
Select all ⌘A Ctrl+A
Copy ⌘C Ctrl+C
Paste ⌘V Ctrl+V
Lasso tool L L
Hand tool H H
Connect tool C C
Edit the label E E
Replace the element R R
Align left ⌥⇧L Alt+Shift+L
Align center ⌥⇧C Alt+Shift+C
Align right ⌥⇧R Alt+Shift+R
Align top ⌥⇧T Alt+Shift+T
Align middle ⌥⇧M Alt+Shift+M
Align bottom ⌥⇧B Alt+Shift+B
Distribute horizontally ⌥⇧H Alt+Shift+H
Distribute vertically ⌥⇧V Alt+Shift+V

Zoom and fit work from anywhere in the window, not only from the canvas. They zoom the diagram, not the page: the desktop app has no page zoom, by decision (#442). Its View menu replaced Electron's default one, which had Zoom In, Zoom Out and Actual Size, and no ⌘⌥+/⌘⌥− page zoom was added in its place; the interface scales with Settings → General → Density and with the theme's base font size (Settings → Appearance → Typography). In a browser, the page zoom stays in the browser's own menu.

The align keys work in Model only and act on the selected shapes (two or more; three or more to distribute), like the align buttons at the top right of the canvas and the command palette. Lanes are not aligned. Distribute keeps the first and last shapes where they are and spaces the rest approximately evenly: diagram-js leaves the first gap a few pixels (about 5 px) shorter than the others. Shapes that overlap along that axis move together as one column or row. The shape palette on the left filters as you type and inserts the highlighted shape with Enter.

Panels

Action macOS Windows / Linux
Show or hide the left column ⇧⌘L Ctrl+Shift+L
Show or hide the right panel ⇧⌘P Ctrl+Shift+P
Show or hide the diagram tabs ⇧⌘D Ctrl+Shift+D
Show or hide the status bar ⇧⌘B Ctrl+Shift+B
Show or hide the results table (Results) ⌘J Ctrl+J
Move the focus to the modes F6 F6
Move the focus to the right panel ⇧F6 Shift+F6

Tab always moves the focus, the canvas included.

Keys the browser keeps

¹ Only in the desktop app. In a browser, ⌘N/Ctrl+N (new window) and ⌘, (browser settings) are taken by the browser before the page sees them, and the web app does not listen to ⌘1…⌘3/Ctrl+1…Ctrl+3 so they keep switching the browser's tabs: use the bar's buttons, the mode tabs or ⌘K instead. In the desktop app the File, View and Simulation menus list these shortcuts next to each item, and each mode tab names its key in its tooltip.

² Prints the diagram alone, black on white, on one sheet. In a browser, that print dialog is also how you get a PDF (choose «Save as PDF»); the desktop app has «File → Export diagram as PDF…» as well. SVG and PNG exports, and the process document (Word or HTML), are in the File menu and the command palette, with no key of their own.

In the desktop app ⌘W/Ctrl+W closes the focused window (About or the detached scenario on their own; the main window asks first when there are unsaved changes and, like its red button, quits the app) and ⌘Q/Ctrl+Q quits (on Windows use the window's close button or Alt+F4). Both come from the native menu's own roles, so they are not in the map above and a browser keeps them for itself.

The detached scenario window forwards ⌘S, ⇧⌘S and ⌘P to the main window; ⌘K too, but only in the desktop app, where the main window is raised first (a browser cannot bring another window to the front, so there the key does nothing in the detached window).

Versión en español

✎ Edit this pageTargets v1.0.0-beta.26