| Home · All Classes · Annotated · Functions |
Examples of the:
required to construct a new theme, are provided below.
A project file in <qtopia-root-dir>/etc/themes/ is required to define the files to be installed for the theme:
include($$(QPEDIR)/etc/themes/stub.pri)
!builtin_theme {
PACKAGE_NAME=<name of the package>
PACKAGE_DEPENDS=<name of package this depends upon>
PACKAGE_DESCRIPTION=<description of the theme package>
TRANSLATIONS=
}
<theme name>conf.files=$${QTOPIA_DEPOT_PATH}/etc/themes/<theme name>.conf
<theme name>conf.path=/etc/themes
<theme name>data.files=$${QTOPIA_DEPOT_PATH}/etc/themes/<theme name>/*.xml\
$${QTOPIA_DEPOT_PATH}/etc/themes/<theme name>/*rc
<theme name>data.path=/etc/themes/<theme name>
<theme name>pics.files=$${QTOPIA_DEPOT_PATH}/pics/themes/<theme name>
<theme name>pics.path=/pics/themes
INSTALLS+=<theme name>conf <theme name>data
PICS_INSTALLS+=<theme name>pics
For example, the Portal theme project file: <qtopia-root-dir>/etc/themes/portal/portal.pro contains:
include($$(QPEDIR)/etc/themes/stub.pri)
!builtin_theme {
PACKAGE_NAME=qpe-theme-portal
PACKAGE_DEPENDS=qpe-taskbar
PACKAGE_DESCRIPTION=Portal theme for Qtopia Phone
TRANSLATIONS=
}
portalconf.files=$${QTOPIA_DEPOT_PATH}/etc/themes/portal.conf
portalconf.path=/etc/themes
portaldata.files=$${QTOPIA_DEPOT_PATH}/etc/themes/portal/*.xml \
$${QTOPIA_DEPOT_PATH}/etc/themes/portal/*rc
portaldata.path=/etc/themes/portal
portalpics.files=$${QTOPIA_DEPOT_PATH}/pics/themes/portal
portalpics.path=/pics/themes
INSTALLS+=portalconf portaldata
PICS_INSTALLS+=portalpics
A configuration file in <qtopia-root-dir>/etc/themes/ is required to define a theme as follows:
[Theme]
Name = <name of theme (translatable)>
Style = <name of the Style plug-in that handles widget drawing>
WidgetsConfig = <path for the configuration file (for the themed widget style)>
TitleConfig = <path to the title configuration file>
HomeConfig = <path to the home screen configuration file>
ContextConfig = <path to the context bar configuration file>
DialerConfig = <path to the touch screen dialer configuration file>
CallScreenConfig = <path to the call screen configuration file>
DecorationConfig = <path to the window decoration configuration file>
IconPath = <list of semi-colon separated paths to substitute icons>
WidgetConfig = <base name for widget pixmaps for the default widget style>
For example, the Portal theme is defined by: <qtopia-root-dir>/etc/themes/portal.conf:
[Theme]
Name[] = Portal
Style = Qtopia
TitleConfig = portal/title.xml
HomeConfig = portal/home.xml
ContextConfig = portal/context.xml
DialerConfig = portal/dialer.xml
CallScreenConfig = portal/callscreen.xml
DecorationConfig = portal/decorationrc
WidgetConfig = portal/widget
The title, home screen, call screen, dialer and context bar share the same theming format while the window decoration and widget themes have their own formats.
| Copyright © 2006 Trolltech | Trademarks | Qtopia 4.1.7 |