XenevaOS
Loading...
Searching...
No Matches
devclip.h
Go to the documentation of this file.
1#ifndef __DEV_CLIP_H__
2#define __DEV_CLIP_H__
3
4#include <stdint.h>
5#include <aurora.h>
6
7struct __VFS_NODE__;
8typedef struct __VFS_NODE__ AuVFSNode;
9
10/* One buffer, whole-clipboard semantics. A write replaces the contents, a read
11 * reports what is there without consuming it -- pasting twice has to paste
12 * twice -- and CLIP_IOCODE_CLEAR empties it. Sized for a command line or a
13 * block of text rather than for a file; pasting a file belongs in the VFS. */
14#define CLIPBOARD_MAX 4096
15
16#define CLIP_IOCODE_CLEAR 1
17
18/* AuDevClipInitialise -- mounts /dev/clipboard on the device file system */
19extern void AuDevClipInitialise();
20
21/* AuClipboardSet -- replace the clipboard; a NULL source empties it */
22extern void AuClipboardSet(const void* src, uint32_t len);
23
24/* AuClipboardGet -- copy out up to max bytes, leaving the clipboard intact */
25extern uint32_t AuClipboardGet(void* dst, uint32_t max);
26
27/* AuClipboardLength -- bytes currently held, 0 when empty */
29
30/* AuClipboardClear -- empty the clipboard */
31extern void AuClipboardClear();
32
33#endif
unsigned int uint32_t
Definition acefiex.h:163
void AuClipboardClear()
Definition devclip.c:48
uint32_t AuClipboardLength()
Definition devclip.c:44
void AuDevClipInitialise()
Definition devclip.c:90
uint32_t AuClipboardGet(void *dst, uint32_t max)
Definition devclip.c:34
void AuClipboardSet(const void *src, uint32_t len)
Definition devclip.c:18
size_t len
Definition initial.c:23
#define max(a, b)
Definition minmax.h:28
Definition vfs.h:129