vis: mark output of pipe command as saved
[vis.git] / register.h
blobc8f11bd40afbafe0796894b1b8fd9a7918b4d6d9
1 #ifndef REGISTER_H
2 #define REGISTER_H
4 #include <stddef.h>
5 #include <stdbool.h>
6 #include "buffer.h"
7 #include "text-util.h"
9 #ifndef VIS_H
10 typedef struct Vis Vis;
11 #endif
13 typedef struct {
14 Buffer buf;
15 bool linewise; /* place register content on a new line when inserting? */
16 bool append;
17 enum {
18 REGISTER_NORMAL,
19 REGISTER_BLACKHOLE,
20 REGISTER_CLIPBOARD,
21 } type;
22 } Register;
24 void register_release(Register *reg);
25 const char *register_get(Vis*, Register*reg, size_t *len);
26 bool register_put(Vis*, Register *reg, Text *txt, Filerange *range);
27 bool register_append(Register *reg, Text *txt, Filerange *range);
29 #endif