Hi.
after reading my text I am surprised to get any hint at all. Thanks Tones.
The problem description now in a proper way:
Normally you create a tiddler, tag it with "$:/tags/MenuBar", put in the caption the display text and in target the title of the targeted tiddler. And after clicking, the target-tiddler is opened in the stream.
My goal was to open the tiddler in a new window like with the "open in new window"-button.
Unfortunately it is not well descripted in the plugin-description, but Tones hinted me onto the right path. Maybe that can be included into the readme of the plugin - of cource better phrased.
Creating customized menu-entry:
- create tiddler
- tag it with $:/tags/MenuBar
- prepare the tiddler as usual as a menu-bar-item
- DON'T set the target field
- instead pace in the text-field a $button-widget with wished action.
- in the $button-widget place the Menu-Item-"text" - it can be a picture or a text - what ever suites
- set the field
custom-menu-content with {{!!text}}
My tiddler looks like this in JSON:
[
{
"title":"openTargetNewWindow",
"bag":"default",
"type":"text/vnd.tiddlywiki",
"tags":"$:/tags/MenuBar",
"caption":"menu text",
"custom-menu-content":"{{!!text}}",
"text":"<$button message=\"tm-open-window\" param=\"targettiddler\">menu text</$button>"
}
]
Maybe it is better to set custom-menu-content with a transclusion of the tiddler itself ({{openTargetNewWindow}}) like done in $:/plugins/tiddlywiki/menubar/items/hamburger instead of using {{!!text}}. but it works – at the moment.
Hope, this helps someone else.
Cheers
ToraxMalu