libkeymap
2.0.4
Library to manage the Linux keymaps
|
Functions for initialization and release of resources as well as functions to handle parameters. More...
Go to the source code of this file.
Functions | |
struct lk_ctx * | lk_init (void) |
int | lk_free (struct lk_ctx *ctx) |
lk_flags | lk_get_parser_flags (struct lk_ctx *ctx) |
int | lk_set_parser_flags (struct lk_ctx *ctx, lk_flags flags) |
int | lk_get_log_priority (struct lk_ctx *ctx) |
int | lk_set_log_priority (struct lk_ctx *ctx, int priority) |
int | lk_set_log_fn (struct lk_ctx *ctx, void(*log_fn)(void *data, int priority, const char *file, int line, const char *fn, const char *format, va_list args), const void *data) |
Functions for initialization and release of resources as well as functions to handle parameters.
struct lk_ctx* lk_init | ( | void | ) | [read] |
Initializes the structures necessary to read and/or parse keymap.
int lk_free | ( | struct lk_ctx * | ctx | ) |
Free keymap resources.
ctx | is a keymap library context. |
lk_flags lk_get_parser_flags | ( | struct lk_ctx * | ctx | ) |
Get the parser flags.
ctx | is a keymap library context. |
int lk_set_parser_flags | ( | struct lk_ctx * | ctx, |
lk_flags | flags | ||
) |
Set the parser flags.
ctx | is a keymap library context. |
flags | the new value of the flags. |
int lk_get_log_priority | ( | struct lk_ctx * | ctx | ) |
Get the current logging priority.
ctx | is a keymap library context. |
int lk_set_log_priority | ( | struct lk_ctx * | ctx, |
int | priority | ||
) |
Set the current logging priority. The value controls which messages get logged.
ctx | is a keymap library context. |
int lk_set_log_fn | ( | struct lk_ctx * | ctx, |
void(*)(void *data, int priority, const char *file, int line, const char *fn, const char *format, va_list args) | log_fn, | ||
const void * | data | ||
) |
The built-in logging writes to stderr. It can be overridden by a custom function to plug log messages into the user's logging functionality.
ctx | keymap library context |
log_fn | function to be called for logging messages |
data | data to pass to log function |