#clipboard #error

clipboard2

clipboard2 is an improved version of clipboard-rs with better error handling and MIME type handling on Windows

2 releases

Uses old Rust 2015

0.1.1 Oct 27, 2018
0.1.0 Jul 3, 2018

#213 in #clipboard

Download history 102/week @ 2025-09-20 71/week @ 2025-09-27 54/week @ 2025-10-04 52/week @ 2025-10-11 111/week @ 2025-10-18 98/week @ 2025-10-25 80/week @ 2025-11-01 74/week @ 2025-11-08 90/week @ 2025-11-15 89/week @ 2025-11-22 96/week @ 2025-11-29 112/week @ 2025-12-06 121/week @ 2025-12-13 65/week @ 2025-12-20 50/week @ 2025-12-27 48/week @ 2026-01-03

299 downloads per month
Used in 5 crates (4 directly)

MIT license

20KB
480 lines

Improved cross-platform clipboard library

Fork of https://github.com/aweinstock314/rust-clipboard with better error handling


clipboard2

Build status Travis Build Status

Hard fork of https://github.com/aweinstock314/rust-clipboard

This library has better error handling than the original one, the code is mostly copied.

Usage

extern crate clipboard2;

use clipboard2::{Clipboard, SystemClipboard};

fn main() {
    let clipboard = SystemClipboard::new().unwrap();
    clipboard.set_string_contents(String::from("Hello")).unwrap();
    println!("{}", clipboard.get_string_contents().unwrap());
}

Dependencies

~0–340KB