Addon.xml: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
>Theuni
>Ronie
m (moved Skin.xml to Skin addon.xml: skin.xml is deprecated)
(No difference)

Revision as of 14:24, 21 January 2011

Each skin in XBMC contains the skin.xml file which sets up an overview of the skin and provides credits and versioning information.

Example

  <skin>
    <defaultresolution>pal</defaultresolution>
    <defaultresolutionwide>pal16x9</defaultresolutionwide>
    <defaultthemename>default</defaultthemename>
    <effectslowdown>1</effectslowdown>
    <version>2.0</version>
  </skin>

One thing to note is that all tag names are lower case. XML tag names are case sensitive!

Overview of the Tags

defaultresolution Default resolution folder for this skin. This is the base directory that all window xml file requests will fall back to.
defaultresolutionwide Default widescreen resolution folder for this skin. This is the directory that all window xml file requests from widescreen resolutions (1080i, 720p, 480p 16x9, NTSC 16x9 and PAL 16x9) will fallback to. If the file isn't found in this window, then it'll fall back to the <defaultresolution> folder.
defaultthemename Default theme name. Currently set to: Default.
effectslowdown A multiplier that is applied to all <animation> effect lengths in the skin. Useful to slow down all animations globally so that you can better configure timings and see interactions between animating controls.
version This specifies the version of the skin engine that this skin will operate with. The current minimum skin version is 2.0. The XBMC team tries to keep backward compatibility for as long as possible (generally before a major version jump).

How window xml files are found

XBMC can run in many differing resolutions, and a skin should try and cater to all these resolutions. The easiest way is to develop for one specific resolution and make sure that all controls contain <width> and <height> tags. That way, XBMC can scale the controls to the new screen resolution.

However, you may choose to develop alternative window xml files for differing resolutions (such as for HDTV resolutions, or for widescreen versus 4x3 resolutions).

The order that XBMC looks for it's skin files are as follows:

  1. It first looks in the current screenmode folder (one of 1080i, 720p, NTSC16x9, NTSC, PAL16x9 or PAL)
  2. If the current screenmode is 1080i, it then looks in the 720p folder.
  3. If the current screenmode is a widescreen mode (1080i, 720p, NTSC16x9, PAL16x9) then it looks in the <defaultresolutionwide> folder.
  4. Finally, it looks in the <defaultresolution> folder.

This allows you to just put any window files that do not require special treatment for 16x9 resolutions etc. in the <defaultresolution> folder, preventing needless repetition.