class PageTheme extends Theme (View source)

Constants

E_THEME_INSTALLED

THEME_EXTENSION

THEME_CUSTOMIZABLE_STYLESHEET_EXTENSION

FILENAME_TYPOGRAPHY_CSS

Properties

$error from ConcreteObject
protected $pThemeName from Theme
protected $pThemeID from Theme
protected $pThemeDescription from Theme
protected $pThemeDirectory from Theme
protected $pThemeThumbnail from Theme
protected $pThemeHandle from Theme
protected $pThemeURL from Theme
protected $pThemeIsPreview from Theme
protected $pkgID from Theme
protected $stylesheetCachePath from Theme
protected $stylesheetCacheRelativePath from Theme
protected $pThemeGridFrameworkHandle Special items meant to be extended by custom theme classes. from Theme

Methods

loadError($error)

No description

isError()

No description

getError()

No description

setPropertiesFromArray($arr)

No description

static 
camelcase($file)

No description

static 
uncamelcase($string)

No description

__construct()

No description

from Theme
static 
getGlobalList()

No description

from Theme
static 
getLocalList()

No description

from Theme
static 
getListByPackage($pkg)

No description

from Theme
static 
getList($where = null)

No description

from Theme
static 
getInstalledHandles()

No description

from Theme
providesAsset($assetType, $assetHandle = null)

No description

from Theme
requireAsset()

No description

from Theme
static Theme[]
getAvailableThemes(bool $filterInstalled = true)

scans the directory for available themes. For those who don't want to go through the hassle of uploading.

from Theme
static 
getByFileHandle($handle, $dir = DIR_FILES_THEMES, $pkgHandle = '')

No description

from Theme
bool
isThemeCustomizable()

Checks the theme for a styles.xml file (which is how customizations happen.).

from Theme
getThemeCustomizableStyleList()

Gets the style list object for this theme.

from Theme
getThemeCustomizablePreset($handle)

Gets a preset for this theme by handle.

from Theme
getThemeCustomizableStylePresets()

Gets all presets available to this theme.

from Theme
enablePreviewRequest()

No description

from Theme
resetThemeCustomStyles()

No description

from Theme
isThemePreviewRequest()

No description

from Theme
from Theme
getStylesheetObject($stylesheet)

No description

from Theme
string
getStylesheet(string $stylesheet)

Looks into the current CSS directory and returns a fully compiled stylesheet when passed a LESS stylesheet. Also serves up custom value list values for the stylesheet if they exist.

from Theme
getThemeCustomStyleObject()

Returns a Custom Style Object for the theme if one exists.

from Theme
ValueList
getThemeCustomStyleObjectValues()

Returns the value list of the custom style object if one exists.

from Theme
setCustomStyleObject(ValueList $valueList, $selectedPreset = false, CustomCssRecord $customCssRecord = null)

No description

from Theme
static PageTheme
getByHandle(string $pThemeHandle)

No description

from Theme
static PageTheme
getByID($pThemeID)

No description

from Theme
static Theme|null
populateThemeQuery(string $where, array $args)

No description

from Theme
static 
add($pThemeHandle, $pkg = null)

No description

from Theme
getFilesInTheme()

No description

from Theme
static 
getThemeNameAndDescription($dir, $pThemeHandle, $pkgHandle = '')

No description

from Theme
export($node)

No description

from Theme
static 
exportList($xml)

No description

from Theme
static 
install($dir, $pThemeHandle, $pkgID)

No description

from Theme
updateThemeCustomClass()

No description

from Theme
getThemeID()

No description

from Theme
getThemeName()

No description

from Theme
string
getThemeDisplayName(string $format = 'html')

Returns the display name for this theme (localized and escaped accordingly to $format)

from Theme
getPackageID()

No description

from Theme
getPackageHandle()

No description

from Theme
hasCustomClass()

Returns whether a theme has a custom class.

from Theme
getThemeHandle()

No description

from Theme
getThemeDescription()

No description

from Theme
getThemeDisplayDescription($format = 'html')

No description

from Theme
getThemeDirectory()

No description

from Theme
getThemeURL()

No description

from Theme
getThemeEditorCSS()

No description

from Theme
setThemeURL($pThemeURL)

No description

from Theme
setThemeDirectory($pThemeDirectory)

No description

from Theme
setThemeHandle($pThemeHandle)

No description

from Theme
setStylesheetCachePath($path)

No description

from Theme
setStylesheetCacheRelativePath($path)

No description

from Theme
getStylesheetCachePath()

No description

from Theme
from Theme
isUninstallable()

No description

from Theme
getThemeThumbnail()

No description

from Theme
applyToSite(Site $site = null)

No description

from Theme
static Theme
getSiteTheme()

No description

from Theme
uninstall()

No description

from Theme
registerAssets()

No description

supportsGridFramework()

No description

from Theme
getThemeGridFrameworkObject()

No description

from Theme
getThemeBlockClasses()

