]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/shamino_com/themeinfo.php
Renamed class Theme to WikiTheme to avoid Gforge name clash
[SourceForge/phpwiki.git] / themes / shamino_com / themeinfo.php
1 <?php
2 rcs_id('$Id$');
3 /**
4  * A minimalistic design by walter rafelsberger
5  * See http://www.shamino.com/wiki/
6  *
7  * Tiny actionbar: PageInfo, Edit and 
8  *   all other Actionbars buttons in info.tmpl, 
9  * Signin implictly after Edit.
10  * tiny navbar: without buttons, just links
11  * no logo
12  */
13
14 require_once('lib/WikiTheme.php');
15
16 class WikiTheme_shamino_com extends WikiTheme {
17
18     function makeActionButton ($action, $label = false, $page_or_rev = false) {
19         extract($this->_get_name_and_rev($page_or_rev));
20
21         if (is_array($action)) {
22             $attr = $action;
23             $action = isset($attr['action']) ? $attr['action'] : 'browse';
24         }
25         else
26             $attr['action'] = $action;
27
28         $class = is_safe_action($action) ? 'named-wiki' : 'wikiadmin';
29         if (!$label)
30             $label = $this->_labelForAction($action);
31
32         if ($version)
33             $attr['version'] = $version;
34
35         if ($action == 'browse')
36             unset($attr['action']);
37
38         return $this->makeButton($label, WikiURL($pagename, $attr), $class);
39     }
40
41     function load() {
42         // CSS file defines fonts, colors and background images for this
43         // style.  The companion '*-heavy.css' file isn't defined, it's just
44         // expected to be in the same directory that the base style is in.
45
46         // This should result in phpwiki-printer.css being used when
47         // printing or print-previewing with style "PhpWiki" or "MacOSX" selected.
48         $this->setDefaultCSS('PhpWiki',
49                                   array(''      => 'shamino_com.css',
50                                         'print' => 'phpwiki-printer.css'));
51
52         // This allows one to manually select "Printer" style (when browsing page)
53         // to see what the printer style looks like.
54         $this->addAlternateCSS(_("Printer"), 'phpwiki-printer.css', 'print, screen');
55         $this->addAlternateCSS(_("Top & bottom toolbars"), 'phpwiki-topbottombars.css');
56         $this->addAlternateCSS(_("Modern"), 'phpwiki-modern.css');
57
58         /**
59          * The logo image appears on every page and links to the HomePage.
60          */
61         //$this->addImageAlias('logo', WIKI_NAME . 'Logo.png');
62
63         /**
64          * The Signature image is shown after saving an edited page. If this
65          * is set to false then the "Thank you for editing..." screen will
66          * be omitted.
67          */
68
69         //$this->addImageAlias('signature', WIKI_NAME . "Signature.png");
70         // Uncomment this next line to disable the signature.
71         $this->addImageAlias('signature', false);
72
73         /*
74          * Link icons.
75          */
76         //$this->setLinkIcon('http');
77         //$this->setLinkIcon('https');
78         //$this->setLinkIcon('ftp');
79         //$this->setLinkIcon('mailto');
80         //$this->setLinkIcon('interwiki');
81         //$this->setLinkIcon('wikiuser');
82         //$this->setLinkIcon('*', 'url');
83
84         //$this->setButtonSeparator("\n | ");
85
86         /**
87          * WikiWords can automatically be split by inserting spaces between
88          * the words. The default is to leave WordsSmashedTogetherLikeSo.
89          */
90         //$this->setAutosplitWikiWords(false);
91
92         /**
93          * Layout improvement with dangling links for mostly closed wiki's:
94          * If false, only users with edit permissions will be presented the 
95          * special wikiunknown class with "?" and Tooltip.
96          * If true (default), any user will see the ?, but will be presented 
97          * the PrintLoginForm on a click.
98          */
99         $this->setAnonEditUnknownLinks(false);
100
101         /*
102          * You may adjust the formats used for formatting dates and times
103          * below.  (These examples give the default formats.)
104          * Formats are given as format strings to PHP strftime() function See
105          * http://www.php.net/manual/en/function.strftime.php for details.
106          * Do not include the server's zone (%Z), times are converted to the
107          * user's time zone.
108          */
109         $this->setDateFormat("%B %d, %Y");
110         $this->setTimeFormat("%H:%M");
111
112         /*
113          * To suppress times in the "Last edited on" messages, give a
114          * give a second argument of false:
115          */
116         //$this->setDateFormat("%B %d, %Y", false); 
117     }
118 }
119
120 $WikiTheme = new WikiTheme_shamino_com('shamino_com');
121
122
123 // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
124 // (c-file-style: "gnu")
125 // Local Variables:
126 // mode: php
127 // tab-width: 8
128 // c-basic-offset: 4
129 // c-hanging-comment-ender-p: nil
130 // indent-tabs-mode: nil
131 // End:   
132 ?>