TableHighlight problems

3 views
Skip to first unread message

Mike

unread,
Aug 9, 2009, 12:22:17 AM8/9/09
to TiddlyWikiDev
Original Post:
http://groups.google.com/group/TiddlyWiki/browse_thread/thread/f260e2a97caf00a8/6eb79cec74b200e8?lnk=gst&q=highlight#6eb79cec74b200e8

I have created a minimal test site - if anyone has the time to probe
into what I am doing wrong / missing.
http://www.strm.us/TidlyWiki/Examples_TWGG/highlightscriptexample.html
In the tiddler About --> Known Issues:
1. When multiple tables exist inside one tiddler, sometimes one or
more table will fill entirely instead of every evenRow, upon highlight
this will correct until next render. See TestTable1 or TestTable2 for
examples.
1. Possible CSS / JQuery conflict with the handling of
evenRow
2. When transcluding via the tabs macro, only the first table is
rendered with the script, a refresh has to be invoked to use the
script on the next table / tab. See TestTabs1 for an example.
1. normal transclusion works fine i.e. <<tiddler TestTable1>>
2. might be a symptom of transcluding the script via the
ViewTemplate

I appreciate any ideas / suggestions / feedback,

Thanks,
Mike

FND

unread,
Aug 10, 2009, 1:18:36 PM8/10/09
to Tiddly...@googlegroups.com
> 1. When multiple tables exist inside one tiddler, sometimes one or
> more table will fill entirely instead of every evenRow
> [...]

> 2. When transcluding via the tabs macro, only the first table is
> rendered with the script

I'm afraid I can't reproduce either of those (Firefox 3.5 on Ubuntu).


-- F.

LostCreation

unread,
Aug 17, 2009, 1:39:26 PM8/17/09
to TiddlyWikiDev
Mike, I was able to reproduce all the issues you were having, both on
2.5 and after upgrading your TW to 2.5.2.

> 1. When multiple tables exist inside one tiddler, sometimes one or
> more table will fill entirely instead of every evenRow, upon highlight
> this will correct until next render. See TestTable1 or TestTable2 for
> examples.
> 1. Possible CSS / JQuery conflict with the handling of
> evenRow

It appears that the plugin removes all style class declarations from
the table-row when you hover and replaces them with the highlight and
hoverRow classes. It then removes the highlight and hoverRow classes,
and adds back the even/odd style to the TR when you blur...
unfortunately it uses a slightly different algorithm for detecting
even/odd than the TW table wikifier does, and can come up with
different results when there are multiple tables.

This issue itself is pretty easy to fix if all you do is add the
highligher class (and/or the hoverRow) and then remove it, but you
need to tweak the stylesheet to make highlighter's background rule "!
important" so that it will override all non-"! important" rules. It
has nothing to do with jQuery conflicts, and was most likely always an
issue -- just unnoticed until now.

> 2. When transcluding via the tabs macro, only the first table is
> rendered with the script, a refresh has to be invoked to use the
> script on the next table / tab. See TestTabs1 for an example.
> 1. normal transclusion works fine i.e. <<tiddler TestTable1>>
> 2. might be a symptom of transcluding the script via the
> ViewTemplate

Unless I'm mistaken, the sortable plugin does its work when
refreshTiddler is called. Unfortunately, refreshTiddler isn't called
when a tab's content's are wikified. A fix would probably require
overriding the tabs macro as well. Calling refeshTiddler after
changing tabs using firebug doesn't seem to do it, although calling
refreshAll() does. I haven't spent a whole lot of time looking at
Saq's plugin/refreshTiddler, so I may simply be calling things wrong.

Mike

unread,
Aug 22, 2009, 3:48:24 PM8/22/09
to TiddlyWikiDev
Thank You FND & LostCreation,

I had a similar thought process on the css styling, and I have updated
the test case.
I have only tried this on a windows based platform with FF 3.5
I am slightly perplexed that it is working fine on Ubuntu, I will try
to broaden my experiment onto IE, and possibly fire up my Ubuntu VM
and see if I have the same results.

As for the tabs macro - that may be beyond me at this point, but I
will keep digging

I appreciate the feedback, as always TW is a never ending learning
experience,

Mike
Reply all
Reply to author
Forward
0 new messages