每个主题都有一个索引文件,它定义了这个主题的特征。索引文件的名称为 /usr/share/themes/theme-name/index.theme。
以下是一个主题索引文件的示例:
[Desktop Entry] Type=X-GNOME-Metatheme Name=High Contrast Large Name[es]=Alto contraste grande Comment=Large black-on-white text and icons Comment[es]=Textos e iconos grandes en negro sobre blanco Encoding=UTF-8 [X-GNOME-Metatheme] GtkTheme=HighContrastLargePrint IconTheme=HighContrast MetacityTheme=Atlanta ApplicationFont=sans 18
下面的表给出了主题索引文件中的键:
表 3–1 主题索引文件中的键| 索引文件键 | 说明 | 
|---|---|
| Type | 指定这个主题决定了几个主题选项的外观,例如控件、窗口框架和图标。 | 
| Name | 主题名称。即这个主题在 | 
| Comment | 主题的简要描述。即在 | 
| GtkTheme | 对应 | 
| IconTheme | 对应 | 
| MetacityTheme | 对应 | 
| ApplicationFont | 与 |