No description

from Theme
getThemeAreaClasses()

No description

from Theme
getThemeEditorClasses()

No description

from Theme
from Theme
getThemeResponsiveImageMap()

No description

from Theme
from Theme
from Theme
from Theme

Details

loadError($error)

Parameters

$error

isError()

getError()

setPropertiesFromArray($arr)

Parameters

$arr

static camelcase($file)

Parameters

$file

static uncamelcase($string)

Parameters

$string

__construct()

static getGlobalList()

static getLocalList()

static getListByPackage($pkg)

Parameters

$pkg

static getList($where = null)

Parameters

$where

static getInstalledHandles()

providesAsset($assetType, $assetHandle = null)

Parameters

$assetType
$assetHandle

requireAsset()

static Theme[] getAvailableThemes(bool $filterInstalled = true)

scans the directory for available themes. For those who don't want to go through the hassle of uploading.

Parameters

bool $filterInstalled

Return Value

Theme[]

static getByFileHandle($handle, $dir = DIR_FILES_THEMES, $pkgHandle = '')

Parameters

$handle
$dir
$pkgHandle

bool isThemeCustomizable()

Checks the theme for a styles.xml file (which is how customizations happen.).

Return Value

bool

StyleList getThemeCustomizableStyleList()

Gets the style list object for this theme.

Return Value

StyleList

getThemeCustomizablePreset($handle)

Gets a preset for this theme by handle.

Parameters

$handle

getThemeCustomizableStylePresets()

Gets all presets available to this theme.

enablePreviewRequest()

resetThemeCustomStyles()

isThemePreviewRequest()

getThemeCustomizableStyleSheets()

getStylesheetObject($stylesheet)

Parameters

$stylesheet

string getStylesheet(string $stylesheet)

Looks into the current CSS directory and returns a fully compiled stylesheet when passed a LESS stylesheet. Also serves up custom value list values for the stylesheet if they exist.

Parameters

string $stylesheet The LESS stylesheet to compile

Return Value

string The path to the stylesheet

getThemeCustomStyleObject()

Returns a Custom Style Object for the theme if one exists.

ValueList getThemeCustomStyleObjectValues()

Returns the value list of the custom style object if one exists.

Return Value

ValueList

setCustomStyleObject(ValueList $valueList, $selectedPreset = false, CustomCssRecord $customCssRecord = null)

Parameters

ValueList $valueList
$selectedPreset
CustomCssRecord $customCssRecord

static PageTheme getByHandle(string $pThemeHandle)

Parameters

string $pThemeHandle

Return Value

PageTheme

static PageTheme getByID($pThemeID)

Parameters

$pThemeID

Return Value

PageTheme

static protected Theme|null populateThemeQuery(string $where, array $args)

Parameters

string $where
array $args

Return Value

Theme|null

static add($pThemeHandle, $pkg = null)

Parameters

$pThemeHandle
$pkg

getFilesInTheme()

static private getThemeNameAndDescription($dir, $pThemeHandle, $pkgHandle = '')

Parameters

$dir
$pThemeHandle
$pkgHandle

export($node)

Parameters

$node

static exportList($xml)

Parameters

$xml

static protected install($dir, $pThemeHandle, $pkgID)

Parameters

$dir
$pThemeHandle
$pkgID

updateThemeCustomClass()

getThemeID()

getThemeName()

string getThemeDisplayName(string $format = 'html')

Returns the display name for this theme (localized and escaped accordingly to $format)

Parameters

string $format = 'html' Escape the result in html format (if $format is 'html'). If $format is 'text' or any other value, the display name won't be escaped

Return Value

string

getPackageID()

getPackageHandle()

hasCustomClass()

Returns whether a theme has a custom class.

getThemeHandle()

getThemeDescription()

getThemeDisplayDescription($format = 'html')

Parameters

$format

getThemeDirectory()

getThemeURL()

getThemeEditorCSS()

setThemeURL($pThemeURL)

Parameters

$pThemeURL

setThemeDirectory($pThemeDirectory)

Parameters

$pThemeDirectory

setThemeHandle($pThemeHandle)

Parameters

$pThemeHandle

setStylesheetCachePath($path)

Parameters

$path

setStylesheetCacheRelativePath($path)

Parameters

$path

getStylesheetCachePath()

getStylesheetCacheRelativePath()

isUninstallable()

getThemeThumbnail()

applyToSite(Site $site = null)

Parameters

Site $site

static Theme getSiteTheme()

Return Value

Theme

uninstall()

registerAssets()

supportsGridFramework()

GridFramework|null getThemeGridFrameworkObject()

Return Value

GridFramework|null

getThemeBlockClasses()

getThemeAreaClasses()

getThemeEditorClasses()

getThemeDefaultBlockTemplates()

getThemeResponsiveImageMap()

getThemeGatheringGridItemMargin()

getThemeGatheringGridItemWidth()

getThemeGatheringGridItemHeight()