- Light and dark (customizable) color schemes.
- JavaScript support:
- - Very fast for files under 1000 lines.
- Script, function and block scopes (and even `catch` block scopes).
+ - Very fast for files under 1000 lines.
- Emacs Lisp support:
- - `defun`, `lambda`, `let`, `let*`, quotes, backticks, commas.
+ - `defun`, `lambda`, `let`, `let*`, `cond`, `condition-case`, `defadvice`,
+ `dolist`, `quote`, `backquote` and backquote splicing.
+ - Instantaneous lazy coloring, 8000 lines-per-second full coloring.
+ - Works in `eval-expression` too.
## Installation
-Requires Emacs 24+.
+Requires Emacs 24.3+.
JavaScript language support requires either [js2-mode][], or
[Node.js 0.10+][node] and the [scopifier][] executable.
```lisp
;; js-mode:
-(add-hook 'js-mode-hook 'context-coloring-mode)
+(add-hook 'js-mode-hook #'context-coloring-mode)
;; js2-mode:
(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode))
-(add-hook 'js2-mode-hook 'context-coloring-mode)
+(add-hook 'js2-mode-hook #'context-coloring-mode)
;; emacs-lisp-mode:
-(add-hook 'emacs-lisp-mode-hook 'context-coloring-mode)
+(add-hook 'emacs-lisp-mode-hook #'context-coloring-mode)
+
+;; eval-expression:
+(add-hook 'minibuffer-setup-hook #'context-coloring-mode)
```
## Customizing
comments using `font-lock`.
- `context-coloring-syntactic-strings` (default: `t`): If non-nil, also color
strings using `font-lock`.
-- `context-coloring-delay` (default: `0.25`; supported modes: `js-mode`,
- `js3-mode`, `emacs-lisp-mode`): Delay between a buffer update and
+- `context-coloring-default-delay` (default: `0.25`; supported modes: `js-mode`,
+ `js3-mode`): Default (sometimes overridden) delay between a buffer update and
colorization.
- `context-coloring-js-block-scopes` (default: `nil`; supported modes:
`js2-mode`): If non-nil, also color block scopes in the scope hierarchy in