From d931b14863838a8dceed8cd95c71a75a271cca6b Mon Sep 17 00:00:00 2001 From: Albert Cervin Date: Thu, 15 Dec 2022 18:06:59 +0100 Subject: Make minibuffer use an actual buffer Also fix some issues with inserting multibyte chars. --- src/text.h | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/text.h') diff --git a/src/text.h b/src/text.h index 708ef09..e6f681a 100644 --- a/src/text.h +++ b/src/text.h @@ -10,6 +10,11 @@ struct render_cmd; struct text *text_create(uint32_t initial_capacity); void text_destroy(struct text *text); +/** + * Clear the text without reclaiming memory + */ +void text_clear(struct text *text); + void text_append(struct text *text, uint32_t line, uint32_t col, uint8_t *bytes, uint32_t nbytes, uint32_t *lines_added, uint32_t *cols_added); -- cgit v1.2.3