PowerUI.Css.CssProperty Class Reference

Detailed Description

A CSS property. You can create custom ones by deriving from this class. Note that they are instanced globally.

Inheritance diagram for PowerUI.Css.CssProperty:
PowerUI.Css.Properties.BackgroundClip PowerUI.Css.Properties.BackgroundColor PowerUI.Css.Properties.BackgroundImageProperty PowerUI.Css.Properties.BackgroundPosition PowerUI.Css.Properties.BackgroundRepeat PowerUI.Css.Properties.BackgroundSize PowerUI.Css.Properties.BorderColor PowerUI.Css.Properties.BorderImageSlice PowerUI.Css.Properties.BorderRadius PowerUI.Css.Properties.BorderStyleProperty PowerUI.Css.Properties.BorderWidth PowerUI.Css.Properties.Bottom PowerUI.Css.Properties.Clip PowerUI.Css.Properties.ColorOverlay PowerUI.Css.Properties.ColorProperty PowerUI.Css.Properties.Content PowerUI.Css.Properties.Direction PowerUI.Css.Properties.Display PowerUI.Css.Properties.FilteringMode PowerUI.Css.Properties.Float PowerUI.Css.Properties.FontFamily PowerUI.Css.Properties.FontSize PowerUI.Css.Properties.FontStyle PowerUI.Css.Properties.FontWeight PowerUI.Css.Properties.Height PowerUI.Css.Properties.Left PowerUI.Css.Properties.LetterSpacing PowerUI.Css.Properties.Lighting PowerUI.Css.Properties.LineHeight PowerUI.Css.Properties.Margin PowerUI.Css.Properties.MaxHeight PowerUI.Css.Properties.MaxWidth PowerUI.Css.Properties.MinHeight PowerUI.Css.Properties.MinWidth PowerUI.Css.Properties.OnAtlas PowerUI.Css.Properties.Overflow PowerUI.Css.Properties.Padding PowerUI.Css.Properties.Position PowerUI.Css.Properties.Right PowerUI.Css.Properties.Rotate PowerUI.Css.Properties.Scale PowerUI.Css.Properties.Scroll PowerUI.Css.Properties.ShaderFamily PowerUI.Css.Properties.Skew PowerUI.Css.Properties.TextAlign PowerUI.Css.Properties.TextAlignLast PowerUI.Css.Properties.TextDecorationColor PowerUI.Css.Properties.TextDecorationLine PowerUI.Css.Properties.TextExtrude PowerUI.Css.Properties.TextShadow PowerUI.Css.Properties.TextStroke PowerUI.Css.Properties.Top PowerUI.Css.Properties.TransformOrigin PowerUI.Css.Properties.TransformOriginPosition PowerUI.Css.Properties.Translate PowerUI.Css.Properties.UrlSrc PowerUI.Css.Properties.VerticalAlign PowerUI.Css.Properties.Visibility PowerUI.Css.Properties.WhiteSpace PowerUI.Css.Properties.Width PowerUI.Css.Properties.WordSpacing PowerUI.Css.Properties.ZIndex

Public Member Functions

virtual string[] GetProperties ()
 The set of all properties that this one will handle. Usually just one. e.g. "v-align", "vertical-align". More...
 
virtual void Apply (ComputedStyle style, Value value)
 Apply this CSS style to the given computed style. Note that you can grab the element from the computed style if you need that. More...
 
virtual void SetDefault (Css.Value value, ValueType type)
 Sets the default value for this property into the given value. More...
 
BackgroundImage GetBackground (ComputedStyle style)
 Call this if the current property requires a background image object. More...
 
BorderProperty GetBorder (ComputedStyle style)
 Call this if the current property requies a border object. More...
 
TextRenderingProperty GetText (ComputedStyle style)
 Call this if the current property requires a text object. NOTE: This one may be null. More...
 

Public Attributes

string Name
 The main property name. Some properties use multiple names (e.g. content and inner-text). More...
 
bool IsTextual
 Does this css property apply to text? E.g. font-size, color etc. More...
 
