Commit Graph

3648 Commits

Author SHA1 Message Date
Maxime Coste
28bcb45b92 Fix bug where idle timers of disabled modes were still run 2017-05-22 16:57:22 +01:00
Maxime Coste
bc11e52960 Remove virtual destructor from OptionManagerWatcher
We should never destruct anything through an OptionManagerWatcher
pointer, so having all those destructor virtual makes no sense.
2017-05-22 10:31:56 +01:00
Maxime Coste
bdcfe30834 Fix scrolling when cursor is on a wrapped part of the last displayed line 2017-05-22 08:54:25 +01:00
Maxime Coste
ad9ad7e603 Fix vertical movement with tabstops
Fixes #1388
2017-05-21 08:24:44 +01:00
Maxime Coste
df4eadd2f5 Merge remote-tracking branch 'danr/Add-modified-value-if-buffer-has-modifications-not-saved' 2017-05-21 06:43:19 +01:00
Maxime Coste
248ffa543b Merge branch 'master' of git://github.com/bmwiedemann/kakoune 2017-05-21 06:34:36 +01:00
Bernhard M. Wiedemann
4788112f2d Always link input files in the same order
to produce bit-identical 'kak' binaries
See https://reproducible-builds.org/ for why this is good.

This change is needed because filesystem ordering is random
and ordering matters for the g++ linker
2017-05-20 22:50:25 +02:00
Bernhard M. Wiedemann
78991c4820 do not embed timestamps in .gz files
using gzip -n to produce bit-identical results
and -9 to compress a bit better
2017-05-20 22:49:36 +02:00
Maxime Coste
b440d9f537 Change <a-z>/<a-Z> to combine selections instead of appending 2017-05-20 10:31:49 +01:00
Dan Rosén
625e7f8249 Add modified value if buffer has modifications not saved
Closes #1386
2017-05-18 17:39:30 +02:00
Maxime Coste
91ed57c985 Make hardware cursor visible in ncurses ui 2017-05-18 06:28:08 +01:00
Maxime Coste
973487abcd Small reorganization in the normal keymap 2017-05-18 06:05:45 +01:00
Maxime Coste
a578c51baf Move constexpr compatible Array struct to meta.hh 2017-05-17 20:20:31 +01:00
Maxime Coste
3917d26709 small code cleanups 2017-05-17 20:17:16 +01:00
Maxime Coste
7acf11c851 Add missing std::move in on_scope_end implementation 2017-05-17 20:12:36 +01:00
Maxime Coste
0229baf6ba Add range-faces -> range-specs rename to the breaking changes message 2017-05-17 19:42:23 +01:00
Maxime Coste
dfaafcd49a Rename range-faces to range-specs
range-faces are now used to replace-range highlighters, where the string
part is not interpretted as a face but as a display line, so the name was
not relevant anymore.
2017-05-17 19:40:52 +01:00
Maxime Coste
44d2db2706 Add a basic replace-ranges highlighter
replace-ranges is takes a range-faces option, but treats the face
string as a display line to be parsed, and replaces the range display
with this display line.
2017-05-15 09:12:10 +01:00
Maxime Coste
468bd63569 Tweak buffer change code so that WinDisplay hooks can use info boxes 2017-05-13 11:18:21 +01:00
Maxime Coste
3a0d9481ac Add the -E switch for server initialization commands
Fixes #1361
2017-05-13 11:05:09 +01:00
Olivier Perret
ec636ce04b update line-flags and flag_lines doc to reflect current status 2017-05-11 20:45:28 +02:00
Maxime Coste
75e6b54ae2 Disable horizontal scroll offset support when wrapping 2017-05-11 09:23:20 +01:00
Maxime Coste
8fa7e67abc Use LineCount instead of int for ncurses assistant margin 2017-05-10 11:35:12 +01:00
Maxime Coste
a0752d8d46 Merge remote-tracking branch 'lenormf/fix-assistant-align' 2017-05-10 11:31:26 +01:00
Olivier Brewaeys
3f42e45ff6 Small spelling error fix
John Doe Copyright Waiver

  I dedicate any and all copyright interest in this software to the
  public domain.  I make this dedication for the benefit of the public at
  large and to the detriment of my heirs and successors.  I intend this
  dedication to be an overt act of relinquishment in perpetuity of all
  present and future rights to this software under copyright law.
