diff options
| author | Marc André Tanner <mat@brain-dump.org> | 2017-01-31 09:10:07 +0100 |
|---|---|---|
| committer | Marc André Tanner <mat@brain-dump.org> | 2017-01-31 09:40:28 +0100 |
| commit | 963c238ff8d3f734bd852669d379e951f4fc7649 (patch) | |
| tree | 6b0f1688b04e6ce7c2cddccbe29281b264fa34b7 /vis.c | |
| parent | eca2fbb4c6d9de94f7a4cb1140819246425bebbd (diff) | |
| download | vis-963c238ff8d3f734bd852669d379e951f4fc7649.tar.gz vis-963c238ff8d3f734bd852669d379e951f4fc7649.tar.xz | |
vis: add workaround for broken color handling in Terminal.app
Terminal.app sets $TERM=xterm-256color and ships a corresponding
terminfo description advocating that it is capable of color changes
to the 256 color palette when in fact it can not.
We introduce a new boolean option "change-256colors" which is
true by default but can be used to disable color changes. It is
automatically set if Terminal.app is detected using $TERM_PROGRAM.
This should fix display artifacts as described in #456.
Diffstat (limited to 'vis.c')
| -rw-r--r-- | vis.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -532,6 +532,7 @@ Vis *vis_new(Ui *ui, VisEvent *event) { vis->ui = ui; vis->tabwidth = 8; vis->expandtab = false; + vis->change_colors = true; vis->registers[VIS_REG_BLACKHOLE].type = REGISTER_BLACKHOLE; vis->registers[VIS_REG_CLIPBOARD].type = REGISTER_CLIPBOARD; array_init(&vis->motions); |
