mirror-ghostty/include/ghostty/vt
Mitchell Hashimoto 11574c35a2
libghostty: expose paste encode to C API
Add ghostty_paste_encode() which encodes paste data for writing to
the terminal pty. It strips unsafe control bytes, wraps in bracketed
paste sequences when requested, and replaces newlines with carriage
returns for unbracketed mode. The input buffer is modified in place
and the encoded result is written to a caller-provided output buffer,
following the same buffer/out_written pattern as the other encode
functions like ghostty_size_report_encode.

Update the c-vt-paste example with an encode_example() demonstrating
the new function and add corresponding @snippet references in the
header documentation.
2026-03-26 11:28:23 -07:00
..
key vt: expose focus encoding in C and Zig APIs 2026-03-16 14:38:19 -07:00
mouse vt: expose focus encoding in C and Zig APIs 2026-03-16 14:38:19 -07:00
allocator.h vt: add ghostty_alloc for buffer allocation 2026-03-23 16:12:29 -07:00
build_info.h vt: expose optimize mode in build info API 2026-03-21 07:31:55 -07:00
color.h lib-vt: Wasm SGR helpers and example (#9362) 2025-10-26 13:19:55 -07:00
device.h vt: expose device_attributes effect in the C API 2026-03-24 11:32:52 -07:00
focus.h docs: extract focus encoding example into standalone project 2026-03-17 16:48:48 -07:00
formatter.h libghostty: add ghostty_free for cross-runtime memory safety 2026-03-23 20:52:02 +01:00
grid_ref.h example: add grid reference traversal example 2026-03-19 19:55:02 -07:00
key.h example: rename some examples 2026-03-17 17:39:26 -07:00
modes.h docs: extract inline code examples into standalone projects 2026-03-17 17:03:58 -07:00
mouse.h example: rename some examples 2026-03-17 17:39:26 -07:00
osc.h vt: add sized struct pattern and types.h 2026-03-14 14:42:50 -07:00
paste.h libghostty: expose paste encode to C API 2026-03-26 11:28:23 -07:00
point.h terminal: convert Point to lib.Enum/lib.TaggedUnion with C header 2026-03-19 14:01:11 -07:00
render.h libghostty: add resolved bg_color and fg_color to cells API 2026-03-21 20:30:01 -07:00
screen.h vt: add color_palette and color_rgb cell data types 2026-03-20 21:18:56 -07:00
sgr.h docs: extract inline code examples into standalone projects 2026-03-17 17:03:58 -07:00
size_report.h docs: extract inline code examples into standalone projects 2026-03-17 17:03:58 -07:00
style.h vt: add style and grapheme accessors 2026-03-19 19:48:16 -07:00
terminal.h vt: expose terminal default colors via C API 2026-03-26 09:51:30 -07:00
types.h vt: expose terminal default colors via C API 2026-03-26 09:51:30 -07:00
wasm.h lib-vt: Wasm SGR helpers and example (#9362) 2025-10-26 13:19:55 -07:00