cee::ug::BackgroundPropertyHandler Class Reference

Property handler for background properties. More...

Public Types

enum  PropertyKey { SINGLE_BACKGROUND_COLOR, TOP_BACKGROUND_COLOR, BOTTOM_BACKGROUND_COLOR }
 List of property keys for BackgroundPropertyHandler. More...
 

Public Member Functions

 BackgroundPropertyHandler (PropertySet *propSet)
 Creates a background property handler from a given property set propSet. More...
 
Variant propertyValue (PropertyKey key) const
 Returns the property value for the specified property key. More...
 
void setPropertyValue (PropertyKey key, Variant data)
 Sets the property key and value to this handlers property set. More...
 
void applyToBackground (vis::Background *background) const
 Applies the properties in this property set to the specified background. More...
 
void buildProperties (const vis::Background &background)
 Sets the property keys and values for this property set from the background. More...
 

Static Public Member Functions

static Str propertySetClassType ()
 Returns the class type of the property set. More...
 
static bool isValidPropertySet (const PropertySet &propSet)
 Returns true if the specified property set is a valid background property set. More...
 

Detailed Description

Property handler for background properties.

Member Enumeration Documentation

List of property keys for BackgroundPropertyHandler.

Enumerator
SINGLE_BACKGROUND_COLOR 

Color for single background coloring.

TOP_BACKGROUND_COLOR 

Top background color for gradient background coloring.

BOTTOM_BACKGROUND_COLOR 

Bottom background color for gradient background coloring.

Constructor & Destructor Documentation

cee::ug::BackgroundPropertyHandler::BackgroundPropertyHandler ( PropertySet propSet)

Creates a background property handler from a given property set propSet.

Member Function Documentation

void cee::ug::BackgroundPropertyHandler::applyToBackground ( vis::Background background) const

Applies the properties in this property set to the specified background.

void cee::ug::BackgroundPropertyHandler::buildProperties ( const vis::Background background)

Sets the property keys and values for this property set from the background.

bool cee::ug::BackgroundPropertyHandler::isValidPropertySet ( const PropertySet propSet)
static

Returns true if the specified property set is a valid background property set.

Str cee::ug::BackgroundPropertyHandler::propertySetClassType ( )
static

Returns the class type of the property set.

cee::Variant cee::ug::BackgroundPropertyHandler::propertyValue ( PropertyKey  key) const

Returns the property value for the specified property key.

Returns an empty Variant if the property key was not found.

void cee::ug::BackgroundPropertyHandler::setPropertyValue ( PropertyKey  key,
Variant  data 
)

Sets the property key and value to this handlers property set.

If key exists in the property set, the paired property value is updated to data. Otherwise the key/value pair is added to the property set.