This
generic class is the base for all the other
. It is up to the user to provide all the necessary data (display name, description, the ValidatorRule, the value of the SC, etc.)
- StyleComponents
The
(SC) is the most basic of the three building pieces of CSS styles. It combines a CSS property value with a ValidatorRule to ensure that the value follows a certain format.
and
- StyleProperties
. To clarify the relationship between these three building pieces, consider the following example:
- StyleCollections
div { margin: 20px; border: 1px solid #000; }
is a
- div
consisting of 2
:
- StyleProperties
and
- margin
. Each of the latter consists of one or more
- border
. In specific,
- StyleComponents
consists of one
- margin
with the value
, and
- 20px
has three
- border
with values
- StyleComponents
,
- 1px
, and
- solid
correspondingly.
- #000
Located in /harmoni/core/GUIManager/StyleComponent.class.php (line 38)
StyleComponentInterface | --StyleComponent
Class | Description |
---|---|
AttachmentSC | The RepeatSC represents CSS "attachment" value. The allowed values are: |
AutoLengthSC | The AutoLengthSC represents CSS "top", "left", "right", "bottom", |
BackgroundAttachmentSC | The BackgroundAttachmentSC represents CSS background-attachment values. The allowed values are: |
BackgroundRepeatSC | The BackgroundRepeatSC represents CSS background-repeat values. The allowed values are: |
BorderStyleSC | The BorderStyleSC represents CSS border-style values. The allowed values are: |
ClearSC | The ClearSC represents CSS clear values. The allowed values are: |
ColorSC | The ColorSC represents CSS color values. For efficiency reasons, constant |
CursorSC | The CursorSC represents CSS "cursor" values. The allowed |
DirectionSC | The DirectionSC represents CSS direction values. The allowed values are: |
DisplaySC | The DisplaySC represents CSS "display" values. The allowed |
FloatSC | The FloatSC represents CSS float values. The allowed values are: |
FontFamilySC | The FontFamilySC represents CSS "font-family" values. The allowed |
FontSizeSC | The FontSizeSC represents CSS "font-size" values. The allowed |
FontStyleSC | The FontStyleSC represents CSS "font-style" values. The allowed |
FontVariantSC | The FontVariantSC represents CSS "font-variant" values. The allowed |
FontWeightSC | The FontWeightSC represents CSS "font-weight" values. The allowed |
HorizontalAlignmentPositionSC | The HorizontalAlignmentPosition represents CSS relative and absolute position values, as well as certain alignments. The allowed |
LengthSC | The LengthSC represents CSS relative and absolute length values. The allowed |
LineHeightSC | The LineHeightSC represents CSS "line-height" values. The allowed |
MaxDimensionSC | The MaxDimensionSC represents CSS "max-height" and "max-width" values. |
OverflowSC | The OverflowSC represents CSS overflow values. The allowed values are: |
PositionSC | The PositionSC represents CSS "position" values. The allowed |
RepeatSC | The RepeatSC represents CSS "repeat" value. The allowed values are: |
TextAlignSC | The TextAlignSC represents CSS text-align values. The allowed values are: |
TextDecorationSC | The TextDecorationSC represents CSS text-decoration values. The allowed values are: |
TextSpacingSC | The TextSpacingSC represents CSS "word-spacing" and "letter-spacing" values. |
TextTransformSC | The TextTransformSC represents CSS text-transform values. The allowed values are: |
UrlSC | The UrlSC represents CSS "url" values. The URL format is: |
VerticalAlignmentPositionSC | The VerticalAlignmentPosition represents CSS relative and absolute position values, as well as certain alignments. The allowed |
VerticalAlignSC | The VerticalAlignSC represents CSS vertical-align values. The allowed values are: |
VisibilitySC | The VisibilitySC represents CSS visibility values. The allowed values are: |
WhiteSpaceSC | The WhiteSpaceSC represents CSS white-space values. The allowed values are: |
ZIndexSC | The ZIndexSC represents CSS z-index values. The allowed values are: |
The description of this SC.
The display name of this SC.
The description of the Error that will be thrown whenever validation fails.
If TRUE, then the value of this SC will be restricted to the list of options.
An array of strings that will store the list of options (may or may not be
set in the constructor)
This is the ValidatorRule of this SC.
The constructor.
, no validator rule will be used.
- NULL
and getOptions() will return an iterator of the options. In addition, if
- true
is set to
- limitedToOptions
, then a new ChoiceValidatorRule will be created with the given options. If this argument is
- TRUE
, then hasOptions() will return
- null
.
- false
is not set, then the value of the argument is irrelevant. FALSE and
- limitedToOptions
will result the same behavior but it is recommended that
- null
is used whenever
- FALSE
is set, and
- options
if not.
- null
Returns the description of this StlyeProperty.
Returns the display name of this SC.
Returns the list of options (list of allowed values) of this SC.
Get the value of this SC.
Determines whether this SC has a list of options. If there is a list of options, then the ValidatorRule of this SC would be a ChoiceValidatorRule.
If not, the ValidatorRule could be any ValidatorRule.
This function will return
if the value of this SC is restricted only to the list of options. It will return
- TRUE
, if not.
- FALSE
if the value of this SC is restricted only to the list of options. It will return
- TRUE
, if not.
- FALSE
Sets the value of this SC and validates it using the attached
.
- ValidatorRule
.
- ValidatorRule
Inherited From StyleComponentInterface
StyleComponentInterface::getDescription()
StyleComponentInterface::getDisplayName()
StyleComponentInterface::getOptions()
StyleComponentInterface::getValue()
StyleComponentInterface::hasOptions()
StyleComponentInterface::isLimitedToOptions()
StyleComponentInterface::setValue()
Documentation generated on Wed, 19 Sep 2007 10:26:58 -0400 by phpDocumentor 1.3.0RC3