Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/DoumanAsh/clipboard-win
/ functions
Functions
118 in github.com/DoumanAsh/clipboard-win
⨍
Functions
118
◇
Types & classes
28
↓ 44 callers
Method
len
(&self)
src/html.rs:23
↓ 29 callers
Method
as_ptr
(&self)
src/html.rs:28
↓ 26 callers
Method
get
(&self)
src/utils.rs:93
↓ 14 callers
Method
as_mut_ptr
(&mut self)
src/utils.rs:187
↓ 10 callers
Method
lock
(&self)
src/utils.rs:107
↓ 9 callers
Method
write_clipboard
(&self, data: &T)
src/formats.rs:114
↓ 7 callers
Function
get_clipboard_data
Retrieves raw pointer to clipboard data. Wrapper around ```GetClipboardData```. Pre-conditions: [open()](fn.open.html) has been called.
src/raw.rs:226
↓ 7 callers
Method
set_len
(&mut self, len: usize)
src/utils.rs:191
↓ 6 callers
Method
as_ref
(&self)
src/html.rs:35
↓ 5 callers
Function
format_name
Returns format name based on it's code. Parameters: ```format``` - clipboard format code. ```out``` - temporary buffer to hold text. Buffer can be c
src/raw.rs:1045
↓ 5 callers
Method
try_recv
Attempts to get any clipboard update event Returns `Ok(true)` if event received, otherwise return `Ok(false)` indicating no clipboard event present
src/monitor.rs:146
↓ 4 callers
Method
read_clipboard
(&self, out: &mut alloc::vec::Vec<u8>)
src/formats.rs:121
↓ 4 callers
Function
register_format
Registers a new clipboard format with specified name. Returns: Newly registered format identifier, if successful. Note: Custom format identifier i
src/raw.rs:1135
↓ 4 callers
Method
release
(self)
src/utils.rs:103
↓ 4 callers
Function
unlikely_empty_size_result
()
src/utils.rs:14
↓ 3 callers
Function
invalid_data
()
src/raw.rs:38
↓ 3 callers
Method
iter
(&self)
src/monitor.rs:107
↓ 3 callers
Method
recv
Waits for new clipboard message, blocking until then. Returns `Ok(true)` if event received. If `Shutdown` request detected, then return `Ok(false)`
src/monitor.rs:128
↓ 3 callers
Function
register_raw_format
Registers a new clipboard format with specified name as C wide string (meaning it must have null char at the end). Returns: Newly registered format
src/raw.rs:1119
↓ 3 callers
Function
set_clipboard_string
(data: &str)
src/lib.rs:250
↓ 2 callers
Method
as_slice
(&self)
src/utils.rs:175
↓ 2 callers
Method
code
Gets raw format code
src/formats.rs:250
↓ 2 callers
Function
get_html
Retrieves HTML using format code created by `register_raw_format` or `register_format` with argument `HTML Format`
src/raw.rs:322
↓ 2 callers
Method
next
(&mut self)
src/monitor.rs:172
↓ 2 callers
Method
next
Returns next format on clipboard. In case of failure (e.g. clipboard is closed) returns `None`.
src/raw.rs:961
↓ 2 callers
Function
open_for
Opens clipboard associating it with specified window handle. Unless [empty](fn.empty.html) is called, `owner` would be `None`. Wrapper around ```Ope
src/raw.rs:106
↓ 2 callers
Function
set
Set data onto clipboard.
src/lib.rs:225
↓ 2 callers
Function
set_bitmap
Sets bitmap (header + RGB) onto clipboard, from raw bytes. Returns `ERROR_INCORRECT_SIZE` if size of data is not valid
src/raw.rs:787
↓ 2 callers
Function
set_bitmap_inner
(data: &[u8], clear: EmptyFn)
src/raw.rs:805
↓ 2 callers
Function
set_file_list_inner
(paths: &[impl AsRef<str>], empty: EmptyFn)
src/raw.rs:864
↓ 2 callers
Function
set_html_inner
(format: u32, html: &str, empty: EmptyFn)
src/raw.rs:401
↓ 2 callers
Function
set_inner
(format: u32, data: &[u8], clear: EmptyFn)
src/raw.rs:486
↓ 2 callers
Function
set_string_inner
(data: &str, clear: EmptyFn)
src/raw.rs:556
↓ 2 callers
Method
shutdown_channel
Creates shutdown channel.
src/monitor.rs:117
↓ 2 callers
Function
unlikely_last_error
()
src/utils.rs:20
↓ 1 callers
Function
close
Closes clipboard. Wrapper around ```CloseClipboard```. Pre-conditions: [open()](fn.open.html) has been called.
src/raw.rs:121
↓ 1 callers
Function
count_formats
Retrieves number of currently available formats on clipboard. Returns `None` if `CountClipboardFormats` failed.
src/raw.rs:262
↓ 1 callers
Function
empty
Empties clipboard. Wrapper around ```EmptyClipboard```. Pre-conditions: [open()](fn.open.html) has been called.
src/raw.rs:142
↓ 1 callers
Function
format_name_big
Returns format name based on it's code (allocating variant suitable for big names) Parameters: ```format``` clipboard format code. Return result:
src/raw.rs:1081
↓ 1 callers
Function
get
Retrieve data from clipboard.
src/lib.rs:209
↓ 1 callers
Function
get_bitmap
Reads bitmap image, appending image to the `out` vector and returning number of bytes read on success. Output will contain header following by RGB
src/raw.rs:682
↓ 1 callers
Function
get_clipboard
Shortcut to retrieve data from clipboard. It opens clipboard and gets output, if possible.
src/lib.rs:218
↓ 1 callers
Function
get_file_list
Retrieves file list from clipboard, appending each element to the provided storage. Returns number of appended file names.
src/raw.rs:646
↓ 1 callers
Function
get_file_list_path
Retrieves file list from clipboard, appending each element to the provided storage. Returns number of appended file names.
src/raw.rs:606
↓ 1 callers
Function
get_string
Copies raw bytes from clipboard with specified `format`, appending to `out` buffer. Returns number of copied bytes on success, otherwise 0.
src/raw.rs:526
↓ 1 callers
Function
get_vec
Copies raw bytes from clipboard with specified `format`, appending to `out` buffer. Returns number of copied bytes on success, otherwise 0.
src/raw.rs:301
↓ 1 callers
Function
open
Opens clipboard. Wrapper around ```OpenClipboard```. Pre-conditions: Clipboard is not opened yet. Post-conditions (if successful): Clipboard can
src/raw.rs:86
↓ 1 callers
Method
push_data
(&mut self, text: &[u8])
src/utils.rs:133
↓ 1 callers
Method
push_str
(&mut self, input: &str)
src/utils.rs:170
↓ 1 callers
Method
remaining
(&self)
src/utils.rs:128
↓ 1 callers
Function
set_clipboard
Shortcut to set data onto clipboard. It opens clipboard and attempts to set data.
src/lib.rs:233
↓ 1 callers
Function
set_file_list
Set list of file paths to clipboard.
src/raw.rs:853
↓ 1 callers
Function
set_html
Sets HTML using format code created by `register_raw_format` or `register_format` with argument `HTML Format`
src/raw.rs:397
↓ 1 callers
Function
set_string
Copies unicode string onto clipboard, performing necessary conversions, returning true on success.
src/raw.rs:587
↓ 1 callers
Method
size
(&self)
src/utils.rs:98
↓ 1 callers
Function
which_format_avail
Returns the first available format in the specified list. Returns `None` if no format is available or clipboard is empty
src/raw.rs:246
Method
as_str
(&self)
src/utils.rs:182
Function
clipboard_should_work
()
tests/test_clip.rs:165
Function
custom_format_big
()
tests/formats.rs:16
Function
custom_format_default_up_to_buf_capacity
()
tests/formats.rs:57
Function
custom_format_overflow
()
tests/formats.rs:32
Function
custom_format_smol
()
tests/formats.rs:4
Function
custom_format_trunc_default
()
tests/formats.rs:49
Function
custom_format_with_wide_chars
()
tests/formats.rs:65
Method
drop
(&mut self)
src/utils.rs:54
Method
drop
(&mut self)
src/lib.rs:165
Method
drop
(&mut self)
src/monitor.rs:33
Method
drop
(&mut self)
src/raw.rs:65
Function
free_dc
(data: HDC, _: usize)
src/raw.rs:43
Function
free_global_mem
(data: *mut c_void, _: usize)
src/utils.rs:44
Function
free_rust_mem
(data: *mut c_void, size: usize)
src/utils.rs:29
Method
from
(this: &'a mut [u8])
src/utils.rs:199
Method
from
Constructs enumerator that starts from format.
src/raw.rs:944
Method
from
(value: &RawData)
src/formats.rs:128
Method
from_borrowed
(ptr: ptr::NonNull<c_void>)
src/utils.rs:88
Function
get
Copies raw bytes from clipboard with specified `format` Returns number of copied bytes on success, otherwise 0. It is safe to pass uninit memory
src/raw.rs:279
Function
get_clipboard_string
()
src/lib.rs:242
Method
is_char_boundary
(text: &[u8], idx: usize)
src/utils.rs:137
Function
is_format_avail
Determines whenever provided clipboard format is available on clipboard or not.
src/raw.rs:238
Method
new
Attempts to open clipboard, returning clipboard instance on success.
src/lib.rs:130
Method
new
Subscribes window to clipboard changes.
src/monitor.rs:48
Method
new
()
src/html.rs:18
Method
new
()
src/raw.rs:56
Method
new
Creates new instance, if possible
src/formats.rs:240
Method
new_attempts
Attempts to open clipboard, giving it `num` retries in case of failure.
src/lib.rs:142
Method
new_attempts_for
Attempts to open clipboard, giving it `num` retries in case of failure.
src/lib.rs:148
Method
new_for
Attempts to open clipboard, associating it with specified `owner` and returning clipboard instance on success.
src/lib.rs:136
Method
new_global_mem
(size: usize)
src/utils.rs:76
Method
new_rust_mem
(size: usize)
src/utils.rs:63
Function
noop
(_: *mut c_void, _: usize)
src/utils.rs:25
Function
noop
()
src/options.rs:19
Method
reset
Resets enumerator to list all available formats.
src/raw.rs:949
Function
seq_num
Retrieves clipboard sequence number. Wrapper around ```GetClipboardSequenceNumber```. Returns: ```Some``` Contains return value of ```GetClipboardS
src/raw.rs:158
Function
set
Copies raw bytes onto clipboard with specified `format`, returning whether it was successful. This function empties the clipboard before setting the
src/raw.rs:512
Function
set_bitamp
(data: &[u8])
src/raw.rs:780
Function
set_bitmap_with
Sets bitmap (header + RGB) onto clipboard, from raw bytes. Returns `ERROR_INCORRECT_SIZE` if size of data is not valid Allows to customize clipboard
src/raw.rs:801
Function
set_file_list_with
Set list of file paths to clipboard.
src/raw.rs:860
Function
set_html_with
Sets HTML using format code created by `register_raw_format` or `register_format` with argument `HTML Format` Allows to customize clipboard setting b
src/raw.rs:392
Function
set_string_with
Copies unicode string onto clipboard, performing necessary conversions, returning true on success. Allows to customize clipboard setting behavior -
src/raw.rs:598
Function
set_without_clear
Copies raw bytes onto the clipboard with the specified `format`, returning whether it was successful. This function does not empty the clipboard befo
src/raw.rs:519
next →
1–100 of 118, ranked by callers