Class TTheme
TTheme class
TTheme represents a particular theme. It is merely a collection of skins that are applicable to the corresponding controls.
Each theme is stored as a directory and files under that directory. The theme name is the directory name. When TTheme is created, the files whose name has the extension ".skin" are parsed and saved as controls skins.
A skin is essentially a list of initial property values that are to be applied to a control when the skin is applied. Each type of control can have multiple skins identified by the SkinID. If a skin does not have SkinID, it is the default skin that will be applied to controls that do not specify particular SkinID.
Whenever possible, TTheme will try to make use of available cache to save the parsing time.
To apply a theme to a particular control, call TTheme::applySkin()
.
- TComponent
-
TApplicationComponent
-
TTheme implements ITheme
Copyright: Copyright © 2005-2014 PradoSoft
License: http://www.pradosoft.com/license/
Author: Qiang Xue <qiang.xue@gmail.com>
Since: 3.0
Located at Web/UI/TThemeManager.php
public
|
|
public
string
|
|
protected
|
|
public
string
|
|
protected
|
|
public
string
|
|
protected
|
|
public
array
|
|
protected
|
|
public
boolean
|
|
public
array
|
|
protected
|
|
public
array
|
|
protected
|
getApplication(),
getRequest(),
getResponse(),
getService(),
getSession(),
getUser(),
publishAsset(),
publishFilePath()
|
string |
THEME_CACHE_PREFIX |
'prado:theme:' |
#
prefix for cache variable name used to store parsed themes |
string |
SKIN_FILE_EXT |
'.skin' |
#
Extension name of skin files |
GLOBAL_RAISE_EVENT_LISTENER
|