PatternSkin has chosen to generate the buttons at the bottom of the topic very differently from the classic skin. Most templates that existed before
PatternSkin stopped working.
I realize that this can be fixed by providing pattern skin specific templates for all these applications. Nevertheless, I think it is most inappropriate for this behavior. The basic operation of a template designed for
ClassicSkin should not be negatively affected by the use of
PatternSkin. That skin should have used the same macro names to generate its UI elements, just prettier. It is against the twiki architecture that a skin that works in
ClassicSkin (invoked as xxx.tmpl) is not operational in
PatternSkin (invoked as xxx.pattern.tmpl), in addition to being most inappropriate.
Examining the code it appears that most of the changes here were gratuitous. One could have preserved the functioning of a
ClassicSkin template by just choosing more consistent macros.
Test case
Try, e.g.,
SectionalEditPlugin.
Environment
--
ThomasWeigert - 23 Jan 2005
Follow up
Can you be more specific? What is the bug: "breaks most templates" or "buttons at the bottom do not longer appear"?
If I am going to fix bugs, what do I do with the statement "most of the changes here were gratuitous"? Please add some examples.
--
ArthurClemens - 23 Jan 2005
Sorry,
Arthur for being too vague. Let me try again:
- Many TWikiApplications define templates of their own.
- For example, take a look at SectionalEditPlugin which defines two templates
previewsection.tmpl and editsection.tmpl.
- Typically, these templates are based on the ClassicSkin templates. This is particularly true for TWikiApplications generated before the Cairo release.
- All topics relying on such templates are rendered without the topic actions for the following reason:
- The ClassicSkin templates typically call the macro
standardfooter which calls topicaction (the macro that inserts the links in the bottom bar).
-
standardfooter is inherited from twiki.tmpl
- However,
twiki.pattern.tmpl does not define the same standardfooter (this is just a dummy there).
- Thus, when using PatternSkin and encountering such TWikiApplication, the topic is rendered incomplete (as
twiki.pattern.tmpl is called). These TWikiApplications work under ClassicSkin.
Hope this makes it clearer. My suggestion is that the two skins that are shipped with TWiki must use exactly the same key macros so that users who want to define templates can inherit the same basic behavior in either skin.
PatternSkin should merely add additional layout information due to the styles used.
Note that the macro arrangement in
PatternSkin may well be better, but then
ClassicSkin should be brought in synch. Note though that this will again break existing application, but is easier to fix.
The current situation, however, is untenable.
--
ThomasWeigert - 26 Jan 2005
I have since updated
SectionalEditPlugin and provided pattern skin compatible templates. This does not mean that this remove the need to tackle this issue....
--
ThomasWeigert - Apr 2005
Fix record
Consistent templates for classic skin
I have started working on this. I have made the templates in
ClassicSkin more consistent. This is checked into
SVN as 4199.
The general layout of templates in
ClassicSkin is as shown below:
twiki.tmpl
-
main
content
simpleheader
logo
TWIKI>WEB>parent>TOPIC
titleaction
headerhelp
webaction
heading
message
topicinfo
<table> topicaction </table>
<table>
footernote (e.g., r6 - 2005-06-05 - 06:19:11 -
WillNorris parent)
copyright
</table>
standardfooter
view.tmpl
htmldoctype
bodystart
main
<form> view
</form>
content
%TEXT%
form
attachments
topicinfo
<table> topicaction </table>
<table>
footernote (e.g., r6 - 2005-06-05 - 06:19:11 -
WillNorris parent)
copyright
</table>
standardfooter
bodyend
edit.tmpl
htmldoctype
head
script (include focus)
bodystart (include initform)
main
content
<form>
simpleheader
logo
TWIKI>WEB>parent>TOPIC
titleaction
headerhelp
webaction
%TEXT%
hidden values
signature block
%FORMFIELDS%
topicinfo
<table> topicaction </table>
<table>
footernote (e.g., %DONOTNOTIFYCHECKBOX% %FORCENEWREVSIOIN%,
WikiSyntaxSummry)
copyright
</table>
</form>
standardfooter
bodyend
search.tmpl (inherits view)
main
<form> view
</form>
content
%SPLIT%
%SEARCHSTRING%
searchbody
%SPLIT%
repeatedsearchblock
<table>Topics in web:....</table>
%REPEAT%
<table>
%TOPICNAME% %REVISION% %AUTHOR%
%TEXTHEAD%
</table>
%REPEAT%
%SPLIT%
<table> topicaction </table>
topicinfo
<table>
footernote (e.g., r6 - 2005-06-05 - 06:19:11 -
WillNorris parent)
copyright
</table>
standardfooter
oops
htmldoctype
bodystart
main
content
simpleheader
logo
TWIKI>WEB>parent>TOPIC
titleaction
headerhelp
webaction
heading
message
topicinfo
<table> topicaction </table>
<table>
footernote (e.g., r6 - 2005-06-05 - 06:19:11 -
WillNorris parent)
copyright
</table>
standardfooter
bodyend