[[!meta title="Column-aligning text in Emacs"]] [[!meta copyright="Copyright © 2026 Jeff Trull"]] [[!inline pages="internal(2026/info/align-nav)" raw="yes"]] # Column-aligning text in Emacs Jeff Trull (he/him) - Pronunciation: rhymes with "hull" and "dull", Mastodon: @jaafar@hachyderm.io Blog: Email: [[!inline pages="internal(2026/info/align-before)" raw="yes"]] Emacs has a rich set of features for manipulating ordinary text. The "fill" features align text at the right or left edges of a paragraph, while "indent" adds space at the start of a line based on the level within an outline, or the depth of a block in code. Emacs also has a framework for lining up text **inside** a line to match adjacent lines, creating the appearance of columns. For example, some coders like to have equal signs in a series of assignment statements line up, like this: apple = 12; rambutan = 42; The [align.el family of functions](https://www.gnu.org/software/emacs/manual///html_node/emacs/Code-Alignment.html) provides functions like align, which is the entry point for mode-based code alignment, as well as align-regexp, which gives interactive, user-defined access to the same features. The presenter will give a basic introduction to the user-facing features before diving into a technical explanation of how to use the framework at the Lisp level to create your own alignment rules and features. The technical portion will touch on packages like rx and peg in addition to align.el. Format: **20 minutes** and outline: - Motivation: the uses of (column) alignment - Built-in align: features you can use out-of-the-box in programming modes - Customizing built-in align - align-regexp for interactive alignment - customizing align-rules-list for modes - align.el for the ELisp coder - Readable regexp with rx - Example: Creating org-mode tables from columns - Example: peg parsers as an alternative to regexp About the speaker: Jeff is a long-time Emacs user working on improving his ELisp skills. The dominance of VSCode makes him sad. He discovered the align.el framework while trying to improve Emacs formatting support for a C++ library he uses, Boost.SML . [[!inline pages="internal(2026/info/align-after)" raw="yes"]] [[!inline pages="internal(2026/info/align-nav)" raw="yes"]]