aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/api/ui.c
Commit message (Collapse)AuthorAge
...
* refactor: remove redundant const char * castsii142023-04-07
|
* fix(api): make nvim_get_hl return 'cterm' attrs properlybfredl2023-03-23
|
* feat(api): add nvim_get_hl (#22693)Null Chilly2023-03-23
| | | | | Problem: no way of getting all highlight group definitions in a namespace. Solution: add `nvim_get_hl()`, deprecate `nvim_get_hl_by_name()` and `nvim_get_hl_by_id()`.
* feat(ui): restore has('gui_running')Justin M. Keyes2023-02-27
| | | | | | | | | | Problem: has('gui_running') is still common in the wild and our answer has changed over time, causing frustration. https://github.com/vimpostor/vim-tpipeline/commit/95a6ccbe9f33bc42dd4cee45731d8bc3fbcd92d1 Solution: Use stdin_tty/stdout_tty to decide if a UI is (not) a GUI.
* feat(api): more fields in nvim_list_uisJustin M. Keyes2023-02-27
| | | | | | | | Problem: nvim_list_uis does not report all ":help ui-option" fields. Solution: Store ":help ui-option" fields on the `UI` object and update ui_array.
* docs: fix typos (#22353)zeertzjq2023-02-22
|
* docs: fix typos (#21961)dundargoc2023-02-20
| | | Co-authored-by: Ben Morgan <cassava@iexu.de>
* refactor(api): VALIDATE macros #22256Justin M. Keyes2023-02-14
| | | | | | - VALIDATE() takes a format string - deduplicate check_string_array - VALIDATE_RANGE - validate UI args
* fix(ui-ext): force cursor update after resize in char-based UIzeertzjq2023-02-13
| | | | Neither ui/screen.lua nor Neovim Qt keep cursor position after resizing.
* perf(ui): mitigate redraw latency regression from TUI refactorbfredl2023-02-08
| | | | | | | | | | | | | | | | | | | | | While the new RPC encoder/decoder implementation in general should have less overhead than the deleted UIBridge serializer previously used for the TUI, it regresses on redraw latency in one important aspect. The old bridge implementation allowed the TUI to process a previous screen line internally in parallel with the main thread rendering the next one in win_line etc. As printing the escape sequences in highlighted cells has a considerable hit in profiles, this has a substantial effect on redraw latency. The RPC implementation, however, waits with sending any data until either a flush, or the buffer is full. This change lowers the granularity of communication again, using an adjustable threshold counted in number of cell events (discounting long repeats and clearing as maximum a single extra event). The current value is guesstimated to something simple on a reasonable scale, which should be bigger than a single line, but multiple events for a big multi-window screen.
* refactor: fix IWYU mapping file and use IWYU (#21802)dundargoc2023-01-15
| | | Also add the EXITFREE definition to main_lib rather than the nvim target, as the header generation needs the EXITFREE flag to work properly.
* refactor(ui): devirtualize the ui layerbfredl2023-01-05
| | | | | | | | | | | | | | | | | - The defined interface for the UI is only the RPC protocol. The original UI interface as an array of function pointers fill no function. - On the server, all the UI:s are all RPC channels. - ui.c is only used on the server. - The compositor is a preprocessing step for single-grid UI:s - on the client, ui_client and tui talk directly to each other - we still do module separation, as ui_client.c could form the basis of a libnvim client module later. Items for later PR:s - vim.ui_attach is still an unhappy child, reconsider based on plugin experience. - the flags in ui_events.in.h are still a mess. Can be simplified now. - UX for remote attachment needs more work. - startup for client can be simplified further (think of the millisecs we can save)
* fix(tui): more work in the TUIbfredl2022-12-31
|
* feat(tui): run TUI as external processhlpr982022-12-31
|
* build: allow IWYU to fix includes for all .c filesdundargoc2022-11-15
| | | | | | | | | | Allow Include What You Use to remove unnecessary includes and only include what is necessary. This helps with reducing compilation times and makes it easier to visualise which dependencies are actually required. Work on https://github.com/neovim/neovim/issues/549, but doesn't close it since this only works fully for .c files and not headers.
* refactor: clang-tidy fixes to silence clangd warning (#20683)dundargoc2022-10-21
| | | | | | | | | | | | | | | | | | | | | | | | | * refactor: readability-uppercase-literal-suffix * refactor: readability-named-parameter * refactor: bugprone-suspicious-string-compare * refactor: google-readability-casting * refactor: readability-redundant-control-flow * refactor: bugprone-too-small-loop-variable * refactor: readability-non-const-parameter * refactor: readability-avoid-const-params-in-decls * refactor: google-readability-todo * refactor: readability-inconsistent-declaration-parameter-name * refactor: bugprone-suspicious-missing-comma * refactor: remove noisy or slow warnings
* docs: fix typos (#20150)dundargoc2022-09-26
| | | | | | | Co-authored-by: Miguel Carneiro <mcarneiromorenas@gmail.com> Co-authored-by: Gregory Anders <greg@gpanders.com> Co-authored-by: Raphael <glephunter@gmail.com> Co-authored-by: C.D. MacEachern <craig.daniel.maceachern@gmail.com> Co-authored-by: zeertzjq <zeertzjq@outlook.com>
* refactor: replace char_u with charDundar Göc2022-09-11
| | | | Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u with charDundar Göc2022-09-09
| | | | Work on https://github.com/neovim/neovim/issues/459
* Merge pull request #20023 from bfredl/hlarenabfredl2022-09-01
|\ | | | | refactor(highlight): make hlattrs2dict always use pre-allocated dict
| * refactor(highlight): make hlattrs2dict always use pre-allocated dictbfredl2022-08-31
| | | | | | | | | | hlattrs2dict used to work with both allocated and unallocated dicts which was quite messy. Now always delegate allocation to caller.
* | feat(lua): vim.ui_attach to get ui events from luabfredl2022-08-31
|/ | | | Co-authored-by: Famiu Haque <famiuhaque@protonmail.com>
* refactor(api): provide a temporary copy solution for nvim_call_atomicbfredl2022-08-24
| | | | | | Make the copy_object() family accept an optional arena. More than half of the callsites should be refactored to use an arena later anyway.
* vim-patch:8.1.2082: rename popupmnu.* to popupmenu.* (#19829)zeertzjq2022-08-18
| | | | | | | vim-patch:8.1.2082: some files have a weird name to fit in 8.3 characters Problem: Some files have a weird name to fit in 8.3 characters. Solution: Use a nicer names. https://github.com/vim/vim/commit/30e8e73506e4522ef4aebf7d525c0e6ffe8805fd
* refactor: remove some unused includes (#19820)zeertzjq2022-08-17
| | | Replace grid.h in screen.h and screen.h in buffer.h with grid_defs.h
* refactor: use CLEAR_FIELD and CLEAR_POINTER macros (#19709)zeertzjq2022-08-11
| | | | | | | vim-patch:8.2.0559: clearing a struct is verbose Problem: Clearing a struct is verbose. Solution: Define and use CLEAR_FIELD() and CLEAR_POINTER(). https://github.com/vim/vim/commit/a80faa8930ed5a554beeb2727762538873135e83
* docs: fix typos (#19588)dundargoc2022-08-03
| | | | Co-authored-by: zeertzjq <zeertzjq@outlook.com> Co-authored-by: notomo <notomo.motono@gmail.com>
* perf(ui): eliminate spurious memory allocations for hl_attr_define eventbfredl2022-07-18
|
* perf(ui): reduce allocation overhead when encoding "redraw" eventsbfredl2022-06-20
| | | | | | | | | | | | | | | | | Note for external UIs: Nvim can now emit multiple "redraw" event batches before a final "flush" event is received. To retain existing behavior, clients should make sure to update visible state at an explicit "flush" event, not just the end of a "redraw" batch of event. * Get rid of copy_object() blizzard in the auto-generated ui_event layer * Special case "grid_line" by encoding screen state directly to msgpack events with no intermediate API events. * Get rid of the arcane notion of referring to the screen as the "shell" * Array and Dictionary are kvec_t:s, so define them as such. * Allow kvec_t:s, such as Arrays and Dictionaries, to be allocated with a predetermined size within an arena. * Eliminate redundant capacity checking when filling such kvec_t:s with values.
* refactor(uncrustify): set maximum number of consecutive newlines to 2 (#18695)dundargoc2022-05-25
|
* refactor: move more grid functions to grid.c. Clean up some variablesbfredl2022-05-18
|
* refactor: replace char_u variables and functions with charDundar Goc2022-05-07
| | | | Work on https://github.com/neovim/neovim/issues/459
* refactor: replace char_u variables and functions with charDundar Goc2022-05-04
| | | | Work on https://github.com/neovim/neovim/issues/459
* feat(api/ui): win_extmarksYatao Li2022-05-03
|
* fix(coverity): use xstrndup() instead of vim_strsave() (#18363)zeertzjq2022-05-03
|
* refactor(ui): simplify stdin handlingbfredl2022-05-02
|
* refactor(uncrustify): change rules to better align with the style guideDundar Goc2022-04-29
| | | | | | | | | | | | | Add space around arithmetic operators '+' and '-'. Remove space between back-to-back parentheses, i.e. ')(' vs. ') ('. Remove space between '((' or '))' of control statements. Add space between ')' and '{' of control statements. Remove space between function name and '(' on function declaration. Collapse empty blocks between '{' and '}'. Remove newline at the end of the file. Remove newline between 'enum' and '{'. Remove newline between '}' and ')' in a function invocation. Remove newline between '}' and 'while' of 'do' statement.
* feat(api): ui options relevant for remote TUIhlpr982022-04-17
|
* refactor(api): make export of functions opt-in, not opt-outBjörn Linse2021-10-03
|
* refactor: format #15702dundargoc2021-09-18
|
* refactor(map): get rid of spurious subsystem_init() functions due to mapsBjörn Linse2021-08-22
|
* chore: use codespell to spell check #15016dundargoc2021-07-07
|
* decoration: split out "decoration" from "extmark" moduleBjörn Linse2020-11-07
| | | | | Decorations will only grow more complex. move the to a separate file, so that extmark.c remains about extmarks.
* api/ui: simplify popup menu position get/set logic; fix testYatao Li2020-04-28
|
* api/ui: allow set bounds row and col to be less than 0; ui_pum_get_pos: ↵Yatao Li2020-04-28
| | | | return first extui bounds information instead of reducing
* external pum: use floating point geometry; typval: add tv_dict_add_floatYatao Li2020-04-28
|
* ui_pum_get_pos: return internal pum position if external pum pos not foundYatao Li2020-04-28
|
* API/UI: Allow UI to set PUM position and size, and pass the position to ↵Yatao Li2020-04-28
| | | | CompleteChanged
* UIAttach, UIDetachJustin M. Keyes2019-09-12
| | | | | doc: ginit.vim, gvimrc fix #3656
* UIAttach, UIDetachRui Abreu Ferreira2019-09-12
|