Skip to content

Label Settings Keys

coolstar edited this page Jul 18, 2015 · 3 revisions

iOS 5 & 6 used WebKit to render Labels. However, in iOS 7 & 8, Apple no longer uses WebKit. While we could load WebKit ourselves, we don't need a whole web browser just to render some labels, and it would be a waste of resources. Instead, Anemone renders the labels itself based on these keys.

FontName

This string tells Anemone which font it should use instead of the default.

FontSize

This number (can be an integer or a real) tells Anemone how large the font should be in points. If this key is omitted, Anemone uses the default font size.

TextXoffset

This number (can be an integer or a real) tells Anemone how many points the text should be shifted horizontally.

TextYoffset

This number (can be an integer or a real) tells Anemone how many points the text should be shifted vertically.

TextColor

A CSS-compatible color string that describes the color that should be used. Also can specify the opacity of the label.

Examples:

1. black
2. #ffffff
3. rgb(255,0,0,0)
4. rgba(255, 255, 0, 0.5)

TextCase

A string, if set to "uppercase" or "lowercase" (without quotes, of course) converts the string to uppercase or lowercase respectively.

ShadowColor

Like TextColor, except specifies the color of the text shadow.

ShadowXoffset

This number (can be an integer or a real) tells Anemone how many points the shadow should be shifted horizontally compared to the text.

ShadowYoffset

This number (can be an integer or a real) tells Anemone how many points the shadow should be shifted vertically compared to the text.

ShadowBlurRadius

This number (can be an integer or a real) tells Anemone how many points the shadow should be blurred.

Clone this wiki locally