ELinks 0.16.1.1
keybinding.c File Reference
#include "scripting/python/pythoninc.h"
#include <stdarg.h>
#include <string.h>
#include "elinks.h"
#include "config/kbdbind.h"
#include "intl/libintl.h"
#include "main/event.h"
#include "scripting/python/core.h"
#include "scripting/python/keybinding.h"
#include "session/session.h"
#include "util/error.h"
#include "util/string.h"
Include dependency graph for keybinding.c:

Functions

static enum evhook_status invoke_keybinding_callback (va_list ap, void *data)
static int keymap_is_valid (const char *keymap)
PyObject * python_bind_key (PyObject *self, PyObject *args, PyObject *kwargs)
void python_done_keybinding_interface (void)

Variables

PyObject * keybindings = NULL
char python_bind_key_doc []

Function Documentation

◆ invoke_keybinding_callback()

enum evhook_status invoke_keybinding_callback ( va_list ap,
void * data )
static

◆ keymap_is_valid()

int keymap_is_valid ( const char * keymap)
static

◆ python_bind_key()

PyObject * python_bind_key ( PyObject * self,
PyObject * args,
PyObject * kwargs )

◆ python_done_keybinding_interface()

void python_done_keybinding_interface ( void )

Variable Documentation

◆ keybindings

PyObject* keybindings = NULL

◆ python_bind_key_doc

char python_bind_key_doc[]
Initial value:
=
PYTHON_DOCSTRING("bind_key(keystroke, callback[, keymap]) -> None\n\
\n\
Bind a keystroke to a callable object.\n\
\n\
Arguments:\n\
\n\
keystroke -- A string containing a keystroke. The syntax for\n\
keystrokes is described in the elinkskeys(5) man page.\n\
callback -- A callable object to be called when the keystroke is\n\
typed. It will be called without any arguments.\n\
\n\
Optional arguments:\n\
\n\
keymap -- A string containing the name of a keymap. Valid keymap\n\
names can be found in the elinkskeys(5) man page. By\n\
default the \"main\" keymap is used.\n")
#define PYTHON_DOCSTRING(str)
Definition core.h:46