libghostty
Loading...
Searching...
No Matches
io.h
Go to the documentation of this file.
1
6
7#ifndef GHOSTTY_VT_IO_H
8#define GHOSTTY_VT_IO_H
9
10#include <stdbool.h>
11#include <stddef.h>
12#include <stdint.h>
13
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
48typedef bool (*GhosttyReaderFn)(
49 void* userdata,
50 uint8_t* buffer,
51 size_t capacity,
52 size_t* out_read);
53
76typedef bool (*GhosttyWriterFn)(
77 void* userdata,
78 const uint8_t* data,
79 size_t len);
80
86typedef struct {
87 GhosttyReaderFn read;
88 void* userdata;
90
96typedef struct {
97 GhosttyWriterFn write;
98 void* userdata;
100
101#ifdef __cplusplus
102}
103#endif
104
106
107#endif /* GHOSTTY_VT_IO_H */
bool(* GhosttyWriterFn)(void *userdata, const uint8_t *data, size_t len)
Definition io.h:76
bool(* GhosttyReaderFn)(void *userdata, uint8_t *buffer, size_t capacity, size_t *out_read)
Definition io.h:48