Excise to field?

of current tid or another? is there an option? i see only excise to another whole tid

It is not an option but can be done. The current excise is to cut content and place it in a tiddler leaving a link or transclusion behind.

the current editor tool button is here $:/core/ui/EditorToolbar/excise with the logic in this tiddler $:/core/ui/EditorToolbar/excise-dropdown basicaly it uses the tm-edit-text-operation

<$action-sendmessage
	$message="tm-edit-text-operation"
	$param="excise"
	title={{$config-title$/new-title}}
	type={{$config-title$/type}}
	macro={{$config-title$/macro-title}}
	tagnew={{$config-title$/tagnew}}
/>

The trick

Clone and edit the current tiddlers into your own, learn something in the process and make it save to a field instead.

See How to create dynamic editor toolbar buttons and tm-edit-text-operation

You may need to use the excise to a temp tiddler and adds another action to set field to the content of that tiddler. Eg add a line below the above action such as;

<$action-setfield $tiddler=<<currentTiddler>> $field=fieldname $value={{$config-title$/new-title}}/>

But not tested.

thnx @TW_Tones for the refrence & code. I tried it and it seems to not work, but ill refer to the links you gave

Do give me a little more detail about what you want for example excise to fieldnam on current tiddler and I may be able to make it for you. Can i replace the existing value etc. …

wow @TW_Tones! i’ll play with the ref you gave me first for a few days though to see if i can get something to work. but i really appreciate your gesture! :grin:

1 Like

I found another way to do it by modifying the content of $:/core/modules/editor/operations/text/excise.js

You can replace

tags: event.paramObject.tagnew === "yes" ? [editTiddlerTitle] : []

by

filename: event.paramObject.tagnew === "yes" ? [editTiddlerTitle] : []

after saving you need to reload Tiddlywiki