The Kalem Book GitHub

This Book describes Kalem's main branch, which may be ahead of the latest release.

Glossary

Term Meaning
Block A part of a document the view treats as one: a paragraph, a table, a formula, a code block, a drawer; blocks fold
Chip A reference, citation or link shown as the thing it points to (a number, an author and year) rather than as its source
Command An action with an identifier (latex.insert.figure), a title, a scope and default keys; menus, keys, the palette and scripts run commands
Completer A source of completions at the cursor: words, commands, labels, citation keys, file paths
Drawer In Org, a :NAME: … :END: block; in the view, any block folded to its first line away from the cursor
Frontend One of the two editors: the graphical one (kalem) and the terminal one (kalem -t)
Grid A table, a CSV file or a BibTeX file drawn with aligned columns; the source shows where the cursor is
Known difference A place where Kalem deliberately differs from its oracle, recorded with a test
Lossless Reading a file and writing it back without changes gives the same bytes
Mode How Kalem treats a document: Org, Markdown, LaTeX, CSV, BibTeX, plain text (with a language), or a folder
Oracle The reference implementation or test suite a mode is checked against: Emacs for Org, pandoc and TeX for LaTeX
Palette The list of commands opened with Ctrl+Shift+P (Cmd+Shift+P), which also asks for a command's arguments
Plugin Compiled Rust run by Kalem as a WebAssembly component with its own memory, limits and permissions: a viewer of files that are not text, or an extension adding commands, events and panels; or a declarative language plugin (Part III)
Project A folder with a version control directory or a marker file; files, search and recent files are per project
Scope The types of text a command serves (§11.2 of the design): org, latex, csv, bib, a programming language
Source view The file as it is, without rendering (Ctrl+/)
Text first The file on disk is the truth: Kalem renders plain text and edits it in place, with no database, container format or sidecar file of its own
Text type The type of the text at the cursor: the file's mode, or a source block's language inside Org
WebAssembly component Compiled code with a typed interface, run in a sandbox with its own memory; the form every Kalem plugin takes
When-clause A condition on the editor's state (editorMode = org && inTable=) that decides whether a command applies
Workspace The settings of a folder, in .kalem/settings.toml