summaryrefslogtreecommitdiff
path: root/src/text-buffer.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/text-buffer.c')
-rw-r--r--src/text-buffer.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/text-buffer.c b/src/text-buffer.c
index 215e446..cc764bc 100644
--- a/src/text-buffer.c
+++ b/src/text-buffer.c
@@ -47,6 +47,16 @@ text_buffer_append (text_buffer *tb, char c)
tb->contents[tb->used++] = c;
}
+void
+text_buffer_append_str (text_buffer *tb, char *c, size_t len)
+{
+ size_t i;
+ for (i=0; i<len; i++)
+ {
+ text_buffer_append (tb, c[i]);
+ }
+}
+
char
text_buffer_index (text_buffer *tb, size_t pos)
{