Some coding fun: A Word Occurrence Highlighter

85 views
Skip to first unread message

Charlie Veniot

unread,
Aug 29, 2021, 12:39:42 AM8/29/21
to TiddlyWiki
Drag the attached to https://tiddlywiki.com/ to import the single tiddler.

This bit of coding fun inspired by the Highlighting duplicates in lists discussion thread.

My kind of "BrainAge" game.
WordOccurenceHighlighter.json

Télumire

unread,
Aug 29, 2021, 4:15:57 AM8/29/21
to TiddlyWiki
Hi, thanks for sharing this, I struggle a bit with the filter operator so this help a lot !
As a side note, the <mark> element would be a more semantic solution :)

Charlie Veniot

unread,
Aug 29, 2021, 12:44:35 PM8/29/21
to TiddlyWiki
Cognitively, "mark" throws me off because every time I see that I think of "Mark", a great childhood buddy.  Then, whatever I'm trying to do at the moment hits a major pause as I'm distracted by childhood memories.  Everything, and I mean everything, is just one degree of separation from everything else ...

Giggles aside:

I didn't focus much on making things particularly very readable or organized or easy to understand (just a quick and dirty coding exercise).  If anything is clear as mud, please let me know, and I can clean things up and explain things a smidgen.  

Mohammad Rahmani

unread,
Aug 29, 2021, 1:44:57 PM8/29/21
to tiddl...@googlegroups.com
Very nice!
I would suggest adding a little documentation!
I also like to add this to the standard TW search!



Best wishes
Mohammad


--
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 tiddlywiki+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/8a18f276-3136-42f8-b4b6-5c13f532fe0cn%40googlegroups.com.

arun babu

unread,
Jun 26, 2022, 3:04:02 PMJun 26
to TiddlyWiki
Hi Charlie,

Can this be modified to be used be in the backlinks section. I would like the linked words to be highlighted in all the backlink tiddlers.

Arun.

Charlie Veniot

unread,
Jun 26, 2022, 3:38:36 PMJun 26
to TiddlyWiki
G'day,

I can't see any reason why not.  Looks easy enough to setup.

Charlie Veniot

unread,
Jun 26, 2022, 3:39:36 PMJun 26
to TiddlyWiki
I suggest you consider creating a custom tab in info instead of modifying the existing one.  Less risky when upgrading TiddlyWiki.

arun babu

unread,
Jun 26, 2022, 3:53:45 PMJun 26
to tiddl...@googlegroups.com
\define lingo-base() $:/language/TiddlerInfo/
<$list filter="[all[current]backlinks[]sort[title]]" emptyMessage=<<lingo References/Empty>> template="$:/core/ui/ListItemTemplate">
</$list>

This is the reference tiddler in the info section.
How should i modify it?

You received this message because you are subscribed to a topic in the Google Groups "TiddlyWiki" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/tiddlywiki/XWwQnUgHd-g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to tiddlywiki+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tiddlywiki/46a27fde-2545-44b5-87b8-d7a72eb5e99dn%40googlegroups.com.

Charlie Veniot

unread,
Jun 26, 2022, 9:22:16 PMJun 26
to TiddlyWiki
That is way too long to explain.

Here's a start for you to work with (attached.)  Download and drag into TiddlyWiki.com 
Charlie's Backlinks Alternative.json

arun babu

unread,
Jun 28, 2022, 2:14:59 PMJun 28
to TiddlyWiki
I was too busy at work yesterday. So I didn't get time to test it. Now only got time to check it. Will come back here after testing for sometime.

arun babu

unread,
Jul 16, 2022, 5:36:55 PMJul 16
to tiddl...@googlegroups.com
Hi Charlie,
I couldn't make much progress with this. I have just added this into my demo wiki. Click on the Wordhighlight link in the topbar.
How to make highlighting work without the word selector.
Also I need to highlight the words within the tiddler body which match the backlinks.

For example, in the tiddler named "Peter Kranz", there is one backlink seen.

image.png


I need to see the text of the "SIH" tiddler also in addition to its links and want to highlight the word "Peter Kranz" within the "SIH" tiddler.

image.png
Is it possible?

Charlie Veniot

unread,
Jul 16, 2022, 6:36:12 PMJul 16
to TiddlyWiki
Your Wiki is much too big, much too different, for me to help.  I am not familiar enough with it, and I can't find things where I expect them to be.  It is overwhelming to pinpoint a problem with one thing when facing the whole guacamole.

Very pretty wiki, but it is too tall a task for me to disect it.  Maybe somebody else with the time and the energy can dig into it.

Might I suggest that before you introduce functionality into the big/wildly different wiki, that you try new intended features in a small and dedicated TiddlyWiki instance for that one feature.

So that targettetted unit/functional testing can be done for that feature in isolation, or at most with those artifacts (design elements) directly linked to the feature (i.e. things directly linked to the specific feature).

When the feature is working in the small-scale vanilla TiddlyWiki, then integrate that new feature into the big one, and then do the big integration testing.  If what was working in the small TiddlyWiki doesn't work in the big TiddlyWiki, then that helps narrow down the problem.

arun babu

unread,
Jul 16, 2022, 6:44:31 PMJul 16
to tiddl...@googlegroups.com
Does the wordhighlight link in the topbar doesn't show the relevant tiddlers only. If not I will upload a small wiki later.

This is the wiki I use for all my testings and experiments. So it include most of my tweaks and plug ins. Thats why it may seem like a large wiki. Actual content in this wiki is very less only.

Charlie Veniot

unread,
Jul 16, 2022, 7:03:41 PMJul 16
to TiddlyWiki
Yeah, it isn't about the amount of content.

It is the amount of cognitive overload.  Like being used to the dashboard of a car and suddenly sitting in front of the controls of a 747.

I find myself playing "Where's Waldo", and I can't stand that game.

I'm thinking it might be easier for some of the experts and leaders, or anybody who can quickly adapt to a different user interface, over in Talk TiddlyWiki to quickly troubleshoot what's going on..

arun babu

unread,
Jul 16, 2022, 7:14:09 PMJul 16
to tiddl...@googlegroups.com
https://wordhighlight.tiddlyhost.com/

This is a basic wiki with only the three relevant tiddlers.

Charlie Veniot

unread,
Jul 16, 2022, 7:34:15 PMJul 16
to TiddlyWiki
Your TiddlyWiki is excellent and beautiful for the minds that function that way, which may very well by 99.99% of folk.

I'm likely that 0.01%, that one single person who gets flustered by it, and I don't do fluster-me things.

But if there's a chance that I still can't help you with a vanilla TiddlyWiki, it might still be useful for somebody else to figure out the problem.
Reply all
Reply to author
Forward
0 new messages