Man page - termkey_push_bytes(3)
Packages contains this manual
- termkey_canonicalise(3)
- termkey_getkey(3)
- termkey_get_buffer_remaining(3)
- termkey(7)
- termkey_set_flags(3)
- termkey_interpret_position(3)
- termkey_advisereadable(3)
- termkey_start(3)
- termkey_set_waittime(3)
- termkey_keyname2sym(3)
- termkey_set_buffer_size(3)
- termkey_interpret_csi(3)
- termkey_get_keyname(3)
- termkey_set_canonflags(3)
- termkey_interpret_mouse(3)
- termkey_new(3)
- termkey_get_fd(3)
- termkey_interpret_string(3)
- termkey_strpkey(3)
- termkey_waitkey(3)
- termkey_strfkey(3)
- termkey_interpret_modereport(3)
- termkey_lookup_keyname(3)
- termkey_push_bytes(3)
- termkey_keycmp(3)
apt-get install libtermkey-dev
Manual
TERMKEY_PUSH_BYTES
NAMESYNOPSIS
DESCRIPTION
RETURN VALUE
SEE ALSO
NAME
termkey_push_bytes - supply more bytes to the input buffer
SYNOPSIS
#include <termkey.h>
size_t termkey_push_bytes(TermKey * tk , const char * bytes , size_t len );
Link with -ltermkey .
DESCRIPTION
termkey_push_bytes () allows more bytes of input to be supplied directly into the input buffer of the termkey (7) instance. If there was no buffer space remaining then -1 is returned with errno set to ENOMEM .
This function, along with termkey_getkey (3), makes it possible to use the termkey instance with a source of bytes other than from reading a filehandle.
For synchronous usage, termkey_waitkey (3) performs the input blocking task. For use against a regular stream filehandle that supports read (2), see termkey_advisereadable (3).
RETURN VALUE
termkey_push_bytes () the number of bytes consumed from the input (which may be smaller than the length provided, if the buffer runs out of space) or -1 cast to size_t if an error occurs, in which case errno is set accordingly.
SEE ALSO
termkey_getkey (3), termkey_advisereadable (3), termkey (7)