Alternative XML properties - tremho/thunderbolt-common GitHub Wiki
Alternatives to normal CSS names
There are some cases where Thunderbolt has defined aliases for properties normally known by other CSS names.
align,alignSelf,hAlign,vAlign,horizontalAlignment,verticalAlignmentThealignoralignSelfproperty may contain one or both horizontal and vertical components, separated by either comma or space. Otherwise,hAlignandvAlignmay be defined independentlyhAlignvalues are one ofleft,center, orrightvAlignvalues are one oftop,middle, orbottomhorizontalAlignmentandverticalAlignmentare synonymous withhAlignandvAlign, respectively.
background vs. backgroundSettings
In CSS, the background property is an aggregate shorthand for multiple possible background settings.
However, in Nativescript, it's really just an alias for 'background-color'. Setting anything other than a recognized color to background will result in an error cannot set value of null
As a result, Thunderbolt supports the same semantics under the property background-settings (backgroundSettings). Like background for CSS, this will parse and distribute the values given to the individual background properties.
You can also use the individual background properties in either XML markup or in CSS:
- background-color
- background-image see asset notes
- background-repeat
- background-position note that if providing values, both must be provided.
- background-size note that if providing values, both must be provided. also: unsized Android images will be smaller than elsewhere, but sized images are consistent with the appearance of other platforms