Spaces Context
This context class enables the definition of the common space oriented (margin and padding) styling properties.
This context is passed as receiver either by Space.margin or Space.padding functions for setting the properties for all sides at once or by Space.margins or Space.paddings functions for defining each side independently.
This usage enable styling like this:
margin { small }or alternatively
margins {
top { small }
left { normal }
}Parameters
the CSS-property for the top
the CSS-property for the left
the CSS-property for the bottom
the CSS-property for the right
basic context scope interface
the defined output StringBuilder to write the generated CSS into
Constructors
Functions
This function is used to set the all paddings or margins It is usefull to override existing specific definitions for top, etc.
This function is used to set the bottom padding or margin property according to the passed SpacesContext.bottomKey value like `padding-bottom`.
This function is used to set the horizontal padding or margin according to the passed SpacesContext.leftKey and SpacesContext.rightKey value like `padding-left` and ``padding-right`.
This function is used to set the left padding or margin property according to the passed SpacesContext.leftKey value like `margin-left`.
This function is used to set the right padding or margin property according to the passed SpacesContext.rightKey value like `padding-right`.
This function is used to set the top padding or margin property according to the passed SpacesContext.topKey value like `margin-top`.
This function is used to set the vertical padding or margin according to the passed SpacesContext.topKey and SpacesContext.bottomKey value like `margin-top` and ``margin-bottom`.