#include <assert.h>
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#include "nvim/api/private/defs.h"
#include "nvim/api/private/helpers.h"
#include "nvim/api/ui.h"
#include "nvim/cursor_shape.h"
#include "nvim/highlight.h"
#include "nvim/map.h"
#include "nvim/memory.h"
#include "nvim/msgpack_rpc/channel.h"
#include "nvim/option.h"
#include "nvim/popupmnu.h"
#include "nvim/screen.h"
#include "nvim/ui.h"
#include "nvim/vim.h"
#include "nvim/window.h"
Data Structures | |
struct | UIData |
Functions | |
void | remote_ui_wait_for_attach (void) |
Wait until ui has connected on stdio channel. More... | |
void | nvim_ui_attach (uint64_t channel_id, Integer width, Integer height, Dictionary options, Error *err) FUNC_API_SINCE(1) FUNC_API_REMOTE_ONLY |
void | ui_attach (uint64_t channel_id, Integer width, Integer height, Boolean enable_rgb, Error *err) FUNC_API_DEPRECATED_SINCE(1) |
void | nvim_ui_detach (uint64_t channel_id, Error *err) FUNC_API_SINCE(1) FUNC_API_REMOTE_ONLY |
void | nvim_ui_try_resize (uint64_t channel_id, Integer width, Integer height, Error *err) FUNC_API_SINCE(1) FUNC_API_REMOTE_ONLY |
void | nvim_ui_set_option (uint64_t channel_id, String name, Object value, Error *error) FUNC_API_SINCE(1) FUNC_API_REMOTE_ONLY |
void | nvim_ui_try_resize_grid (uint64_t channel_id, Integer grid, Integer width, Integer height, Error *err) FUNC_API_SINCE(6) FUNC_API_REMOTE_ONLY |
void | nvim_ui_pum_set_height (uint64_t channel_id, Integer height, Error *err) FUNC_API_SINCE(6) FUNC_API_REMOTE_ONLY |
void | nvim_ui_pum_set_bounds (uint64_t channel_id, Float width, Float height, Float row, Float col, Error *err) FUNC_API_SINCE(7) FUNC_API_REMOTE_ONLY |
void nvim_ui_attach | ( | uint64_t | channel_id, |
Integer | width, | ||
Integer | height, | ||
Dictionary | options, | ||
Error * | err | ||
) |
Activates UI events on the channel.
Entry point of all UI clients. Allows |--embed| to continue startup. Implies that the client is ready to show the UI. Adds the client to the list of UIs. |nvim_list_uis()|
channel_id | ||
width | Requested screen columns | |
height | Requested screen rows | |
options | |ui-option| map | |
[out] | err | Error details, if any |
Deactivates UI events on the channel.
Removes the client from the list of UIs. |nvim_list_uis()|
channel_id | ||
[out] | err | Error details, if any |
void nvim_ui_pum_set_bounds | ( | uint64_t | channel_id, |
Float | width, | ||
Float | height, | ||
Float | row, | ||
Float | col, | ||
Error * | err | ||
) |
Tells Nvim the geometry of the popumenu, to align floating windows with an external popup menu.
Note that this method is not to be confused with |nvim_ui_pum_set_height()|, which sets the number of visible items in the popup menu, while this function sets the bounding box of the popup menu, including visual elements such as borders and sliders. Floats need not use the same font size, nor be anchored to exact grid corners, so one can set floating-point numbers to the popup menu geometry.
channel_id | ||
width | Popupmenu width. | |
height | Popupmenu height. | |
row | Popupmenu row. | |
col | Popupmenu height. | |
[out] | err | Error details, if any. |
Tells Nvim the number of elements displaying in the popumenu, to decide <PageUp> and <PageDown> movement.
channel_id | ||
height | Popupmenu height, must be greater than zero. | |
[out] | err | Error details, if any |
void nvim_ui_try_resize_grid | ( | uint64_t | channel_id, |
Integer | grid, | ||
Integer | width, | ||
Integer | height, | ||
Error * | err | ||
) |
Tell Nvim to resize a grid. Triggers a grid_resize event with the requested grid size or the maximum size if it exceeds size limits.
On invalid grid handle, fails with error.
channel_id | ||
grid | The handle of the grid to be changed. | |
width | The new requested width. | |
height | The new requested height. | |
[out] | err | Error details, if any |