Skip to content

Copy text to clipboard with button push #1321

Answered by SymmetricChaos
benruijl asked this question in Q&A
Discussion options

You must be logged in to vote

I believe what you're looking for is

if ui.button("Button").clicked() {
    ui.output().copied_text = String::from(text);
};

Replies: 1 comment 5 replies

Comment options

You must be logged in to vote
5 replies
@benruijl
Comment options

@miketwenty1
Comment options

@AngelOnFira
Comment options

@miketwenty1
Comment options

@Its-Just-Nans
Comment options

Answer selected by benruijl
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants