1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

clipboard: document all pub functions, adhere to vdoc style (#8243)

This commit is contained in:
Larpon
2021-01-21 12:45:59 +01:00
committed by GitHub
parent 59c3e98c16
commit 62c2168b0b
7 changed files with 53 additions and 28 deletions

View File

@ -54,8 +54,8 @@ struct Clipboard {
max_retries int
retry_delay int
mut:
hwnd C.HWND
foo int // TODO remove
hwnd C.HWND
foo int // TODO remove
}
fn (cb &Clipboard) get_clipboard_lock() bool {
@ -178,6 +178,8 @@ fn (mut cb Clipboard) get_text() string {
return str
}
// new_primary returns a new X11 `PRIMARY` type `Clipboard` instance allocated on the heap.
// Please note: new_primary only works on X11 based systems.
pub fn new_primary() &Clipboard {
panic('Primary clipboard is not supported on non-Linux systems.')
}