Raised after a discussion with Michael Daum.
I had enabled Natskin Plugin to see how Natskin looked and left the plugin active.
I noticed that tabled viewed in Pattern skin did not display correctly.
When you first load a page the table is correct. When you refresh the display turns all white. Header and every 2nd line is no longer having any background colour.
You may ask why would you enable Natskin plugin and view with Pattern.
But it is a feature that users can choose their skin in their user topic in main. And then you can have one bloke using Pattern and another using Nat.
I will not use Natskin myself - but I promissed Michael to raise the bug.
And it may also be a problem others run into and instead of blaming Table plugin it is good to know what is causing the problem.
I found the connection by doing a binary disable/enable of the plugins because I saw the problem was not present on a couple of other Dakars with a difference plugin pack.
KJL
The forensic analysis of the
NatSkin's relationship to the
TablePlugin is outlined not quite accurate.
Tables
do display correctly. Only the colors are those that are tricked into the session preferences by
the
NatSkinPlugin according to its current skin state. The
NatSkinPlugin will add
a look for twikiTables that matches the current NatSkinStyle: see
TWiki:Plugins.NatSkinPlugin#Style_support_for_the_TablePlugi
for a complete list of colors that are
used with the appropriate styles.
Sneaking in TABLEATTRIBUTES by setting them on the session level
is a
bad hack. But as
complete css control of twikiTables
was not accepted in July this year I had to do
something to meet my goals fast
as I got tired of all the talk-talk.
There are two possible solutions to ease the pain using
NatSkin and
PatternSkin on the same site not disturbing
each other:
- hack the hack: only add session preferences for the TablePlugin if the current skin is actually the NatSkin; if the user switches back to the PatternSkin the session preferences have to be cleared automatically
- fix the TablePlugin: there's been a patch
to the TablePlugin that added the css classes needed to make the TABLEATTRIBUTES hack obsolete. This needs to be redone for the current svn version as the TablePlugin moved on w/o incorporating this patch.
There are more css related proposals and patches by RobertWohlfarth (see
TWiki:Plugins.TablePluginDev
)
that sound interesting but are not relevant for skinning. There's even a completely new table plugin
by BramVanOosterhout (see
TWiki:Plugins.BoundedTablePlugin
) that adds a new table syntax to TWiki
based on MediaWiki's syntax with css control out of the box.
(1) is the fast solution that only needs changes to the
NatSkinPlugin. This will fix this bug. But (2) needs
a new patch and then it being accepted by the current maintainer(s) of the
TablePlugin,
TWiki:Main/JohnTalintyre
and
TWiki:Main/PeterThoeny
.
Anyway, the current
TablePlugin on TWiki.org is not in sync with its svn counterpart. I am not sure if the
svn version runs on cairo and the TWiki.org version runs on dakar. So there's a more fundamental problem
also, which is not restricted to the
TablePlugin alone.
MD.
Fixed in SVN 7780.
MD