Let's say your code block is in a tiddler "mycode"

Paste this into a tiddler, call it  and tag it with $:/tags/ViewTemplate

<$list filter="[all[current]prefix[mycode]]">
<$button>
<$macrocall $name="copy-to-clipboard" src={{mycode}}/>
</$button>
</$list>

Save, and clickon the tag $:/tags/ViewTemplate. Drag and drop "mytemplate" 
so it's just in front of the body tag. Now a button will appear on your 
mycode tiddler that will let you copy the code. Always make backups before 
trying changes like this.

On Tuesday, January 5, 2021 at 6:58:19 AM UTC-8 [email protected] 
wrote:

> How do I create that button on the top-right side of the code block so It 
> copies the entire code block to clipboard?
> It looks like I can edit the tiddlywiki.com website to make it look like 
> what I want to get. But when I actually do it on my own file (v5.1.23), it 
> doesn't work.
> Any idea?
>
> Il giorno martedì 4 agosto 2020 alle 11:39:29 UTC+2 PMario ha scritto:
>
>> Hi Rafael,
>>
>> Have a look at: 
>> https://tiddlywiki.com/#WidgetMessage%3A%20tm-copy-to-clipboard:%5B%5BWidgetMessage%3A%20tm-copy-to-clipboard%5D%5D%20%5B%5Bcopy-to-clipboard%20Macro%20(Examples)%5D%5D%20%5B%5Bcopy-to-clipboard%20Macro%5D%5D
>>
>> -m
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"TiddlyWiki" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/b72a75ab-c889-460f-8f65-aea1afb2d810n%40googlegroups.com.

Reply via email to