2017-05-10 12:17:11 +02:00
Maxime Coste
9300a981eb Add support for the -passes option to the ref highlighter 2017-05-10 10:31:34 +01:00
Maxime Coste
5483a087d2 Make ref highlighter work for all highlight passes 2017-05-10 08:16:31 +01:00
Maxime Coste
59a0841baa Update group highlighter docstring to document the passes option 2017-05-09 10:02:01 +01:00
Maxime Coste
12c498a0bd Distinguish between BufferRanges and InclusiveBufferRanges
Fixes #1257
2017-05-08 12:34:57 +01:00
Maxime Coste
f9a609e479 Refactor range highlighting into a struct 2017-05-08 12:05:45 +01:00
Maxime Coste
6a97455b3b Do not push a final spurious command separators when parsing commands
Fixes #1336
2017-05-08 11:46:03 +01:00
Maxime Coste
ad1175fefc Update wrap highlighter docstring 2017-05-08 11:30:51 +01:00
Maxime Coste
b0b40485ce Move SimpleHighlighter as an implementation detail 2017-05-08 11:29:23 +01:00
Maxime Coste
a5d4dbc16e Fix unneeded and wrong splitting of display atom during wrapping 2017-05-07 16:26:14 +01:00
Maxime Coste
e63156bcfb Fix infinite loop with longer than width words in word wrap mode 2017-05-07 16:26:14 +01:00
Maxime Coste
4e9193a975 Slight highlighting related code cleanup 2017-05-07 16:26:14 +01:00
Maxime Coste
b4b08d10b4 Fix assert when wrapping a line that takes more than the full window height 2017-05-07 16:26:14 +01:00
Maxime Coste
17b19dc057 Ensure window position line is inside buffer 2017-05-07 16:26:14 +01:00
Maxime Coste
4032d05c79 Reject 0 wrap column 2017-05-07 16:26:14 +01:00
Maxime Coste
8dd808726d Add support for word wrapping with the -word switch to the wrap highlighter 2017-05-07 16:26:14 +01:00
Maxime Coste
bb17fb6dd3 Add a -passes switch support for the group highlighter 2017-05-07 16:26:14 +01:00
Maxime Coste
fa5ae65f3a Move passes logic to the base Highlighter class
Validate that childs of HighlighterGroup are matching its passes.
2017-05-07 16:26:14 +01:00
Maxime Coste
55631c8d8e Detect errors while parsing flag line and handle them
Fixes #1345
2017-05-07 16:26:14 +01:00
Maxime Coste
053544d740 Disable horizontal scrolling when running a WrapHighlighter 2017-05-07 16:26:14 +01:00
Maxime Coste
23e38a254f Introduce a LineNumberWrapped face 2017-05-07 16:26:14 +01:00
Maxime Coste
39826afde5 Make scrolling around work more correctly with wrapping 2017-05-07 16:26:14 +01:00
Maxime Coste
bd3ba77e96 Make Wrap highlighter only wrap on window width. 2017-05-07 16:26:14 +01:00
Maxime Coste
5ee21ec932 Respect tabstop in Buffer::offset_coord 2017-05-07 16:26:14 +01:00
Maxime Coste
57c2b32d20 Introduce highlighting phases and display setup computation
Highlighters now run in 3 phases:
Wrap, Move, and Colorize. That way we guarantee the wrap
highlighter runs first, then eventual line numbers/flags,
and finally the colorizers.

We also run a `compute_display_setup` method thats responsible
for computing the lines that will be displayed, eventually
scrolling the view to ensure the cursor is visible.
2017-05-07 16:26:14 +01:00
Maxime Coste
a4f9e29d60 Add a wrap highlighter 2017-05-07 16:26:14 +01:00