bool IsXProperty
 True if this property occurs along the x axis. E.g. width, left, right. More...
 
bool IsWidthOrHeight
 True if this is width or height only. More...
 
ValueType Type =ValueType.Null
 The optional type of this property, if it defines it. More...
 

Member Function Documentation

virtual void PowerUI.Css.CssProperty.Apply ( ComputedStyle  style,
Value  value 
)
inlinevirtual

Apply this CSS style to the given computed style. Note that you can grab the element from the computed style if you need that.

Parameters
styleThe computed style to apply the property to.
valueThe new value being applied.

Reimplemented in PowerUI.Css.Properties.ShaderFamily, PowerUI.Css.Properties.TextExtrude, PowerUI.Css.Properties.Width, PowerUI.Css.Properties.ColorOverlay, PowerUI.Css.Properties.Height, PowerUI.Css.Properties.Scale, PowerUI.Css.Properties.Scroll, PowerUI.Css.Properties.Lighting, PowerUI.Css.Properties.Content, PowerUI.Css.Properties.FontFamily, PowerUI.Css.Properties.ColorProperty, PowerUI.Css.Properties.FontSize, PowerUI.Css.Properties.Rotate, PowerUI.Css.Properties.TextDecorationColor, PowerUI.Css.Properties.Translate, PowerUI.Css.Properties.BackgroundClip, PowerUI.Css.Properties.BackgroundPosition, PowerUI.Css.Properties.BackgroundRepeat, PowerUI.Css.Properties.BackgroundSize, PowerUI.Css.Properties.BorderColor, PowerUI.Css.Properties.BorderImageSlice, PowerUI.Css.Properties.BorderRadius, PowerUI.Css.Properties.BorderWidth, PowerUI.Css.Properties.Left, PowerUI.Css.Properties.Margin, PowerUI.Css.Properties.Overflow, PowerUI.Css.Properties.Padding, PowerUI.Css.Properties.Right, PowerUI.Css.Properties.TextShadow, PowerUI.Css.Properties.TextStroke, PowerUI.Css.Properties.BackgroundImageProperty, PowerUI.Css.Properties.Skew, PowerUI.Css.Properties.BackgroundColor, PowerUI.Css.Properties.WordSpacing, PowerUI.Css.Properties.FontStyle, PowerUI.Css.Properties.FontWeight, PowerUI.Css.Properties.LetterSpacing, PowerUI.Css.Properties.TextDecorationLine, PowerUI.Css.Properties.TransformOrigin, PowerUI.Css.Properties.LineHeight, PowerUI.Css.Properties.Clip, PowerUI.Css.Properties.FilteringMode, PowerUI.Css.Properties.BorderStyleProperty, PowerUI.Css.Properties.Bottom, PowerUI.Css.Properties.Direction, PowerUI.Css.Properties.Float, PowerUI.Css.Properties.MaxHeight, PowerUI.Css.Properties.MaxWidth, PowerUI.Css.Properties.MinHeight, PowerUI.Css.Properties.MinWidth, PowerUI.Css.Properties.OnAtlas, PowerUI.Css.Properties.Position, PowerUI.Css.Properties.TextAlign, PowerUI.Css.Properties.TextAlignLast, PowerUI.Css.Properties.Top, PowerUI.Css.Properties.VerticalAlign, PowerUI.Css.Properties.Visibility, PowerUI.Css.Properties.WhiteSpace, PowerUI.Css.Properties.ZIndex, PowerUI.Css.Properties.Display, and PowerUI.Css.Properties.TransformOriginPosition.

BackgroundImage PowerUI.Css.CssProperty.GetBackground ( ComputedStyle  style)
inline

Call this if the current property requires a background image object.

BorderProperty PowerUI.Css.CssProperty.GetBorder ( ComputedStyle  style)
inline

Call this if the current property requies a border object.

virtual string [] PowerUI.Css.CssProperty.GetProperties ( )
inlinevirtual

The set of all properties that this one will handle. Usually just one. e.g. "v-align", "vertical-align".

