Maxime Coste
73ae3d292f
implement finding kak executable path on MacOS
2012-01-20 21:12:57 +00:00
Maxime Coste
bb36271ae5
HighlighterGroup: use idvaluemap::complete_id_if in complete_group_id
2012-01-19 20:53:15 +00:00
Maxime Coste
ce6b4c2cc4
idvaluemap: complete_id_if method for conditional id completion
2012-01-19 20:52:08 +00:00
Maxime Coste
2824bd9a46
HighlighterGroup: move to it's own file, Window uses them directly
2012-01-19 20:37:29 +00:00
Maxime Coste
541872cafa
completion support for addgrouphl and rmgrouphl
2012-01-18 11:33:58 +00:00
Maxime Coste
cffdbcb689
replace addhl -group with addgrouphl command, and add rmgrouphl
2012-01-18 00:15:10 +00:00
Maxime Coste
ae8882b0de
Context: do not permit access to window or buffer if null
2012-01-15 21:33:35 +00:00
Maxime Coste
a6930395b8
tweak kakrc files highlighting
2012-01-15 17:50:46 +00:00
Maxime Coste
c1f625054a
split kakrc with filetype specific files in rc/
...
cpp highlighting is now specified by rc/cpp.kak.
2012-01-15 17:35:25 +00:00
Maxime Coste
c62b3b251d
add a runtime command to execute files in the runtime directory
2012-01-15 17:34:05 +00:00
Maxime Coste
f99c3a1a6a
kakrc: use a hlkakrc highlighter group for kakrc highlighting regex
2012-01-15 13:48:48 +00:00
Maxime Coste
f3e8498a58
addhl supports a -group option
...
-group <group_id> can be used to add the highlighter in a
highlighter group which will be then handled as a whole.
2012-01-15 13:47:12 +00:00
Maxime Coste
98f937146a
HighlighterRegistry: add add_highlighter_to_group method
2012-01-15 13:46:45 +00:00
Maxime Coste
2cfa70a466
Window: add get_highlighter_group method
2012-01-15 13:46:12 +00:00
Maxime Coste
0c1e763d66
Highlighters: add an HighlighterGroup class
2012-01-15 13:45:18 +00:00
Maxime Coste
5092456186
Highlighters: move HighlighterParameters definition from highlighter_registry.hh to highlighter.hh
2012-01-15 13:44:16 +00:00
Maxime Coste
7599edffa9
idvaluemap: add missing includes
2012-01-15 13:40:58 +00:00
Maxime Coste
0234378bcf
kakrc: refactor using lists of commands for hooks
2012-01-15 03:04:37 +00:00
Maxime Coste
f259af9326
CommandManager: add flags support and IgnoreSemiColons flag
...
commands are now registred with flags, and the IgnoreSemiColons
flag permit to specify a command which needs all the parameters
on the line, bypassing the command sequence operator ';'.
the hook command is tagged as such.
2012-01-15 03:02:08 +00:00
Maxime Coste
be5cf92367
Completion: sort results in complete_filename
2012-01-15 02:02:18 +00:00
Maxime Coste
f673f3c334
Completion: handle hidden files in complete_filenam
2012-01-15 02:01:58 +00:00
Maxime Coste
49ea6f7103
correctly clear the window status line
2012-01-15 01:45:23 +00:00
Maxime Coste
4a5758ebb3
CommandManager: support ';' as a command separator
2012-01-15 01:37:35 +00:00
Maxime Coste
272f2d87a1
Highlighters: tweak colorize_cplusplus
2012-01-14 14:12:20 +00:00
Maxime Coste
95db828e17
CommandManager: use directly first command parameter as the command name
2012-01-14 14:02:54 +00:00
Maxime Coste
66d91b8828
support '\' as a line continuation marker when executing commands in file
2012-01-14 13:50:45 +00:00
Maxime Coste
fea81e1378
kakrc: add support for kakrc file highlighting
2012-01-14 01:04:08 +00:00
Maxime Coste
50ce3d1549
Document some Kakoune concepts, as Window, Buffer, DisplayAtom...
2012-01-11 14:21:58 +00:00
Maxime Coste
9557167f26
<space> with a count argument replaces current selections with the counth selection.
2012-01-09 14:28:01 +00:00
Maxime Coste
e02cb4e5bd
Selectors: select_next_match starts from cursor+1
...
so searching effectively starts on the character after current
selection end. Which makes repeating 'n' on a one character match
work.
2012-01-09 14:22:52 +00:00
Maxime Coste
8b1b1d9cd8
Selectors: add select_surrounding to select blocks
...
Alt-a followed by []()<>{}bB selects the block surrounding current
selection end.
Alt-i is similar but selects only the inside of the block.
2012-01-04 14:18:08 +00:00
Maxime Coste
e59bdd931e
search for kakrc next to the kak executable instead of in the current directory
2011-12-28 22:57:48 +00:00
Maxime Coste
4de41197c0
Add a | key that pipes each selection through an external filter
2011-12-28 19:04:06 +00:00
Maxime Coste
c9ac4d615d
Highlighters: tweak colorize_cplusplus
2011-12-28 18:52:35 +00:00
Maxime Coste
0e398566d2
Buffer: fix compute_lines on empty_buffer
2011-12-28 18:52:14 +00:00
Maxime Coste
aa1c4d64f9
Completions: complete_filename correctly support directories
2011-12-22 13:44:04 +00:00
Maxime Coste
6fa5d809ef
whitespace fix
2011-12-22 13:33:29 +00:00
Maxime Coste
67c08e598b
IncrementalInserter: preserve selection through hook call
2011-12-21 19:06:51 +00:00
Maxime Coste
f77fc3980b
Window: store a stack of selections
2011-12-21 19:06:26 +00:00
Maxime Coste
c11b548662
kakrc: cleanup trailing whitespaces when quiting insert mode
2011-12-21 18:58:41 +00:00
Maxime Coste
70bb4847ee
IncrementalInserter: catch exception thrown by the hook
2011-12-21 18:57:07 +00:00
Maxime Coste
6c817c8117
Window: do not manage undo groups when an inserter is active
2011-12-21 18:56:32 +00:00
Maxime Coste
913ee3f096
Use Keys instead of char for keymap
2011-12-21 14:29:28 +00:00
Maxime Coste
ba1fe056f4
Add an exec command, similar to vim normal command
2011-12-20 19:22:05 +00:00
Maxime Coste
7116ed6d61
Window: throw when multiselect results in no selections
2011-12-20 19:27:13 +00:00
Maxime Coste
42a24895de
Add Key struct
2011-12-20 19:21:11 +00:00
Maxime Coste
91606850fd
Utils: add on_scope_end utility
...
on_scope_end permits to register a functor to be called at scope
end (either exception thrown or normal scope end). this is usefull
for cleanup code that must be run.
usage:
auto cleaner = on_scope_end([]() { cleanup(); });
2011-12-20 19:18:00 +00:00
Maxime Coste
17cab9c7c4
Filters: add cleanup_whitespace filter
...
this filter remove trailing whitespaces on the previous line
when inserting an end-of-line.
2011-12-20 14:27:01 +00:00
Maxime Coste
e77f58c010
better rvalue reference forwarding
2011-12-07 18:57:07 +00:00
Maxime Coste
2239fb6e49
Filters: move from buffer to window
2011-12-07 14:29:10 +00:00
Maxime Coste
c40eb2b03a
Buffer: replace insert and erase methods with modify
...
modify directly takes a Modification as parameter
2011-12-07 14:26:40 +00:00
Maxime Coste
2edddfe009
Buffer: rename BufferModification to Modification
2011-12-06 18:58:43 +00:00
Maxime Coste
73cebb9072
kakrc: do not highlight the end-of-line in trailing whitespaces
2011-12-06 18:50:05 +00:00
Maxime Coste
b245d80c4e
Window: preserve current selection when empty multi_select
2011-12-05 19:21:16 +00:00
Maxime Coste
4ae2fcffbd
Buffer: add comment for clamp
2011-12-05 19:21:11 +00:00
Maxime Coste
711c05b81e
Window: fix trailing spaces
2011-12-05 14:29:36 +00:00
Maxime Coste
23eafd4504
Add a repeat last insert command, bound to .
2011-12-05 14:28:45 +00:00
Maxime Coste
d1cc5da8a6
Filters: add expand_tabulations to insert spaces instead of tabs
2011-12-03 20:25:05 +00:00
Maxime Coste
74a315cd0e
kakrc: add preserve_indent filter on c++ files and highlight trailing spaces
2011-12-02 19:01:08 +00:00
Maxime Coste
c761420055
fix exec_commands_in_file
2011-12-02 19:00:37 +00:00
Maxime Coste
11d606f79e
{Filter,Highlighter}Registry: more infos on factory not found
2011-12-02 19:00:01 +00:00
Maxime Coste
0b4ed2280f
Buffer: call BufCreate hook on construction
2011-12-02 18:59:18 +00:00
Maxime Coste
8e39edc567
DynamicBufferIterator: fix end of buffer corner case
2011-12-02 18:57:18 +00:00
Maxime Coste
b1daf8de16
Selectors: fix select_line on the last line
2011-12-02 18:56:18 +00:00
Maxime Coste
94d59cc4dd
Buffer: add filter support
...
filters are functions called prior to applying a modification
to a buffer. They can manipulate the modification to change
the editor behaviour.
2011-12-02 14:28:27 +00:00
Maxime Coste
8e06e168d9
HighlighterRegistry: use idvaluemap to store factories
2011-12-02 14:22:51 +00:00
Maxime Coste
4252e0d610
Window: use an idvaluemap to store highlighters
2011-12-02 14:20:11 +00:00
Maxime Coste
a5a726d291
Add idvaluemap container
...
it is a vector based map, preserving insertion order and providing
completion on ids it contains.
2011-12-02 14:18:31 +00:00
Maxime Coste
934e62b502
stop clearing selections all the time
2011-11-30 14:18:54 +00:00
Maxime Coste
d8dd782960
Highlighters: style fix
2011-11-30 14:11:53 +00:00
Maxime Coste
0b48525b35
Window: do not stay on an eol when clearing selections
2011-11-29 22:48:00 +00:00
Maxime Coste
0859b20bcf
Rename Filter to Highlighter to be more explicit
2011-11-29 22:37:20 +00:00
Maxime Coste
e89516f2a3
IncrementalInserter: refactoring
2011-11-29 21:35:50 +00:00
Maxime Coste
b24dec89a2
Buffer: add iterator_at_line_{begin,end} methods
2011-11-28 19:31:29 +00:00
Maxime Coste
51ee0b61f4
DynamicBufferIterator: use const_cast instead of having a mutable field in Buffer
2011-11-28 18:55:17 +00:00
Maxime Coste
46a01b5a0b
Debug: stop writing key codes to debug buffer and cleanups
2011-11-28 18:52:29 +00:00
Maxime Coste
dc642f8afa
Buffer: refactor to remove do_{insert,erase} methods
2011-11-27 18:41:25 +00:00
Maxime Coste
08ba791ff4
Add a kakrc file which automatically enables hlcpp on c/c++ files
2011-11-27 13:02:50 +00:00
Maxime Coste
70e0393c4d
Add a source command to execute commands from file
...
a kakrc file in current directory is sourced automatically
at start
2011-11-27 12:59:59 +00:00
Maxime Coste
de19aeb035
File: extract read_file function which returns file content in a string
2011-11-27 12:56:38 +00:00
Maxime Coste
b59a0816b9
Add wq and wq! commands
2011-11-26 19:11:24 +00:00
Maxime Coste
e36153f035
CommandManager: fix complete and style tweak
2011-11-26 19:05:49 +00:00
Maxime Coste
a00961da99
Add hook command
2011-11-26 18:41:55 +00:00
Maxime Coste
dd2896ecc8
Window: call WinCreate hook on creation
2011-11-26 18:39:59 +00:00
Maxime Coste
9c117a821c
Filters: fix colorize_regex_range when range is not visible
2011-11-26 18:34:49 +00:00
Maxime Coste
68f3d24199
HooksManager: replace HookContext with Context
2011-11-26 18:34:10 +00:00
Maxime Coste
957446dee4
Add a Context parameter to commands
2011-11-26 18:32:57 +00:00
Maxime Coste
417802cbdf
CommandManager: argument splitting supports "multi word"
...
works with " and '
2011-11-26 17:20:02 +00:00
Maxime Coste
9775958012
Add a HooksManager class
2011-11-25 14:26:29 +00:00
Maxime Coste
9a4d8d5f4d
Filters: tweak colorize_cplusplus
2011-11-24 19:13:58 +00:00
Maxime Coste
dcfb5e15f2
SelectionHighlighter: highlight end of lines in selection
2011-11-24 19:13:38 +00:00
Maxime Coste
ea2aeea3a4
Filters: generalize colorize_regex in colorize_regex_range
2011-11-24 19:11:58 +00:00
Maxime Coste
2549a63c0b
Selectors: fix corner cases on first/last buffer char
2011-11-24 18:46:35 +00:00
Maxime Coste
30b4fb6513
Buffer: fix handling of last eol
2011-11-24 14:23:41 +00:00
Maxime Coste
7b09b34cab
Selectors: fix select_whole_lines
2011-11-22 18:58:05 +00:00
Maxime Coste
d27aaab066
use alt-x instead of , to select whole lines
2011-11-22 14:31:20 +00:00
Maxime Coste
a1200aacad
Add alt-j command to join lines
2011-11-22 14:24:50 +00:00
Maxime Coste
95f87a6694
Window: add replace method
...
permits to replace selection by a string in a single undo step
2011-11-22 14:23:46 +00:00
Maxime Coste
a7309fbe87
IncrementalInserter: fix erase
2011-11-21 22:18:00 +00:00
Maxime Coste
7861ad9ddb
Selectors: add split_selection bound to Alt-s
2011-11-21 19:30:44 +00:00