The preferences window
Click the cog in the title bar and choose Settings, Key Bindings or Themes. All three are tabs of one window that floats above throng and minimises with it; it stays on top but does not block the app, so you can keep working while you edit a theme and watch each change land.
Under native Wayland (Linux, throng running through the Wayland backend rather than XWayland, which is the
default), Preferences opens as a panel inside the main window instead. Electron 45.5.0 never sends
xdg_toplevel.set_parent on Wayland, whether through parent, modal or setParentWindow, so no compositor can
keep a separate window above throng. The panel floats over the window's content and blocks nothing; drag it by its
title bar anywhere inside the window (it cannot leave it, and remembers where you left it for the run); Esc or its
X closes it, its (?) opens this section of the guide, and F1 does what it does in the separate window: it
opens the section of the row that is focused or under the pointer, or else the top of the open tab's guide page. Everything it shows and does is the
same, and the program dialog opened from inside throng appears as a modal over it. About throng opens in the same
way, as a modal in the main window. Windows, macOS, X11 and XWayland keep the separate windows. Sub-workspace windows
have no Preferences: a request made from one opens the main window's. THRONG_FORCE_INWINDOW_PREFS=1 takes the
in-window path on any platform; the test harness uses it.
- The visual editors apply each change at once, with no Save button and no restart. Toggles and dropdowns apply at once; a typed value applies when you press Enter or leave the box.
- Settings, Key Bindings and Themes each have typeahead search. Every word you type must appear in a row's name, description, current value or the headings above it, and the best match comes first: a hit in the name ranks above one in the value, the description or a heading, and an exact name above a partial one. Sections are ordered by their best match, and typing a section or subsection name returns everything under it.
- The JSON view (the UI ⇄ JSON toggle in the toolbar) edits the same files in throng's own editor. throng applies your document when you leave it: when you switch back to the visual editor, switch tab, or close the window. It waits because a half-typed number is often still valid JSON and applying it would correct and rewrite the value you were halfway through entering. While the document is invalid you cannot leave it: one notice names each offending value with its allowed options or range, and Discard changes and close abandons the edit, leaving the last valid document in effect.
- Every number is a slider, its value, and a box. The slider moves in steps suited to its range and shows the value in the unit that reads best: sizes in MB (1 MB is 1,048,576 bytes), durations in ms, seconds or minutes. The box beside it holds the stored value (bytes for a size, milliseconds for a duration) and takes any whole number within the setting's limits, which can go beyond the slider's ends. A value that is not one of the slider's steps greys the slider; it still moves, and moving it sets that step. Type past a limit and the box turns red while a notification names the setting and its limits; Enter or leaving the box stores that limit. Text that is no number stays, red, until you correct it or press Esc, which puts the stored value back. In the tables below, Range gives the slider's ends and step in the shown unit, then the box's limits in the stored unit where they reach further.
- A box that refuses an entry says why in a notification, never under the box, so nothing on the page moves. Confirming the same entry again flashes that notification and adds no second one.
Folding sections
Every section and subsection heading on the Settings, Key Bindings and Themes tabs folds. Sections start folded, so each tab opens as a list of section headings; open a section and its subsections are already open. Click anywhere on a heading, or Tab to it and press Enter or Space, to fold or unfold it. Folding a section leaves its subsections as you left them, so unfolding it brings back the same layout.
- The count beside each heading is how many rows it holds, its subsections included. While you
search it reads as matches out of total, for example
3 of 34. - A warning marker on a folded heading means a row inside it holds an invalid entry. Your entry is still there when you unfold it.
- Expand All and Collapse All beside the search box unfold or fold every heading on that tab. They are disabled while the search box has text.
- Searching unfolds every section that holds a match. Clearing the search folds them back the way they were, and any folding you did while searching is not kept.
- Your choices are remembered per tab, across closing the window and restarting throng. A section
you opened stays open, and a subsection you folded stays folded. They are not a setting, so they do
not appear in
settings.json.
Lists and tables
A setting that holds a list or a table (excluded globs, link protocols, the extensions that end a spaced path, safe preview sources, language by extension, indentation by language) shows one line in its row: how many entries it holds and the first few. Its edit button opens the list in a window of its own over Preferences, where you add, change and remove entries as before. Save (or Ctrl+Enter) stores the list; Cancel (or Esc) leaves it as it was.
Resetting
Four scopes, all reading the same shipped-defaults record:
| Control | Scope |
|---|---|
| Revert, Reset and Clear on a row | That one setting or binding: Revert undoes your change this session, Reset returns the shipped value, Clear empties it. All three are always on the row, so it never moves; one that does not apply yet is greyed, and its hover title says why. |
| Reset the tab | The whole Settings or Key Bindings editor. |
| Reset All Preferences | Settings, key bindings and built-in themes, atomically. Your projects, layout, workspace state and custom themes are untouched, and the confirmation names them. |
| Revert All Preferences | A session undo: everything goes back to how it was when you opened the window. Defaults stay out of it. |
Values out of range, and files that will not parse
A hand-edited value that is out of range is brought back inside it, and the file is updated to say
so. Each setting's limits are the ones its box accepts (the slider's range unless the table below
gives wider ones), so a pane width of 99999 loads as the maximum, and settings.json is rewritten
to the corrected value. This happens whenever the file is read, including a hot-reload. A
file already within its limits is never rewritten.
A file that cannot be parsed is left alone. throng re-reads it a few times in case it caught you mid-save; if it still will not parse, throng runs on the shipped defaults, records that in the diagnostics log, and leaves your file as it is for you to repair. A key throng does not recognise is kept when it writes the file; a retired key it once used is dropped.