Dotdown™ · editor
Keys and tools in the Dotdown™ box
The box is a plain text field with a few editor habits added. Everything here works while your cursor is in the box, so it never gets in the way of the rest of the page.
All the keys
| Windows / Linux | Mac | Does |
|---|---|---|
| . or / | . or / | Open the field menu at the start of a line. |
| Enter / Tab | Enter / Tab | Pick the highlighted field in the menu. |
| Ctrl + Enter | ⌘ Enter | Apply the text to the form right now. |
| Ctrl + F | ⌘ F | Find. |
| Ctrl + H | ⌘ Option F | Find and replace. |
| Enter / Shift + Enter | Enter / Shift Enter | Next / previous match, while the find box is focused. |
| Ctrl + G | ⌘ G | Go to line. |
| Ctrl + / | ⌘ / | Comment or uncomment the selected lines. |
| Ctrl + Z | ⌘ Z | Undo, including a replace or a comment toggle. |
| Esc | Esc | Close the find bar, or the field menu. |
Typing a field
Type . (or /) at the start of a line and a menu of field types appears. It narrows as you type. Pick one with Enter, Tab or a tap.
- On a computer, type a whole name like
.radioand the full sample line appears. Tab selects the label so you can rename it, and Tab again selects the choices. - Start a new line with Enter and the form below updates to match. Press Ctrl + Enter (⌘ Enter) to apply without a new line.
- Esc closes the menu if you want a plain line.
Find
Press Ctrl + F (⌘ F) with the cursor in the box. A bar opens at the top of the box.
- Every match is highlighted yellow, and the current one orange. The bar shows a count such as “3 of 12”.
- Enter goes to the next match and Shift + Enter to the previous one. The arrows in the bar do the same.
- Aa turns on match case. It is off by default, so
namealso findsName. - If you had text selected when you pressed the key, it is put in the find box for you.
- Press Ctrl + F outside the box and you get the browser’s own find, which is what you want for the rest of the page.
Replace
Press Ctrl + H, or ⌘ Option F on a Mac (⌘ H hides the window on a Mac, so it is not used). A second row appears under the find box.
- Replace changes the current match and moves to the next. All changes every match and tells you how many (“Replaced 12”).
- Both go through the browser’s own typing, so Ctrl + Z undoes them. Replace all is one undo step.
- It is plain text, not patterns. A
.or*in the find box just means that character.
Go to line
Press Ctrl + G (⌘ G), type a number and press Enter. The line is selected and scrolled into view.
Errors use it too. An error like “Line 21: .duplicate needs its fields…” has a Line 21 you can click, and it jumps to that line.
Comment toggle
A line starting with // is a note to yourself and is ignored. Ctrl + / (⌘ /) adds // to every line the selection touches, or removes it if they are all comments already. With nothing selected it does the line the cursor is on.
Handy for trying a form without a field, without deleting it. Select the two lines and press the key:
.text Name* .email Email* .tel Phone
and they become comments:
.text Name* // .email Email* // .tel Phone
Comments are not saved in the form, so they are gone after you press To text or reopen the form.
Line numbers
The numbers on the left match the “Line N” in error messages. A long line that wraps onto two rows still gets one number, with the number at its top.
The buttons
- To form ⤵ turns the text into the field rows below.
- To text ⤴ writes the current form back as text. Comments you typed are not kept.
- Magnifier opens find (and replace) without a key. Copy copies all the text.
On a phone
There are no keyboard shortcuts on a phone, but the same things are there. Tap the magnifier for find and replace, and tap a field in the menu to pick it. After picking, edit the sample line by hand, because a phone keyboard has no Tab. A “Line N” in an error is still tappable.
What is not included
The box is plain text, not a code editor, to keep it small and to keep typing on phones reliable. There is no regex search, no multiple cursors, no moving or duplicating lines with a key, and no Vim keys. If one of these would change how you use it, tell us.
Looking for the syntax of each field? See the Dotdown™ page, or the .page guide for pages and jumps.