Surround a string with box-drawing characters
Emacs Lisp
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
ert-tests
.gitignore
.travis.yml
Makefile
README.markdown
unicode-enbox.el

README.markdown

Build Status

Overview

Surround a string with box-drawing characters in Emacs.

Quickstart

(require 'unicode-enbox)

(insert "\n" (unicode-enbox "testing"))

Explanation

unicode-enbox.el has no user-level interface; it is only useful for programming in Emacs Lisp.

This library provides two functions:

unicode-enbox
unicode-enbox-debox

which can be used to add/remove box-drawing characters around a single- or multi-line string.

See Also

  • M-x customize-group RET unicode-enbox RET

Notes

For good monospaced box-drawing characters, it is recommended to install the free DejaVu Sans Mono font and use unicode-fonts.el. If unicode-fonts.el is too heavy for your needs, try adding the following bit to your ~/.emacs file:

(set-fontset-font "fontset-default"
                  (cons (decode-char 'ucs #x2500)  (decode-char 'ucs #x257F))
                  (font-spec :name "DejaVu Sans Mono:" :registry "iso10646-1"))

Compatibility and Requirements

GNU Emacs version 24.4-devel     : yes, at the time of writing
GNU Emacs version 24.3           : yes
GNU Emacs version 23.3           : yes
GNU Emacs version 22.3 and lower : no

Requires string-utils.el, ucs-utils.el

Uses if present: unicode-fonts.el