Is there any way of creating a shortcut that makes my tiddlers show only their titles?

300 views
Skip to first unread message

Rafael Oliveira

unread,
Jul 30, 2020, 9:48:47 AM7/30/20
to TiddlyWiki
I'd like to create a shortcut that will toggle between hiding/showing the body of my open tiddlers... To illustrate better what I mean, let's say that I have three open tiddlers like the following:

Screenshot from 2020-07-30 10-37-09.png
















Let's say I press ctrl+shit+alt+t, I'd like to see these same three tiddlers like the following:

After pressing ctrl+shit+alt+t, it toggles back to its original view... Is it possible to do something like this easily on TiddlyWiki? Is there any plugin with this kind of functionality? Or can I tweak TiddlyWiki configurations to make it happen?

Mat

unread,
Jul 30, 2020, 9:56:57 AM7/30/20
to TiddlyWiki
Sidebar > Tools > Fold all tiddlers.

<:-)

Rafael Oliveira

unread,
Jul 30, 2020, 10:16:41 AM7/30/20
to TiddlyWiki
Great :)

Is there any way of making the folded option the default one? I've searched this option inside the ControlPanel but I didn't find anything related to folding tiddlers there...

TW Tones

unread,
Jul 30, 2020, 7:32:55 PM7/30/20
to TiddlyWiki
Rafael,

When you fold a tiddler a separate tiddler is created to indicate if its folded or not. 

If you use the Fold all Tiddlers in the Wiki toolbar (rather than on tiddlers) all visible tiddlers will be folded and you can unfold all, or unfold each on the tiddler toolbar.
See $:/core/ui/Buttons/fold-all it uses this action in abutton
<$action-sendmessage $message="tm-fold-all-tiddlers" $param=<<currentTiddler>> foldedStatePrefix="$:/state/folded/"/>

If as you create a tiddler you also create the folded state tiddler and set it to hide or show
<<folded-state>> returns the tiddler where the fold state is set

ControlPanel > Appearance > Toolbars > View Tool Bar > Fold Bar 
Is my preferred way to toggle the fold status

There is another related way to do this by setting a field on each tiddler
hide-bodyThe view template will hide bodies of tiddlers if set to: yes
However this leave no information this is in fact occurring so use judiciously, or you will think you have lost content..

I hope this leads you to a better understanding

Regards
Tony

Eric Shulman

unread,
Jul 30, 2020, 8:51:01 PM7/30/20
to TiddlyWiki
On Thursday, July 30, 2020 at 6:48:47 AM UTC-7, Rafael Oliveira wrote:
I'd like to create a shortcut that will toggle between hiding/showing the body of my open tiddlers... 
Let's say I press ctrl+shit+alt+t, I'd like to see these same three tiddlers ... folded...
After pressing ctrl+shit+alt+t, it toggles back to its original view... 

1) Create a tiddler named "$:/config/shortcuts/toggle-fold", with content:
ctrl-shift-alt-T
2) Create a tiddler named "$:/config/ShortcutInfo/toggle-fold", with content:
toggle fold (all tiddlers)
3) Create a tiddler named "$:/MyKeyboardShortcuts/toggle-fold", with content:
<$list filter="[enlist{$:/StoryList!!list}addprefix[$:/state/folded/]]">
   <$action-setfield text={{{ [
<currentTiddler>{!!text}match[hide]then[show]else[hide]] }}} />
</$list>
4) Add tag "$:/tags/KeyboardShortcut" to that tiddler
5) Add a field named "key", with a value of "((toggle-fold))"

That's it.  You should now be able to press "ctrl-shift-alt-T" to toggle the folded state of all tiddlers.

Notes:
* The $list gets the current contents of the $:/StoryList list field, and adds the prefix used by the TWCore for tracking the folded state of a tiddler
* The $action-setfield toggles the text of each of those state tiddlers between "hide" and "show"
* Your new shortcut key will be listed in the $:/ControlPanel, Keyboard Shortcuts tab.
* You can use this interface to change the key assignment (click on the arrow next to the "toggle-fold" item to see the key assignments)

enjoy,
-e

Rafael Oliveira

unread,
Jul 31, 2020, 1:06:17 AM7/31/20
to TiddlyWiki
Thanks again Eric, this shortcut is going to be very useful for me because most of the time I'm opening permaview links with multiple tiddlers in each link. :)

Rafael Oliveira

unread,
Jul 31, 2020, 1:15:00 AM7/31/20
to tiddl...@googlegroups.com
Thanks TW Tones, I liked the "fold tiddler" option on ControlPanel > Appearance > Toolbars > View Tool Bar ... However, is there any kind of tweak for showing the text only in some buttons and not in others? I mean something like the following:

Screenshot from 2020-07-31 02-09-13.png



Instead of this:

TW Tones

unread,
Jul 31, 2020, 4:14:46 AM7/31/20
to TiddlyWiki
Rafael,

I am sorry I do not understand what you are asking for here.

