-
Notifications
You must be signed in to change notification settings - Fork 3
/
VarMIMEICON.txt
117 lines (114 loc) · 4.27 KB
/
VarMIMEICON.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
%META:TOPICINFO{author="ProjectContributor" comment="" date="1543254682" format="1.1" version="1"}%
%META:TOPICPARENT{name="MimeIconPlugin"}%
#VarMIMEICON
---+++ MIMEICON{"filename"} -- return a meaningful icon for this filename
* Syntax: =%<nop>MIMEICON{"filename"}%=
* Supported parameters:
| *Parameter* | *Description* | *Default* |
| ="filename"= | filenam or file extension to display an icon for | required |
| =size="..."= | icon size; available sizes are depending on the icon set; common sizes are: 16, 32, 48, 64, 128 | 48; when the size isn't found in the icon set a best fitting size available will be chosen automatically |
| =theme="oxygen,crystal,papirus"= | name of the icon set to chose from; for now only these two are supported | papirus or defined in =configure= |
| =class="..."= | css class to be applied to the img tag |
| =format="..."= | format string for the img tag ; | =<img src='$url' class='$class' width='$size' height='$size' alt='$name' />= |
The format parameter may contain the following variables:
* =$name=: the name of the icon (alias: =%<nop>NAME%=)
* =$size=: the requested icon size (alias: =%<nop>URL%=)
* =$url=: the url to the icon (alias: =%<nop>URL%=)
* =$class=: list of css classes applied to the img tag: =foswikiIcon=, the =$class= parameter as well as the theme name
*Examples*:
<table class="foswikiTable foswikiFullWidth">
<thead>
<tr>
<th>Oxygen</th>
<th>Crystal</th>
<th>Papirus</th>
</tr>
</thead>
<tbody>
<tr>
<td>
%MIMEICON{"video.avi" size="16" theme="oxygen"}%
%MIMEICON{"video.avi" size="32" theme="oxygen"}%
%MIMEICON{"video.avi" size="64" theme="oxygen"}%
</td>
<td>
%MIMEICON{"video.avi" size="16" theme="crystal"}%
%MIMEICON{"video.avi" size="32" theme="crystal"}%
%MIMEICON{"video.avi" size="64" theme="crystal"}%
</td>
<td>
%MIMEICON{"video.avi" size="16" theme="papirus"}%
%MIMEICON{"video.avi" size="32" theme="papirus"}%
%MIMEICON{"video.avi" size="64" theme="papirus"}%
</td>
</tr>
<tr>
<td>
%MIMEICON{"document.pdf" size="16" theme="oxygen"}%
%MIMEICON{"document.pdf" size="32" theme="oxygen"}%
%MIMEICON{"document.pdf" size="64" theme="oxygen"}%
</td>
<td>
%MIMEICON{"document.pdf" size="16" theme="crystal"}%
%MIMEICON{"document.pdf" size="32" theme="crystal"}%
%MIMEICON{"document.pdf" size="64" theme="crystal"}%
</td>
<td>
%MIMEICON{"document.pdf" size="16" theme="papirus"}%
%MIMEICON{"document.pdf" size="32" theme="papirus"}%
%MIMEICON{"document.pdf" size="64" theme="papirus"}%
</td>
</tr>
<tr>
<td>
%MIMEICON{"document.txt" size="16" theme="oxygen"}%
%MIMEICON{"document.txt" size="32" theme="oxygen"}%
%MIMEICON{"document.txt" size="64" theme="oxygen"}%
</td>
<td>
%MIMEICON{"document.txt" size="16" theme="crystal"}%
%MIMEICON{"document.txt" size="32" theme="crystal"}%
%MIMEICON{"document.txt" size="64" theme="crystal"}%
</td>
<td>
%MIMEICON{"document.txt" size="16" theme="papirus"}%
%MIMEICON{"document.txt" size="32" theme="papirus"}%
%MIMEICON{"document.txt" size="64" theme="papirus"}%
</td>
</tr>
<tr>
<td>
%MIMEICON{"archive.zip" size="16" theme="oxygen"}%
%MIMEICON{"archive.zip" size="32" theme="oxygen"}%
%MIMEICON{"archive.zip" size="64" theme="oxygen"}%
</td>
<td>
%MIMEICON{"archive.zip" size="16" theme="crystal"}%
%MIMEICON{"archive.zip" size="32" theme="crystal"}%
%MIMEICON{"archive.zip" size="64" theme="crystal"}%
</td>
<td>
%MIMEICON{"archive.zip" size="16" theme="papirus"}%
%MIMEICON{"archive.zip" size="32" theme="papirus"}%
%MIMEICON{"archive.zip" size="64" theme="papirus"}%
</td>
</tr>
<tr>
<td>
%MIMEICON{"soundtrack.mp3" size="16" theme="oxygen"}%
%MIMEICON{"soundtrack.mp3" size="32" theme="oxygen"}%
%MIMEICON{"soundtrack.mp3" size="64" theme="oxygen"}%
</td>
<td>
%MIMEICON{"soundtrack.mp3" size="16" theme="crystal"}%
%MIMEICON{"soundtrack.mp3" size="32" theme="crystal"}%
%MIMEICON{"soundtrack.mp3" size="64" theme="crystal"}%
</td>
<td>
%MIMEICON{"soundtrack.mp3" size="16" theme="papirus"}%
%MIMEICON{"soundtrack.mp3" size="32" theme="papirus"}%
%MIMEICON{"soundtrack.mp3" size="64" theme="papirus"}%
</td>
</tr>
</tbody>
</table>