summaryrefslogtreecommitdiff
path: root/platform/darwin/docs
diff options
context:
space:
mode:
Diffstat (limited to 'platform/darwin/docs')
-rw-r--r--platform/darwin/docs/guides/For Style Authors.md.ejs11
-rw-r--r--platform/darwin/docs/guides/Predicates and Expressions.md8
2 files changed, 19 insertions, 0 deletions
diff --git a/platform/darwin/docs/guides/For Style Authors.md.ejs b/platform/darwin/docs/guides/For Style Authors.md.ejs
index cf0f79f419..cff6e2f41c 100644
--- a/platform/darwin/docs/guides/For Style Authors.md.ejs
+++ b/platform/darwin/docs/guides/For Style Authors.md.ejs
@@ -431,5 +431,16 @@ In style JSON | In the format string
`["any", f0, …, fn]` | `p0 OR … OR pn`
`["none", f0, …, fn]` | `NOT (p0 OR … OR pn)`
+## Specifying the text format
+
+The following format attributes are defined as `NSString` constans that you
+can use to update the formatting of `MGLSymbolStyleLayer.text` property.
+
+In style JSON | In Objective-C | In Swift
+--------------|-----------------------|---------
+`text-font` | `MGLFontNamesAttribute` | `.fontNamesAttribute`
+`font-scale` | `MGLFontSizeAttribute` | `.fontSizeAttribute`
+`text-color` | `MGLFontColorAttribute` | `.fontColorAttribute`
+
See the “[Predicates and Expressions](predicates-and-expressions.html)” guide for
a full description of the supported operators and operand types.
diff --git a/platform/darwin/docs/guides/Predicates and Expressions.md b/platform/darwin/docs/guides/Predicates and Expressions.md
index 5f5d9a22a8..51617c8508 100644
--- a/platform/darwin/docs/guides/Predicates and Expressions.md
+++ b/platform/darwin/docs/guides/Predicates and Expressions.md
@@ -546,6 +546,14 @@ operator in the Mapbox Style Specification.
Concatenates and returns the array of `MGLAttributedExpression` objects, for use
with the `MGLSymbolStyleLayer.text` property.
+`MGLAttributedExpression.attributes` valid attributes.
+
+ Key | Value Type
+ --- | ---
+ `MGLFontNamesAttribute` | `NSArray<NSString *>*`
+ `MGLFontSizeAttribute` | `NSNumber`
+ `MGLFontColorAttribute` | `UIColor` or `NSColor` on macos
+
This function corresponds to the
[`format`](https://www.mapbox.com/mapbox-gl-js/style-spec/#expressions-types-format)
operator in the Mapbox Style Specification.