spacemacs/contrib/colors/README.md

93 lines
2.6 KiB
Markdown
Raw Normal View History

2014-12-18 05:12:04 +00:00
# Colors contribution layer for Spacemacs
2014-12-24 06:03:49 +00:00
![logo](img/rainbow_dash.png)
2014-12-18 05:12:04 +00:00
<!-- markdown-toc start - Don't edit this section. Run M-x markdown-toc/generate-toc again -->
**Table of Contents**
- [Colors contribution layer for Spacemacs](#colors-contribution-layer-for-spacemacs)
- [Description](#description)
- [Install](#install)
- [Key bindings](#key-bindings)
- [Rainbow Identifiers](#rainbow-identifiers)
2015-01-24 05:03:40 +00:00
- [Rainbow delimiters](#rainbow-delimiters)
- [Rainbow Mode](#rainbow-mode)
2014-12-18 05:12:04 +00:00
<!-- markdown-toc end -->
## Description
This layer colors your life with:
- [rainbow identifiers][]
2015-01-24 05:03:40 +00:00
- [rainbow delimiters][]
- [rainbow mode][]
2014-12-18 05:12:04 +00:00
[rainbow identifiers][] mode will colorize each variables and functions with an
almost unique color. The keywords and the declaration of function colors are
disabled in order to make the colorized variables and functions stand out.
2015-01-24 05:03:40 +00:00
[rainbow delimiters][] highlights delimiters such as parentheses, brackets or
braces according to their depth.
[rainbow mode][] displays strings representing colors with the color they
represent as background.
2014-12-18 05:12:04 +00:00
## Install
To use this contribution add it to your `~/.spacemacs`
```elisp
(setq-default dotspacemacs-configuration-layers '(colors)
"List of contribution to load."
)
```
## Key bindings
The prefix associated with colors is <kbd>C</kbd>.
### Rainbow Identifiers
2015-01-24 05:03:40 +00:00
![theme_tweaks_python](img/theme-tweaks-python.png)
2014-12-18 05:12:04 +00:00
`rainbow-identifiers` mode can be toggled on and off with:
<SPC> t C i
Note that the toggle is local to the current buffer.
The `saturation` and `lightness` of identifier colors can be adjusted live
with the micro-state:
Key Binding | Description
--------------|------------------------------------------------------------
`<SPC> C i s` | initiate change `saturation` mini-mode
`<SPC> C i l` | initiate change `lightness` mini-mode
`+` | increase the `saturation` or `lightness`
`-` | decrease the `saturation` or `lightness`
`=` | reset the `saturation` or `lightness`
Any other key | leave the change mini-mode
2015-01-24 05:03:40 +00:00
### Rainbow delimiters
2014-12-18 05:12:04 +00:00
2015-01-24 05:03:40 +00:00
`rainbow-delimiters` mode can be toggled on and off with:
2014-12-18 05:12:04 +00:00
2015-01-24 05:03:40 +00:00
<SPC> t C d
Note that the toggle is local to the current buffer.
### Rainbow Mode
![rainbow_mode](img/rainbow-mode.png)
`rainbow-mode` mode can be toggled on and off with:
<SPC> t C c
Note that the toggle is local to the current buffer.
2014-12-18 05:12:04 +00:00
[rainbow identifiers]: https://github.com/Fanael/rainbow-identifiers
2015-01-24 05:03:40 +00:00
[rainbow delimiters]: https://github.com/Fanael/rainbow-delimiters
[rainbow mode]: https://julien.danjou.info/projects/emacs-packages