Tiddlytools calendar slight inonsistency

I’m not sure where the best place is to post questions about Tiddlytools is? The github site I found looked barren.

I was hoping to assign colours to events so that the kind of event could be easily distinguished. The calendar itself does this correctly, but the drop down list appears to show only the colour of the first item in the group.

Here’s what it shows. Note that the event items show the same colour in the drop-down, but different colours in the listing:

image

And just to show that they have indeed been assigned different colours:

image

I believe this is true for the other major groups as well (e.g. logs) but probably isn’t as important since they’re more likely to be all the same colour.

Thanks!

I’m not sure where the best place is to post questions about Tiddlytools is?

This is the best place to post TiddlyTools questions and bug reports so others who may have similar questions can participate in the discussion and also know when a bug has been found… and if/when a fix is available.

For example, you found a real bug (gasp!) in the TiddlyTools Calendar date drop-down color handling.

I believe this is true for the other major groups as well (e.g. logs) but probably isn’t as important since they’re more likely to be all the same colour.

Only the events group can have different colors assigned to individual “event lists” and “timelines”. All the other groups (timers, alarms, journals, logs, created tiddlers, and modified tiddlers) use a single color assignment for each group, regardless of how many individual items are listed. Also note that “logs” is a special group that will only ever have a single item (“show change log”) for any given day on which log entries were made.

The good news is that, thanks to the clear description and snapshots in your bug report, I was able to quickly find and FIX the drop-down event color handling.

Get the latest TiddlyTools Calendar here: TiddlyTools/Time/Calendar.

enjoy,
-e

6 Likes

Eric, for concurency I dropped the update on my site here https://tonyssitting.tiddlyhost.com/ and lost much of the colors, is there a way around this?

After searching my $:/ChangeLog for “eventcolor”, I note this entry:

25.08.26.085208 TiddlyTools/Time/Calendar - showcolorbar(),showday_color(): use "color" field instead of "eventcolor" field

This change was made for compatibility with other plugins that set/use a tiddler’s “color” field. This change applies when displaying colors in the Calendar and also when creating or copying “eventlist” or “timeline” tiddlers. However, this change also broke backward-compatibility with existing TiddlyTools Calendar eventlist and timeline tiddlers that were still using the old “eventcolor” field.

To address this, I’ve just updated TiddlyTools Calendar, as noted in the $:/ChangeLog:

25.09.26.004938 TiddlyTools/Time/Calendar - controls_events(): added fallback handling for old "eventcolor" field
25.09.25.235304 TiddlyTools/Time/Calendar - showcolorbar(),showday_color(): added fallback handling for old "eventcolor" field

This will permit your existing eventlist and timeline tiddlers to be displayed with their assigned colors.

Note that, any new eventlist or timeline tiddlers you may create using the Calendar interface will use the color field.

To address this in your “House Sitting Calendar” color key (the list that you are showing below the Calendar), you might want to change your wikiscript code from this:

<$list filter="[all[]has[eventcolor]sortby[eventcolor]]">
<$link/> {{!!eventcolor}}<br>
</$list>

to this:

<$list filter="[tag[events]] [tag[timeline]] :sort[{!!color}!match[]else{!!eventcolor}]">
<$link/> {{!!color}}{{!!eventcolor}}<br>
</$list>

Note: your existing wikiscript filter has an error. You used sortby[eventcolor] which expects the eventcolor field to contain a list of colors in the order you want them sorted. Instead, you should have used sort[eventcolor] which simply sorts your list of events by the single color values contained in each of their eventcolor fields. My suggested wikiscript not only handles color vs eventcolor, but also addresses this sorting error).

enjoy,
-e

1 Like