#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"= | name of the icon set to chose from; for now only these two are supported | oxygen or defined in =configure= | | =format="..."= | format string for the img tag returned by this macro; within the format string the variables =%<nop>NAME%=, =%<nop>URL%= and =%<nop>SIZE%= are replaced with the concrete values for the icon being rendered | see =mimeicon.theme.tmpl= | *Examples*: <table> <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> </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> </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> </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> </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></tr> </table>
This topic: System
>
MimeIconPlugin
>
VarMIMEICON
Topic revision:
18 Nov 2010,
ProjectContributor
(raw view)
Copyright © by the contributing authors. All material on this site is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki?
Send feedback