aboutsummaryrefslogtreecommitdiff
path: root/vis-registers.c
AgeCommit message (Collapse)AuthorFilesLines
2025-12-22move all standard library includes into util.hRandy Palamar1-3/+0
2025-02-28buffer: remove buffer_printfRandy Palamar1-1/+2
There was only a single user of this function because buffer_appendf is significantly more useful. Change that caller and reduce the code.
2025-01-12array: delete onelinersRandy Palamar1-6/+6
same as buffer commit Array is completely visible
2025-01-11buffer: clear out one line functionsRandy Palamar1-3/+3
Buffer is fully exposed to the program, no need to rely on the linker to optimize useless code.
2025-01-11buffer: delete pointless buffer_init functionRandy Palamar1-8/+4
lets not make the code harder to read for no reason
2025-01-04remove duplicated read_buffer functionsRandy Palamar1-7/+2
When you take a pointer to a function in C that function is going to appear in full in the final binary. This means that there were 3 sections of the final binary with the exact same code. You could argue that in very high performance programs having that function closer to the current instruction when it is needed will give a performance boost but there are so many other places to gain more significant speed ups in vis before that would be remotely relevant. In fact, removing these allows the buffer_append call to inlined so that buffer_insert can be hopped to directly instead of including a useless hop in the middle.
2024-05-21remove some view pointer chasingRandy Palamar1-1/+1
Same as previous commit each window only has a single View. No need for it to be stored elsewhere in memory.
2024-05-21make View unopaqueRandy Palamar1-1/+1
2023-07-18Add fullscreen param to vis_pipe_collect() and Lua API vis:pipe()Jörg Bakker1-2/+2
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).
2020-09-17vis: provide reverse mapping function for register namesMarc André Tanner1-3/+20
2020-07-17support for primary clipboardJeremy Bobbin1-6/+17
2017-07-11vis: cleanup register related APIMarc André Tanner1-11/+27
Also expose all register slots through the Lua API.
2017-07-08vis: cleanup marks implementationMarc André Tanner1-53/+0
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.
2017-07-07vis: use marks instead of registers to store selectionsMarc André Tanner1-12/+27
The key binding remain the same, but the selections are now stored on a per-buffer basis.
2017-07-04vis: implement `gv` by means of new "^ registerMarc André Tanner1-0/+3
This window local register holds the last active selections.
2017-06-15vis: add function to query which register was specifiedMarc André Tanner1-0/+6
2017-06-15vis: add basic infrastructure to store selections in registersMarc André Tanner1-0/+35
2017-06-15vis: rename uses of Cursor to SelectionMarc André Tanner1-1/+1
2017-06-15view: rename view_cursors_countMarc André Tanner1-1/+1
2017-04-23vis: fix # register countMarc André Tanner1-1/+3
Previously the # register was always reported as containing only one entry. This wrongly caused the first value to be put at all locations. Fix #544
2017-04-20vis: add # register to insert cursor numberMarc André Tanner1-0/+11
2017-04-20vis: start cleaning up register related codeMarc André Tanner1-0/+249
Now that register.h is no longer used by view.h we can move the struct and function declarations to vis-core.h.