How to create a digikam theme?
Header
Since 0.9.3 release, theme are based on pure XML format. Comments in the theme are done by using common XML markers to include comments. The header is the place where you can add some comments, give credit to yourself... Look an existing XML theme file for details.Base Properties XML Markers
name: Marine CaseColor: #FFFFFF TextRegularColor: #000000 TextSelectedColor: #000000 TextSpecialRegularColor: #658857 TextSpecialSelectedColor: #FFFFFFBaseColor is the background color which shall be used for the thumbnail view on the right and album/tag tree on the left. TextRegularColor is used for regular (unselected) text and TextSelectedColor is used for selected text. usually the selected region tends to be brighter or darker and the selected text needs to contrast with it. TextSpecial... are the colors which are used for rendering of some special text like the tags at the bottom of the thumbnails and the collection/date names in the left view.
The color specification is done by using standard HTML color format (RGB/hexadecimal).
Banner Properties XML Markers
BannerColor: #4BFF9C BannerColorTo: #35B56F BannerBevel: RAISED BannerGradient: HORIZONTAL BannerBorder: TRUE BannerBorderColor: #2FA062These specifications are used to render the banner at the top of the thumbnail view. BannerBevel indicates the type of bevel to use for the banner, possible choices are RAISED (for a raised appearance), SUNKEN (for a sunken appearance), FLAT (for a flat appearance). BannerGradient is used for rendering a gradient; the possible choices are SOLID (no gradient), HORIZONTAL (horizontal gradient), VERTICAL (vertical gradient), DIAGONAL (diagonal gradient). There are two color specifications: Color and ColorTo. If a SOLID gradient is specified only "Color" is used, for other cases the gradient is rendered from "Color" to "ColorTo". BannerBorder indicates whether a border should be drawn around the banner, using BannerBorderColor. set it to "TRUE" for rendering a border and to "FALSE" otherwise.
Thumbnail Properties XML Markers
ThumbnailRegularColor: #E7FFF4 ThumbnailRegularColorTo: #C4D8CF ThumbnailRegularBevel: RAISED ThumbnailRegularGradient: HORIZONTAL ThumbnailRegularBorder: TRUE ThumbnailRegularBorderColor: #769286 ThumbnailSelectedColor: #4BFF9C ThumbnailSelectedColorTo: #35B56F ThumbnailSelectedBevel: RAISED ThumbnailSelectedGradient: HORIZONTAL ThumbnailSelectedBorder: TRUE ThumbnailSelectedBorderColor: #2FA062These specifications are used for rendering the thumbnails. Regular... is used for unselected thumbnails and Selected... for selected thumbnails. The specifications are similar to that of the banner.
Listview Properties XML Markers
ListviewRegularColor: #FFFFFF ListviewRegularColorTo: #FFFFFF ListviewRegular.bevel: FLAT ListviewRegular.gradient: SOLID ListviewRegular.border: FALSE ListviewRegularBorderColor: #FFFFFF ListviewSelectedColor: #4BFF9C ListviewSelectedColorTo: #35B56F ListviewSelectedBevel: RAISED ListviewSelectedGradient: HORIZONTAL ListviewSelectedBorder: TRUE ListviewSelectedBorderColor: #2FA062These are used for rendering the items on the left treeview. again, the specifications are same as that of the banner.
Notes:
- Case sensitivity is important for specifiying the property names, but not for the property values.
- System level installation of themes is done in $(INSTALLATION_PREFIX)/share/apps/digikam/themes and user level installation in $(HOME)/.kde/share/apps/digikam/themes
- Theme names appear in the menu with the filename. Make sure to capitalize the first letter of the filename
- Its not necessary to restart digikam if you modify the theme. switch to a different theme and switch back. But if you add a new theme, you will have to restart digikam for the new theme to be recognized.
Theme editor
You can also try the theme editor include in digiKam since 0.9.3 release.
