| Age | Commit message (Collapse) | Author | Files | Lines |
|
Reading from curs_refresh(3X) from curses, calling doupdate() repeatedly
will cause 'several bursts of output to the screen'. wnoutrefresh() has
the smarts to only copy the changed lines to the copied virtual screen,
but doupdate() does not.
There have been several bug reports related to flickering but all seems
to be inconsistenly reproducible due to different terminal buffering
behavior. See #1032, #327
Unfortunately, when I am using a slow display, I still notice
flickering, so this commit changes the routines for opening new windows
and splitting windows to wait until the last change is finished before
calling doupdate().
|
|
This enables restoring the terminal from a fullscreen command like
curses based program. Use cases are e.g. a file picker based on some
external program like nnn (https://github.com/jarun/nnn).
|
|
|
|
|
|
|
|
|
|
|
|
Once we have written all data we should properly close the (correct)
pipe. Before we wrongly closed the pipe connected to the standard output
stream.
More generally, we currently do not listen for child process termination,
but instead wait until all the connected pipes are closed. This might
be problematic in case the external process keeps hold of the standard
I/O file descriptors. One particular example of this is wl-copy(1).
See #929
|
|
|
|
There are two main ways how the input queue is managed in vis:
- vis_keys_feed(..) appends new input to the queue and immediately
starts processing it. Starting from the position before the call
i.e. ignoring any previously queued input.
This is typically used in key binding handlers where the input
queue still contains the mapping leading to the invocation of the
handler. In that case new input should be interpreted immediately,
before the handler eventually returns and its mapping is consumed.
- vis_keys_push(..) with pos=0, appends new input to the end of the
queue and starts processing it from the start of the queue, taking
the full content into consideration.
This is used by the main loop when new input becomes available.
This patch switches the handling of <C-c> after a SIGINT from the former
to the latter mechanism and fixes mappings using <C-c> in a non-leading
position.
|
|
|
|
Add a global ignorecase boolean option. When set add REG_ICASE to cflags
when calling text_regex_compile().
|
|
|
|
|
|
Not sure why we need to allocate space for an additional character.
This also avoids creating out of bound pointers.
|
|
|
|
eg. if your long line is a comment with green fg, and you set your
column color bg red while not specifying the fg, then the result is
green fg on red bg.
Prior to this change the result would be default fg on red bg, thus
one char in the long line of green text would look odd/wrong.
Of course if you do explicitly set the column color fg to default in your
theme then the result will not be what you expect - ideally we need
an UNSPECIFIED color type instead of relying on DEFAULT.
|
|
|
|
|
|
|
|
The core vis code was originally written under the assumption that there
always exists at least one window. However, when being called from the
Lua configuration file during start up this is not yet the case.
In general, Lua code should always be placed within appropriate event
handlers e.g. vis.events.INIT for global configuration. Invoking API
functions depending on an active window from top level statements is
not supported. Where before the editor simply crashed, these changes
turn such code sections into NOPs.
Fix #561
|
|
Special case <C-v><Enter> to still insert a carriage return as discussed
in #656 and changed in 2cfc9c867bdfd4cc3ae3246f31cf636633fe1a5f.
Due to limitations of the current implementation <C-v> is not generic,
i.e. combining it as r<C-v><Enter> will not work.
Fixes #765
|
|
|
|
|
|
Check for end-of-text.
|
|
Valid values are `read`, `mmap` or `auto`.
|
|
|
|
Fix #656
|
|
When the fore and background colors are the same, swapping them has
no effect. Instead use the specified cell attributes. Previously the
CELL_ATTR_REVERSE used in the default selection style was ignored.
In general the default style definitions for non-Lua builds could
probably be improved further.
Fix #635
|
|
Previously `ci<` would have no immediate effect because in operator
pending mode `i<` was wrongly treated as a powwible prefix of `i<Tab>`.
Fix #624
|
|
Use visual mode and :| to filter text through external commands.
The mapping was already reused for selection complement.
|
|
In practice this was never an issue also it is guaranteed that the
terminating zero byte is already there.
Fixes coverity issue 157023.
|
|
This should make it easier to see which window is focused.
|
|
This should also fix coverity issue 157024.
|
|
This partially reverts f9e2b884c15919757651db8b10c033a344a19e75
further jumps after leaving visual mode should not break `gv`.
|
|
|
|
This reverts commit 54ca598fcccff8844bfbe494cd3b325b2fea487f.
The key handling functions are called too often. This for example
causes problems for `r` (replace char) in combination with :langmap.
|
|
|
|
|
|
We now use ' to refer to marks. Mark a is set using 'am and restored
using 'aM while this is slightly harder to type than ma and 'a it is
consistent with register usage for yank/put and allows a default
mark to be used which is handy for quick selection manipulation
primitives.
|
|
The key binding remain the same, but the selections are now stored on
a per-buffer basis.
|
|
This window local register holds the last active selections.
|
|
While the complete alias is added to the input queue,
the called key bindings should only see the keys they
have asked for.
Previously a mapping such as:
:map! normal gv \"^Sv
did not work as expected because the key binding for
the register did reject an invalid multi letter register
name.
Might also influence #581
|
|
This should keep the EOF markers visible when another option is enabled.
The whole UI option handling is a bit of a mess. In the longterm more of
the drawing code should be moved into Lua.
|
|
Conflicts:
view.c
view.h
|
|
Conflicts:
view.c
|
|
Merge overlapping selections.
Fix #582
|
|
|
|
|
|
|