Reimplemented in PowerUI.Css.Properties.ShaderFamily, PowerUI.Css.Properties.TextExtrude, PowerUI.Css.Properties.Width, PowerUI.Css.Properties.Height, PowerUI.Css.Properties.Lighting, PowerUI.Css.Properties.Content, PowerUI.Css.Properties.FontFamily, PowerUI.Css.Properties.ColorProperty, PowerUI.Css.Properties.ColorOverlay, PowerUI.Css.Properties.FontSize, PowerUI.Css.Properties.Rotate, PowerUI.Css.Properties.Scale, PowerUI.Css.Properties.TextDecorationColor, PowerUI.Css.Properties.Translate, PowerUI.Css.Properties.BackgroundClip, PowerUI.Css.Properties.BackgroundPosition, PowerUI.Css.Properties.BackgroundRepeat, PowerUI.Css.Properties.BackgroundSize, PowerUI.Css.Properties.BorderColor, PowerUI.Css.Properties.BorderImageSlice, PowerUI.Css.Properties.BorderRadius, PowerUI.Css.Properties.BorderWidth, PowerUI.Css.Properties.Left, PowerUI.Css.Properties.Margin, PowerUI.Css.Properties.Overflow, PowerUI.Css.Properties.Padding, PowerUI.Css.Properties.Right, PowerUI.Css.Properties.Scroll, PowerUI.Css.Properties.TextShadow, PowerUI.Css.Properties.TextStroke, PowerUI.Css.Properties.BackgroundImageProperty, PowerUI.Css.Properties.Skew, PowerUI.Css.Properties.BackgroundColor, PowerUI.Css.Properties.WordSpacing, PowerUI.Css.Properties.FontStyle, PowerUI.Css.Properties.FontWeight, PowerUI.Css.Properties.LetterSpacing, PowerUI.Css.Properties.TextDecorationLine, PowerUI.Css.Properties.TransformOrigin, PowerUI.Css.Properties.LineHeight, PowerUI.Css.Properties.Clip, PowerUI.Css.Properties.FilteringMode, PowerUI.Css.Properties.BorderStyleProperty, PowerUI.Css.Properties.Bottom, PowerUI.Css.Properties.Direction, PowerUI.Css.Properties.Float, PowerUI.Css.Properties.MaxHeight, PowerUI.Css.Properties.MaxWidth, PowerUI.Css.Properties.MinHeight, PowerUI.Css.Properties.MinWidth, PowerUI.Css.Properties.OnAtlas, PowerUI.Css.Properties.Position, PowerUI.Css.Properties.UrlSrc, PowerUI.Css.Properties.TextAlign, PowerUI.Css.Properties.TextAlignLast, PowerUI.Css.Properties.Top, PowerUI.Css.Properties.VerticalAlign, PowerUI.Css.Properties.Visibility, PowerUI.Css.Properties.WhiteSpace, PowerUI.Css.Properties.ZIndex, PowerUI.Css.Properties.Display, and PowerUI.Css.Properties.TransformOriginPosition.

TextRenderingProperty PowerUI.Css.CssProperty.GetText ( ComputedStyle  style)
inline

Call this if the current property requires a text object. NOTE: This one may be null.

virtual void PowerUI.Css.CssProperty.SetDefault ( Css.Value  value,
ValueType  type 
)
inlinevirtual

Sets the default value for this property into the given value.

Parameters
valueThe value to write the default to.
typeThe type of the given value. Optionally used.

Reimplemented in PowerUI.Css.Properties.ColorOverlay, and PowerUI.Css.Properties.Scale.

Member Data Documentation

bool PowerUI.Css.CssProperty.IsTextual

Does this css property apply to text? E.g. font-size, color etc.

bool PowerUI.Css.CssProperty.IsWidthOrHeight

True if this is width or height only.

bool PowerUI.Css.CssProperty.IsXProperty

True if this property occurs along the x axis. E.g. width, left, right.

string PowerUI.Css.CssProperty.Name

The main property name. Some properties use multiple names (e.g. content and inner-text).

ValueType PowerUI.Css.CssProperty.Type =ValueType.Null

The optional type of this property, if it defines it.