3. Core options
Core defaults live in coxn.editor/default-options. Set every option with (set-option! key value).
3.1 Editing and indentation
| Option | Default | Meaning |
|---|
:tab-width | 8 | Display width of a Tab character, following Emacs. EditorConfig tab_width and file-local values can override it per buffer |
:indent-offset | 4 | Spaces per indentation level. Major modes may provide defaults (Clojure and Lisp modes use 2); EditorConfig / file-local values can override per buffer |
:fill-column | 70 | Line width for M-q (fill-paragraph) and auto-fill (Emacs default: 70) |
:electric-pair | false | Automatically complete parentheses and quotes (M-x electric-pair-mode; Emacs default: off) |
:show-paren | true | Highlight matching parentheses (show-paren-mode; default on since Emacs 28) |
:line-move-visual | true | C-n / C-p move by screen lines when long lines wrap (Emacs default) |
:scroll-margin | 0 | Scroll margin (corresponds to Emacs scroll-margin; not consumed in the current release) |
3.2 Interface and display
| Option | Default | Meaning |
|---|
:display-line-numbers | false | Line numbers. M-x display-line-numbers-mode for the current buffer or global-display-line-numbers-mode globally |
:mouse | true | Terminal mouse (xterm-mouse-mode). While enabled, Shift+drag remains the terminal's own selection; M-x xterm-mouse-mode toggles it |
:extended-keys | true | kitty keyboard protocol / modifyOtherKeys, so the terminal can send C-;, C-?, C-S-a, and similar combinations |
:which-key-delay-ms | 500 | Delay after pressing a prefix before the which-key popup appears |
:tab-bar-mode | false | Top tab bar (M-x tab-bar-mode) |
:minibuffer-display | :bottom | Minibuffer position for M-x, C-x C-f, and similar commands: :bottom gives a bottom helm-style display (spacemacs feel); :popup gives a centered floating frame (vertico-posframe feel) |
:eldoc-display | :echo | Where automatic function hints appear: :echo uses the bottom line; :popup opens a floating frame. Toggle with M-m t E; the explicit viewer on M-m h g ignores this option |
:color-depth | :auto | Color depth: :auto probes the terminal (COLORTERM, TERM, Windows Terminal); 24 forces true color; 8 forces the 256-color palette chosen for each theme |
:text-scale | 1.0 | Text scale (Emacs text-scale-mode): C-x C-+ / C-x C-= enlarge, C-x C-- shrinks, C-x C-0 resets; each step is ×1.2 and the range is 0.2–8.0. C-u 3 C-x C-+ applies three steps. GUI recalculates rows and columns with the new font size; in TUI, font size belongs to the terminal. Unlike Emacs, this setting is global |
3.3 Completion
| Option | Default | Meaning |
|---|
:completion-auto | true | Open completion automatically after typing pauses (corfu feel). Toggle with M-m t a |
:completion-auto-delay-ms | 150 | Pause duration before automatic completion opens |
:completion-auto-prefix | 2 | Minimum symbol characters before automatic completion opens. Trigger characters such as ., ->, and :: are exempt |
:completion-sync-wait-ms | 300 | Initial synchronous wait after a completion request. If all sources return in time, show results immediately; otherwise switch to asynchronous display (bounded by :lsp-timeout-ms) |
3.4 Files, auto-saving, and persistence
| Option | Default | Meaning |
|---|
:auto-revert | true | If an unchanged buffer's file changes externally, read it again |
:auto-save | true | Save a copy of modified buffers (the original file is untouched) |
:auto-save-interval | 300 | Number of keystrokes between auto-saves |
:auto-save-timeout-ms | 30000 | Idle time in milliseconds before an auto-save |
:auto-save-dir | <cache>/auto-save | Auto-save directory; file names follow Emacs encoding (/#encoded-path#) |
:make-backup-files | true | Before the first save in a session, copy the original file to a backup |
:backup-dir | <cache>/backup | Backup directory (file names are encoded-path~) |
:save-place | true | Remember point and window position per file and restore it on reopening |
:save-place-file | <config>/save-place.edn | Storage file for save-place |
:bookmark-file | <config>/bookmarks.edn | Bookmarks (C-x r m / C-x r b) |
:projects-file | <config>/projects.edn | Known projects, used by M-x project-forget-project and related commands |
<config> and <cache> are described in §15.
3.5 GUI fonts (coxn-gui only; ignored by TUI)
The defaults are all nil, meaning follow the system: use the system monospace font as the primary font, and use system fontconfig fallbacks for CJK, symbols, and emoji. CJK uses a monospace sans font to preserve double-width alignment. Override with a priority list; the first installed font wins (following spacemacs my-fonts.el):
| Option | Default | Meaning |
|---|
:gui-font | nil | Primary font, for example ["JetBrains Mono" "Fira Code"] |
:gui-font-size | nil (= 14) | Font size in sp (about pixels on desktop; follows Emacs :size), for example 14 |
:gui-font-cjk | nil | Full-width / CJK font, for example ["Noto Sans Mono CJK SC"] |
:gui-font-symbol | nil | Arrow / symbol font, for example ["Symbola"] |
:gui-font-emoji | nil | Color emoji font, for example ["Noto Color Emoji"] |
3.6 Search and process output
| Option | Default | Meaning |
|---|
:grep-program | nil | Program for project grep ("rg" / "grep"). nil uses rg when installed, otherwise grep |
:repos-scan | nil | Root scanned by magit-repos-view (C-x p G). nil uses the parent of the current project root, otherwise the working directory |
:repl-buffer-maximum-size | 1000000 | Maximum characters retained in REPL / process-output buffers (following comint-buffer-maximum-size); beyond it, trim from the start to a line boundary. 0 means unlimited |