I hacked at it a bit more. At this point, I can get a static timestamp (now 
too interesting, but proof of concept).

Here's my code:


<$set name="timestamp" value=<<now '0DDmmm0hh0mm0ss'>> >
<$set name="prefix" value="<<annotate 'Text' '">
<$set name="suffix" value=<<timestamp>> >
<$set name="suffix" value="' '20170401010101'>>">
<$action-sendmessage
    $message="tm-edit-text-operation"
    $param="wrap-selection"
    prefix=<<prefix>>
    suffix=<<suffix>>
/>


Put this in a toolbar tiddler ($:/core/ui/EditorToolbar/Annotate-Text) 
replaces selected text with this in the tiddler currently being edited:

<<annotation 'Text' 'selected text' '20170401010101'>>

I'd love to replace the static timestamp with $timestamp$,  generated by 
the set comand. Note I still need to close the timestamp with a single 
quote, and to close the suffix with ">>". I think it is only a matter of 
making $timestamp$ a parameter...

Thanks!

//steve.


On Saturday, April 1, 2017 at 2:47:20 PM UTC-4, Mat wrote:
>
> Haven't tested anything but I get bad vibes from the odd number of quotes 
> in that third $set.
>
> <:-)
>

-- 
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 post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/tiddlywiki.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/tiddlywiki/018b1382-19aa-4bc2-9586-b13044feb619%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to