![[Home]](https://www.emacswiki.org/images/logo218x38.png)
There are facilities provided by Emacs to align text, comments, assignments, or columns.
align, align-current and align-regexp commands provided with Emacs.align.el extension written by Matthias Helmling. Do not confuse with the align.el lisp file provided with recent emacs versions and described above.columnize-text command, which lines up words or numbers, either by rows or columns. This function is designed to be used manually when editing buffers.let assignments in Lisp code. The align-let.el extension is written by Kevin Ryde.Tables can also be used to line up text. The extension table.el, by Takaaki Ota is now available by default with emacs22.
Converting text to table gives access to a number of neat formatting features from TableMode. The next example is obtained by capturing a short text with M-x table-capture, using space as the column delimiter and a newline as the row delimiter (the newline can be entered by hitting C-q C-j or C-o). The table is then removed with M-x table-release, leaving the default left alignment.
+---------+--------+
Firstname Lastname |Firstname|Lastname| Firstname Lastname
Alice Liddell => +---------+--------+ =>
Lewis Carroll |Alice |Liddell | Alice Liddell
+---------+--------+
|Lewis |Carroll | Lewis Carroll
+---------+--------+