#include "nvim/api/private/converter.h"
#include "nvim/api/private/helpers.h"
#include "nvim/api/vim.h"
#include "nvim/api/vimscript.h"
#include "nvim/context.h"
#include "nvim/eval/encode.h"
#include "nvim/ex_docmd.h"
#include "nvim/option.h"
#include "nvim/shada.h"
Functions | |
void | ctx_free_all (void) |
Clears and frees the context stack. More... | |
size_t | ctx_size (void) |
Returns the size of the context stack. More... | |
Context * | ctx_get (size_t index) FUNC_ATTR_PURE |
void | ctx_free (Context *ctx) FUNC_ATTR_NONNULL_ALL |
void | ctx_save (Context *ctx, const int flags) |
bool | ctx_restore (Context *ctx, const int flags) |
Dictionary | ctx_to_dict (Context *ctx) FUNC_ATTR_NONNULL_ALL |
int | ctx_from_dict (Dictionary dict, Context *ctx) FUNC_ATTR_NONNULL_ALL |
Variables | |
int | kCtxAll |
int ctx_from_dict | ( | Dictionary | dict, |
Context * | ctx | ||
) |
Converts Dictionary representation of Context back to Context object.
[in] | dict | Context Dictionary representation. |
[out] | ctx | Context object to store conversion result into. |
Context* ctx_get | ( | size_t | index | ) |
Returns pointer to Context object with given zero-based index from the top of context stack or NULL if index is out of bounds.
Restores the editor state from a context.
If "context" is NULL, pops context from context stack. Use "flags" to select particular types of context.
ctx | Restore from this context. Pop from context stack if NULL. |
flags | Flags, see ContextTypeFlags enum. |
Saves the editor state to a context.
If "context" is NULL, pushes context on context stack. Use "flags" to select particular types of context.
ctx | Save to this context, or push on context stack if NULL. |
flags | Flags, see ContextTypeFlags enum. |
size_t ctx_size | ( | void | ) |
Returns the size of the context stack.
Dictionary ctx_to_dict | ( | Context * | ctx | ) |
Converts Context to Dictionary representation.
[in] | ctx | Context to convert. |