Theming in Tracker.NewFS - A tutorial for theme designers

0. Requirements

Tracker theming is a new feature and requires at least Tracker.NewFS Beta 7 installed on BeOS R5 or up.

1. Why theming?

Theming in BeOS has long been possible by using different icons for the STD_ICON attributes. But this approch is limited to 16x16 & 32x32 icons and 8bit.
The new theming engine allows for SVG and raster themes (like PNG), with icons up to 512x512 and 32bit colors (including alpha channel). Raster and SVG icons can be combined to provide tuned icons for specific resolutions. Also there is a way to switch between different iconsets easily (including tracker own icons and MIME-Types).
However, themes are an optional feature and need to be enabled first. So there is no need to worry if you dislike theming.

2. Naming convention

All files in the theming structure described below are in lower case and have no file extension. This is true for mimetype icons ("application/x-vnd.be-directory" instead of "application/x-vnd.Be-directory") and for the images themselfs ("trash" instead of "trash.png" or "trash.svg").

3. Location & Infofile

All themes are located in the "Themes" folder under the tracker settings directory, where every theme has it's own folder.
Example: /boot/home/config/settings/Tracker/Themes/<theme-name>

Directly in the theme-root an infofile called "info" can be provided. This file can have 4 strings that are used to display additional information about the theme in the corresponding tracker setting.
The format is as follows: The LinkLabel is optional. If it is provided this label is displayed instead of the link, if not the link is shown directly.

Note that a bookmark will be created to open the link. It will be opend using the default handler for bookmarks, which is NetPositive by default. You should therefore link to something that can be properly displayed by NetPositive.

4. Structure

SVG icons are all in the "svg" folder, raster icons are put into subfolders based on their resolution.
Examples: <theme-root>/svg/*, <theme-root>/128/*, <theme-root>/16/*

In these folders, a subfolder structure for mimetypes and tracker own icons can be provided. Mimetype icons are located in the same way as in the beos_mime database.
Examples: <theme-root>/svg/text/plain, <theme-root>/128/image/png

To make it easier, supertype icons like the one for "image/*" are placed in "supertype" files in the corresponding folder.
Example: <theme-root>/svg/image/supertype would be the icon for "image/*"

If you want to use the same icon for more than one type/resource you can use symlinks. You can link "application/pdf" to "application/x-pdf" for example. Relative links should be used so they don't break when the theme-root is renamed.

Tracker own icons are in the "tracker" folder. Possible icons are:

General icons:

Icons for folders:

Navigation icons:

5. Tuned Icons

If you make a SVG iconset you may want to provide tuned raster icons that look good at low resolutions. To do this you simply provide the icon under */svg/* and */<iconsize>/*.

6. Recommendations

Raster icons are rendered using translators. This makes it possible to have them in any format a translator is installed for, but for performance reasons PNG is recommended. Note also that a crashing translator may bring down the whole tracker, therefore you shouldn't relay on a format you know there is a problematic translator out there (some versions of GIFTranslator for example).