From: PeterThoeny Date: Mon, 26 Jul 2004 00:25:19 +0000 (+0000) Subject: none X-Git-Url: https://git.openafs.org/?p=openafs-wiki.git;a=commitdiff_plain;h=9b36eb5f332f7827a007cfb27b8de8b7040b5436 none --- diff --git a/TWiki/TWikiSkinBrowser.mdwn b/TWiki/TWikiSkinBrowser.mdwn new file mode 100644 index 0000000..5a582fb --- /dev/null +++ b/TWiki/TWikiSkinBrowser.mdwn @@ -0,0 +1,19 @@ +# TWiki Skin Browser + +You can try out the [[TWikiSkins]] currently installed on this system: + + + + + + + +
Try Skin: Description Screenshot
+ +# TWiki Installation Error + +Incorrect format of searchformat template (missing sections? There should be 4 %SPLIT% tags) + +**_Note:_** [[TWikiSkins]] describes how to install and activate a skin + +-- TWiki:Main.PeterThoeny - 25 Jul 2004 diff --git a/TWiki/TWikiSkins.mdwn b/TWiki/TWikiSkins.mdwn index cf3d6d0..da95a70 100644 --- a/TWiki/TWikiSkins.mdwn +++ b/TWiki/TWikiSkins.mdwn @@ -8,7 +8,9 @@
  • Using Cascading Style Sheets
  • +
  • Attachment Tables
  • Packaging and Publishing Skins
  • +
  • Browsing Installed Skins
  • Activating Skins
  • @@ -143,7 +145,7 @@ Here is an example form that has a select box and the "Go" box for illustration ## Using Cascading Style Sheets -The regular templates files currently do not use style sheets. Many skin developers choose to use them, it helps in separating style from content. +Although work is underway at TWiki:Codev.CssClassNames, the regular templates files currently do not use style sheets. Many skin developers, however, choose to use them; it helps in separating style from content. Example: To use a style sheet for the broadcast message, add this to `view.myskin.tmpl`: @@ -159,10 +161,119 @@ Then add a div tag to the `%BROADCASTMESSAGE%` variable located after the `#Page
    %BROADCASTMESSAGE%
    +## Attachment Tables + +Controlling the look and feel of attachment tables is a little bit more complex than for the rest of a skin. By default the attachment table is a standard TWiki table, and the look is controlled in the same ay as other tables. In a very few cases you may want to change the _content_ of the table as well. + +The format of standard attachment tables is defined through the use of special _TWiki template macros_ which by default are defined in the `templates/twiki.tmpl` template using the `%TMPL:DEF` macro syntax described in [[TWikiTemplates]]. These macros are: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Macro Description
    ATTACH:files:header Standard title bar
    ATTACH:files:row Standard row
    ATTACH:files:footer Footer for all screens
    ATTACH:files:header:A Title bar for upload screens, with attributes column
    ATTACH:files:row:A Row for upload screen
    ATTACH:files:footer:A Footer for all screens
    + +The format of tables of file versions in the Upload screen are also formattable, using the macros: + + + + + + + + + + + + + + + + + + +
    Macro Description
    ATTACH:versions:header Header for versions table on upload screen
    ATTACH:versions:row Row format for versions table on upload screen
    ATTACH:versions:footer Footer for versions table on upload screen
    + +The `ATTACH:row` macros are expanded for each file in the attachment table, using the following special tags: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Tag Description
    %A_URL% URL that will recover the file
    %A_REV% Revision of this file e.g. "1.1"
    %A_ICON% A file icon suitable for representing the attachment content
    %A_FILE% The name of the file
    %A_SIZE% The size of the file
    %A_DATE% The date the file was uploaded
    %A_USER% The user who uploaded it
    %A_COMMENT% The comment they put in when uploading it
    %A_ATTRS% The attributes of the file as seen on the upload screen e.g "h" for a hidden file
    + +Note: it is easy to change the look and feel for an entire site by editing the `twiki.tmpl` template file. However, to simplify upgrading, you should avoid doing this. Instead, write a skin-specific template file e.g. `attach.myskin.tmpl` and use `%TMPL:INCLUDE{attach.myskin.tmpl}%` to include it in each of your skin files. As long as it it included _after_ twiki.tmpl, your macro definitions will override the defaults defined there. + ## Packaging and Publishing Skins See TWiki:Plugins/SkinPackagingHowTo and TWiki:Plugins/SkinDeveloperFAQ +## Browsing Installed Skins + +You can try all installed skins in [[TWikiSkinBrowser]]. + ## Activating Skins A skin can be activated in two ways: @@ -176,4 +287,4 @@ A skin can be activated in two ways: The **?skin=name** URL parameter overrides the SKIN Preference value. --- [[PeterThoeny]] - 05 Jan 2003 +-- TWiki:Main.PeterThoeny - 25 Jul 2004 %BR% -- TWiki:Main.CrawfordCurrie - 30 Jun 2004 %BR%