You show an icon, with formatted title and tag pills on the right!
  • Is this a member of a list, or are you altering the way 

    $:/core/ui/ViewTemplate/title works?

There is an option in 

Control Panel, Settings and at the bottom, Toolbar Buttons

Default toolbar button appearance:


Regards
TW Tones

Eric Shulman

unread,
Jul 31, 2020, 4:38:21 AM7/31/20
to TiddlyWiki
On Friday, July 31, 2020 at 1:14:46 AM UTC-7, TW Tones wrote:
I am sorry I do not understand what you are asking for here.
You show an icon, with formatted title and tag pills on the right!

Those aren't tag pills.  That is the tiddler's view toolbar, with the "Toolbar Button Style" set to "rounded"
 
There is an option in 
Control Panel, Settings and at the bottom, Toolbar Buttons

Default toolbar button appearance:


What he's asking is if there is a way to show both icon and text for *most* of the toolbar buttons,
but have one toolbar button omit the text (specifically, the "fold tiddler" button)

-e

Eric Shulman

unread,
Jul 31, 2020, 4:52:44 AM7/31/20
to TiddlyWiki
On Thursday, July 30, 2020 at 10:15:00 PM UTC-7, Rafael Oliveira wrote:
Thanks TW Tones, I liked the "fold tiddler" option on ControlPanel > Appearance > Toolbars > View Tool Bar ... However, is there any kind of tweak for showing the text only in some buttons and not in others? I mean something like the following:

Screenshot from 2020-07-31 02-09-13.png



Instead of this:


Normally, you can only choose to show or no show the text for *all* the tiddler's View Toolbar buttons
(using the $:/ControlPanel, Settings, "Toolbar Buttons"  checkboxes)

To omit the text for one specific button, you can tweak the shadow tiddler that defines that
button's text.  The fold/unfold button is defined here:
   $:/core/ui/Buttons/fold
and, if you examine that tiddler's content, you can see that the *text* of the button
is retrieved from these *two* tiddlers
   $:/language/Buttons/Fold/Caption
and
   $:/language/Buttons/Unfold/Caption

If you edit those two shadow tiddlers and clear out their contents, then the
fold/unfold button will no longer have any text to display, even if the option for
showing the Toolbar Button text is selected in the $:/ControlPanel.

-e

Rafael Oliveira

unread,
Jul 31, 2020, 5:28:53 PM7/31/20
to TiddlyWiki
Thanks again everyone,

I removed the text of the folding icon and also the info icon on my TW:


Is there also a tiddler where I can define the order of the icons on the bar? I've tried searching tiddlers around $:/language/Buttons but I didn't find anything that looked like a list with a predefined order of those icons...

Eric Shulman

unread,
Jul 31, 2020, 5:45:51 PM7/31/20
to TiddlyWiki
On Friday, July 31, 2020 at 2:28:53 PM UTC-7, Rafael Oliveira wrote:
Is there also a tiddler where I can define the order of the icons on the bar?

1) Create a tiddler (any name) containing:
<<tag $:/tags/ViewToolbar>>
2) When you view that tiddler, it will show a "tag pill" for $:/tags/ViewToolbar 
3) Click the tag pill to view the list of all tiddlers with that tag
4) Use drag-n-drop to change the order of the items listed
5) When you are done, you can delete the tiddler you created in step (1)

Note: as an alternative to steps (1), (2) and (5), you can view any
existing tiddler that is already tagged with $:/tags/ViewToolbar,
e.g., $:/core/ui/Buttons/fold
This will display the tag pill for you to use in steps (3) and (4)

-e

Rafael Oliveira

unread,
Aug 1, 2020, 12:45:29 AM8/1/20
to tiddl...@googlegroups.com
Thanks again Eric,

May I assume that it's also true for the icons on the right?

Screenshot from 2020-08-01 01-34-59.png











Are they all linked to a tag and if I discover its name I can modify their order directly on the tiddler? I've tried searching for keywords like "home" and "close all" to identify the name of their tiddler to see what's their linked tag but it didn't work...




Eric Shulman

unread,
Aug 1, 2020, 1:08:55 AM8/1/20
to TiddlyWiki
On Friday, July 31, 2020 at 9:45:29 PM UTC-7, Rafael Oliveira wrote:
Thanks again Eric,
May I assume that it's also true for the icons on the right?

Those icons are referred to as the "Page toolbar".
You can select *and re-order* the toolbar icons
directly from the $:/ControlPanel, Appearance, Toolbars tab.

Just view the tab for the desired toolbar and then use
drag-n-drop to reorder them.  In fact, this works for all
the different toolbars, including the ViewToolbar that we
discussed in the previous message!

-e

Rafael Oliveira

unread,
Aug 2, 2020, 3:20:21 PM8/2/20
to TiddlyWiki
Ah yeah, the ViewToolbar also works from there...

Thanks again
Reply all
Reply to author
Forward
0 new messages