From dbff3a5bb1d47e5a348ce7e91073df43b29b3e44 Mon Sep 17 00:00:00 2001 From: Gabriel Schneider Date: Fri, 6 Nov 2026 22:49:11 -0300 Subject: kinds #51, builtins-json lists the shipped addons' words, read off the Zig kinds' `Word` lines (image.zig and pdf.zig, handed to the generator and read by the staleness test), each `"addon"` first so the docs test's search for a builtin never meets one and an addon word the docs name is checked against the sources (renaming PdfFit fails it); the glossary says whose addon a word is, and the changelog Co-Authored-By: Claude Fable 5.1 Claude-Session: https://claude.ai/code/session_016Y9MNAtZenFv4weoMD3cge --- docs/typ/builtins-gui.json | 5 ++++- docs/typ/builtins-tui.json | 5 ++++- docs/typ/style.typ | 3 ++- 3 files changed, 10 insertions(+), 3 deletions(-) (limited to 'docs/typ') diff --git a/docs/typ/builtins-gui.json b/docs/typ/builtins-gui.json index 87d98903..37b8e1ba 100644 --- a/docs/typ/builtins-gui.json +++ b/docs/typ/builtins-gui.json @@ -110,5 +110,8 @@ {"name": "Wrap", "leader": "SPC t w", "also": [], "arg": true, "scope": "root", "setting": true, "choices": "on, off", "doc": "Long lines wrap onto the next row, on or off."}, {"name": "WsDiagnostics", "leader": "SPC l D", "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "List the workspace's diagnostics from the language server."}, {"name": "WsSymbols", "leader": "SPC l S", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "Search the workspace's symbols for its argument."}, - {"name": "Zerox", "leader": null, "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "acme's Zerox: a second pane on this pane's file, the same text, undo and unsaved state, with a scroll and a cursor of its own (File.zerox)."} + {"name": "Zerox", "leader": null, "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "acme's Zerox: a second pane on this pane's file, the same text, undo and unsaved state, with a scroll and a cursor of its own (File.zerox)."}, + {"addon": "pdf", "name": "PdfSections", "leader": "SPC t s", "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "list the PDF's sections in a pane, each a place to go"}, + {"addon": "pdf", "name": "PdfTint", "leader": "SPC t i", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "tint the PDF to the theme or show it as printed (disabled|filtered|full)"}, + {"addon": "pdf", "name": "PdfFit", "leader": "SPC t z", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "fit the PDF's pages to the pane's width or height (width|height)"} ] diff --git a/docs/typ/builtins-tui.json b/docs/typ/builtins-tui.json index c1879798..e307b3f8 100644 --- a/docs/typ/builtins-tui.json +++ b/docs/typ/builtins-tui.json @@ -103,5 +103,8 @@ {"name": "Wrap", "leader": "SPC t w", "also": [], "arg": true, "scope": "root", "setting": true, "choices": "on, off", "doc": "Long lines wrap onto the next row, on or off."}, {"name": "WsDiagnostics", "leader": "SPC l D", "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "List the workspace's diagnostics from the language server."}, {"name": "WsSymbols", "leader": "SPC l S", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "Search the workspace's symbols for its argument."}, - {"name": "Zerox", "leader": null, "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "acme's Zerox: a second pane on this pane's file, the same text, undo and unsaved state, with a scroll and a cursor of its own (File.zerox)."} + {"name": "Zerox", "leader": null, "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "acme's Zerox: a second pane on this pane's file, the same text, undo and unsaved state, with a scroll and a cursor of its own (File.zerox)."}, + {"addon": "pdf", "name": "PdfSections", "leader": "SPC t s", "also": [], "arg": false, "scope": "pane", "setting": false, "choices": null, "doc": "list the PDF's sections in a pane, each a place to go"}, + {"addon": "pdf", "name": "PdfTint", "leader": "SPC t i", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "tint the PDF to the theme or show it as printed (disabled|filtered|full)"}, + {"addon": "pdf", "name": "PdfFit", "leader": "SPC t z", "also": [], "arg": true, "scope": "pane", "setting": false, "choices": null, "doc": "fit the PDF's pages to the pane's width or height (width|height)"} ] diff --git a/docs/typ/style.typ b/docs/typ/style.typ index 2f777892..bcc732a1 100644 --- a/docs/typ/style.typ +++ b/docs/typ/style.typ @@ -186,7 +186,7 @@ /// Every builtin of either build, written by `zig build builtins-json` /// from the registry and the Help rows (src/builtins_json.zig), a file per /// build: name, leader, also (Help's other shortcuts), arg, scope, setting, -/// choices, doc. Merged here, each with `platforms`: "both", "tui" (the +/// choices, doc, and for a shipped addon's word its addon first. Merged here, each with `platforms`: "both", "tui" (the /// terminal only) or "gui" (the window only). #let builtin-data = { let tui = json("builtins-tui.json") @@ -421,6 +421,7 @@ #heading(depth: 2, raw(b.name)) #label("builtin-" + b.name) #let keys = (if b.leader != none { (key(b.leader),) } else { () }) + b.also.map(shortcut) #if b.platforms != "both" [#emph(if b.platforms == "gui" [window only] else [terminal only]) · ] + #if "addon" in b [#emph[the #raw(b.addon) addon's] · ] #if keys.len() > 0 [#keys.join([, ]) · ] #if b.choices != none [#raw(b.choices.replace(", ", "|")) · ] else if b.arg [takes an argument · ] #prose(b.doc) -- cgit v1.3