Help:Template

From openSUSE


< Templates | Template Messages - Template Messages to Review - Template of the month - Daily templates - Help:Template - All templates


OpenSUSE wiki and Wikipedia use the same type of wiki software, the MediaWiki, therefore most of the answers to questions What are templates? and How to use them? can be found in Wikipedia article about templates.


Draft of template guidelines

Recently we started to develop unified look and feel for all template messages within openSUSE wiki, so there are not yet written openSUSE:Template creation quidelines, but with lists of templates, this draft and collection of often used templates in articles Daily templates that are current consent how templates should look like, you can create some that you find useful, or missing from some other wiki that is using Mediawiki software.


Below is draft of rules to observe when creating and using templates:


  • Related: Help:Colors, Artwork
  • Icon size: 32px, only in rare cases when template is larger then 48px or 64px
  • Template width: 100% of page width; if it should be smaller then check text flow around template.
  • Command line simulation:
    • use tags <pre> and </pre> around the text that should appear on separate lines
    • use tags <code> and </code> around the text that should be inline with the rest of the text
    • in special cases you can use template {{Command|A}}.
      It must be a case that will justify readers discomfort when it runs in a text that has inverse colors to the rest of article.
  • General usability:
    • Think of:
      • How much time visitor to a web page read my creation?
        It is usually portion of the second to make opinion to stay, or to go, a second to read start of the first paragraph to decide will further reading bring more looked for information.
        Today time is precious and no one will read lengthy article broken in pieces with a lot of changes in presentation layout with templates of different color that make reading slower without benefits that will justify time lost.
  • Text position in templates
    • Start should be placed on the left. Text that is not aligned to start from the same position is harder to read as eyes have to locate begin, and if that happens on every line, it makes very unpleasant experience.
    • If icon takes too much space in tables, then put style="width:36px" in cell before icon and size will be reduced to 36px.
    • Example:
{| style="width:100%;background:#DEE1FF; border:2px solid #6699CC" cellpadding="5px" cellspacing="0" 
|-
| style="width:36px;"|[[image:Network-server-database.png|32px]]
|'''This article should be included in the [[SDB:SDB|Support Database]]!'''<br />
For more information see the [[Wiki Team]].
|}
<noinclude>

----
This template will add tagged articles to [[:Category:Pages for SDB]].
</noinclude>
<includeonly>[[Category:Pages for SDB]]</includeonly>